pub struct BlockImportedNotification<Block> {
pub block: Block,
pub is_new_best: bool,
}Expand description
Notification about a successfully imported block
Fields§
§block: BlockImported block
is_new_best: boolWhether the block became the new best block on import.
Notifications are sent in the same order as blocks are persisted, so the most recent notification with this flag set corresponds to the current best block.
Trait Implementations§
Source§impl<Block: Clone> Clone for BlockImportedNotification<Block>
impl<Block: Clone> Clone for BlockImportedNotification<Block>
Auto Trait Implementations§
impl<Block> Forget for BlockImportedNotification<Block>
impl<Block> Freeze for BlockImportedNotification<Block>where
Block: Freeze,
impl<Block> Move for BlockImportedNotification<Block>
impl<Block> RefUnwindSafe for BlockImportedNotification<Block>where
Block: RefUnwindSafe,
impl<Block> Send for BlockImportedNotification<Block>where
Block: Send,
impl<Block> Sync for BlockImportedNotification<Block>where
Block: Sync,
impl<Block> Unpin for BlockImportedNotification<Block>where
Block: Unpin,
impl<Block> UnsafeUnpin for BlockImportedNotification<Block>where
Block: UnsafeUnpin,
impl<Block> UnwindSafe for BlockImportedNotification<Block>where
Block: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more