pub enum BlockchainWriteRequest {
WriteBlock(VerifiedBlockInformation),
BatchWriteBlocks(Vec<VerifiedBlockInformation>),
WriteAltBlock(AltBlockInformation),
PopBlocks(usize),
FlushAltBlocks,
}Expand description
A write request to the blockchain database.
Variants§
WriteBlock(VerifiedBlockInformation)
Request that a block be written to the database.
Input is an already verified block.
BatchWriteBlocks(Vec<VerifiedBlockInformation>)
Request that a batch of blocks be written to the database.
Input is an already verified batch of blocks.
WriteAltBlock(AltBlockInformation)
Write an alternative block to the database,
Input is the alternative block.
PopBlocks(usize)
A request to pop some blocks from the top of the main chain
Input is the amount of blocks to pop.
This request flushes all alt-chains from the cache before adding the popped blocks to the alt cache.
FlushAltBlocks
A request to flush all alternative blocks.
Trait Implementations§
Source§impl Clone for BlockchainWriteRequest
impl Clone for BlockchainWriteRequest
Source§fn clone(&self) -> BlockchainWriteRequest
fn clone(&self) -> BlockchainWriteRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BlockchainWriteRequest
impl Debug for BlockchainWriteRequest
impl Eq for BlockchainWriteRequest
Source§impl PartialEq for BlockchainWriteRequest
impl PartialEq for BlockchainWriteRequest
impl StructuralPartialEq for BlockchainWriteRequest
Auto Trait Implementations§
impl Freeze for BlockchainWriteRequest
impl RefUnwindSafe for BlockchainWriteRequest
impl Send for BlockchainWriteRequest
impl Sync for BlockchainWriteRequest
impl Unpin for BlockchainWriteRequest
impl UnsafeUnpin for BlockchainWriteRequest
impl UnwindSafe for BlockchainWriteRequest
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
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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> ⓘ
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> ⓘ
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§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 816 bytes
Size for each variant:
WriteBlock: 808 bytesBatchWriteBlocks: 24 bytesWriteAltBlock: 808 bytesPopBlocks: 8 bytesFlushAltBlocks: 0 bytes