pub enum ChainHeadEvent {
Initialized {
finalized_block_hashes: Vec<Vec<u8>>,
finalized_block_runtime: Option<RuntimeInfo>,
},
NewBlock {
block_hash: Vec<u8>,
parent_block_hash: Vec<u8>,
new_runtime: Option<RuntimeInfo>,
},
BestBlockChanged {
best_block_hash: Vec<u8>,
},
Finalized {
finalized_block_hashes: Vec<Vec<u8>>,
pruned_block_hashes: Vec<Vec<u8>>,
},
OperationBodyDone {
operation_id: String,
value: Vec<Vec<u8>>,
},
OperationCallDone {
operation_id: String,
output: Vec<u8>,
},
OperationStorageItems {
operation_id: String,
items: Vec<StorageResultItem>,
},
OperationStorageDone {
operation_id: String,
},
OperationWaitingForContinue {
operation_id: String,
},
OperationInaccessible {
operation_id: String,
},
OperationError {
operation_id: String,
error: String,
},
Stop,
}Expand description
Strongly-typed representation of every chainHead_v1_followEvent variant.
Variants§
Initialized
tag 0 — initial state delivered immediately after follow subscription starts.
NewBlock
tag 1 — a new block has been added to the chain.
BestBlockChanged
tag 2 — the best block has changed.
Finalized
tag 3 — one or more blocks have been finalized.
OperationBodyDone
tag 4 — body operation completed.
OperationCallDone
tag 5 — call operation completed.
OperationStorageItems
tag 6 — storage operation delivered a batch of items.
OperationStorageDone
tag 7 — storage operation finished (no more items).
OperationWaitingForContinue
tag 8 — operation is paused; call continue to resume.
OperationInaccessible
tag 9 — operation could not be completed (block inaccessible).
OperationError
tag 10 — operation failed with an error message.
Stop
tag 11 — the follow subscription has been forcibly stopped by the server.
Trait Implementations§
Source§impl Clone for ChainHeadEvent
impl Clone for ChainHeadEvent
Source§fn clone(&self) -> ChainHeadEvent
fn clone(&self) -> ChainHeadEvent
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 moreAuto Trait Implementations§
impl Freeze for ChainHeadEvent
impl RefUnwindSafe for ChainHeadEvent
impl Send for ChainHeadEvent
impl Sync for ChainHeadEvent
impl Unpin for ChainHeadEvent
impl UnsafeUnpin for ChainHeadEvent
impl UnwindSafe for ChainHeadEvent
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