pub struct BlockchainNode {
    pub block: Block,
    pub total_work: Uint256,
    pub required_difficulty: Uint256,
    pub height: u32,
    pub has_txdata: bool,
    /* private fields */
}
Expand description

A link in the blockchain

Fields§

§block: Block

The actual block

§total_work: Uint256

Total work from genesis to this point

§required_difficulty: Uint256

Expected value of block.header.bits for this block; only changes every blockdata::constants::DIFFCHANGE_INTERVAL; blocks

§height: u32

Height above genesis

§has_txdata: bool

Whether the transaction data is stored

Implementations§

Is the node on the main chain?

Trait Implementations§

Produces a Sha256dHash which can be used to refer to the object
Decode an object with a well-defined format
Encode an object with a well-defined format

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.