pub struct AltBlockInformation {
pub block: Block,
pub block_blob: Vec<u8>,
pub txs: Vec<VerifiedTransactionInformation>,
pub block_hash: [u8; 32],
pub pow_hash: [u8; 32],
pub height: usize,
pub weight: usize,
pub long_term_weight: usize,
pub cumulative_difficulty: u128,
pub chain_id: ChainId,
}Expand description
A block on an alternative chain.
Fields§
§block: BlockThe block itself.
block_blob: Vec<u8>The serialized byte form of Self::block.
[Block::serialize].
txs: Vec<VerifiedTransactionInformation>All the transactions in the block, excluding the [Block::miner_transaction].
block_hash: [u8; 32]The block’s hash.
[Block::hash].
pow_hash: [u8; 32]The block’s proof-of-work hash.
height: usizeThe block’s height.
weight: usizeThe adjusted block size, in bytes.
long_term_weight: usizeThe long term block weight, which is the weight factored in with previous block weights.
cumulative_difficulty: u128The cumulative difficulty of all blocks up until and including this block.
chain_id: ChainIdThe ChainId of the chain this alt block is on.
Trait Implementations§
Source§impl Clone for AltBlockInformation
impl Clone for AltBlockInformation
Source§fn clone(&self) -> AltBlockInformation
fn clone(&self) -> AltBlockInformation
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 AltBlockInformation
impl Debug for AltBlockInformation
impl Eq for AltBlockInformation
Source§impl PartialEq for AltBlockInformation
impl PartialEq for AltBlockInformation
impl StructuralPartialEq for AltBlockInformation
Auto Trait Implementations§
impl Freeze for AltBlockInformation
impl RefUnwindSafe for AltBlockInformation
impl Send for AltBlockInformation
impl Sync for AltBlockInformation
impl Unpin for AltBlockInformation
impl UnsafeUnpin for AltBlockInformation
impl UnwindSafe for AltBlockInformation
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: 800 bytes