pub enum Error {
Secp256k1(Error),
Encode(Error),
Network(Error),
SpvBadProofOfWork,
SpvBadTarget,
}Expand description
A general error code, other errors should implement conversions to/from this if appropriate.
Variants§
Secp256k1(Error)
secp-related error
Encode(Error)
Encoding error
Network(Error)
Network error
SpvBadProofOfWork
The header hash is not below the target
SpvBadTarget
The target field of a block header did not match the expected difficulty
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn cause(&self) -> Option<&dyn Error>
fn cause(&self) -> Option<&dyn Error>
👎Deprecated since 1.33.0:
replaced by Error::source, which can support downcasting
Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl !UnwindSafe for Error
impl Freeze for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more