pub enum BlockIndexError {
OrphanHeader,
DuplicateBlock,
CheckpointMismatch {
height: u32,
expected: String,
got: String,
},
TargetExceedsPowLimit,
InsufficientProofOfWork,
}Expand description
Errors from block index operations
Variants§
OrphanHeader
The parent block hash is not in the index
DuplicateBlock
The block is already known
CheckpointMismatch
A header at a checkpoint height does not match the expected hash
TargetExceedsPowLimit
The header’s target (nBits) exceeds the network’s proof-of-work limit
InsufficientProofOfWork
The block hash does not meet the proof-of-work target
Trait Implementations§
Source§impl Clone for BlockIndexError
impl Clone for BlockIndexError
Source§fn clone(&self) -> BlockIndexError
fn clone(&self) -> BlockIndexError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BlockIndexError
impl Debug for BlockIndexError
Source§impl Display for BlockIndexError
impl Display for BlockIndexError
Source§impl Error for BlockIndexError
impl Error for BlockIndexError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<BlockIndexError> for ChainStateError
impl From<BlockIndexError> for ChainStateError
Source§fn from(e: BlockIndexError) -> Self
fn from(e: BlockIndexError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for BlockIndexError
impl PartialEq for BlockIndexError
impl Eq for BlockIndexError
impl StructuralPartialEq for BlockIndexError
Auto Trait Implementations§
impl Freeze for BlockIndexError
impl RefUnwindSafe for BlockIndexError
impl Send for BlockIndexError
impl Sync for BlockIndexError
impl Unpin for BlockIndexError
impl UnsafeUnpin for BlockIndexError
impl UnwindSafe for BlockIndexError
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