Enum grin_chain::types::BlockStatus
source · [−]pub enum BlockStatus {
Next {
prev: Tip,
},
Fork {
prev: Tip,
head: Tip,
fork_point: Tip,
},
Reorg {
prev: Tip,
prev_head: Tip,
fork_point: Tip,
},
}
Expand description
Status of an accepted block.
Variants
Next
Fields
prev: Tip
Previous block (previous chain head).
Block is the “next” block, updating the chain head.
Fork
Fields
prev: Tip
Previous block on this fork.
head: Tip
Current chain head.
fork_point: Tip
Fork point for rewind.
Block does not update the chain head and is a fork.
Reorg
Fields
prev: Tip
Previous block on this fork.
prev_head: Tip
Previous chain head.
fork_point: Tip
Fork point for rewind.
Block updates the chain head via a (potentially disruptive) “reorg”. Previous block was not our previous chain head.
Implementations
Trait Implementations
sourceimpl Clone for BlockStatus
impl Clone for BlockStatus
sourcefn clone(&self) -> BlockStatus
fn clone(&self) -> BlockStatus
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for BlockStatus
impl Debug for BlockStatus
sourceimpl PartialEq<BlockStatus> for BlockStatus
impl PartialEq<BlockStatus> for BlockStatus
sourcefn eq(&self, other: &BlockStatus) -> bool
fn eq(&self, other: &BlockStatus) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &BlockStatus) -> bool
fn ne(&self, other: &BlockStatus) -> bool
This method tests for !=
.
impl Copy for BlockStatus
impl StructuralPartialEq for BlockStatus
Auto Trait Implementations
impl RefUnwindSafe for BlockStatus
impl Send for BlockStatus
impl Sync for BlockStatus
impl Unpin for BlockStatus
impl UnwindSafe for BlockStatus
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> CloneAny for T where
T: Any + Clone,
impl<T> CloneAny for T where
T: Any + Clone,
fn clone_any(&self) -> Box<dyn CloneAny + 'static, Global>
fn clone_any_send(&self) -> Box<dyn CloneAny + Send + 'static, Global> where
T: Send,
fn clone_any_sync(&self) -> Box<dyn CloneAny + Sync + 'static, Global> where
T: Sync,
fn clone_any_send_sync(
&self
) -> Box<dyn CloneAny + Send + Sync + 'static, Global> where
T: Send + Sync,
impl<'a, T> DefaultFeatures<'a> for T where
T: 'a + Send + Sync + Clone,
impl<'a, T> DefaultFeatures<'a> for T where
T: 'a + Send + Sync + Clone,
fn clone_boxed(&self) -> Box<dyn DefaultFeatures<'a> + 'a, Global>
fn clone_boxed(&self) -> Box<dyn DefaultFeatures<'a> + 'a, Global>
Clone this value, and then immediately put it into a Box
behind a trait object of this trait. Read more
fn self_address_mut(&mut self) -> *mut ()
fn self_address_mut(&mut self) -> *mut ()
Returns the address of self
. Read more
impl<'a, T> NonSyncFeatures<'a> for T where
T: 'a + Clone,
impl<'a, T> NonSyncFeatures<'a> for T where
T: 'a + Clone,
fn clone_boxed(&self) -> Box<dyn NonSyncFeatures<'a> + 'a, Global>
fn clone_boxed(&self) -> Box<dyn NonSyncFeatures<'a> + 'a, Global>
Clone this value, and then immediately put it into a Box
behind a trait object of this trait. Read more
fn self_address_mut(&mut self) -> *mut ()
fn self_address_mut(&mut self) -> *mut ()
Returns the address of self
. Read more
impl<T> SafeBorrow<T> for T where
T: ?Sized,
impl<T> SafeBorrow<T> for T where
T: ?Sized,
fn borrow_replacement(ptr: &T) -> &T
fn borrow_replacement(ptr: &T) -> &T
Given ptr
, which was obtained from a prior call to Self::borrow()
,
return a value with the same nominal lifetime which is guaranteed to
survive mutations to Self
. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more