pub struct BestBlock { /* private fields */ }Expand description
The best known block as identified by its hash and height.
Implementations§
source§impl BestBlock
impl BestBlock
sourcepub fn from_network(network: Network) -> Self
pub fn from_network(network: Network) -> Self
Constructs a BestBlock that represents the genesis block at height 0 of the given
network.
sourcepub fn new(block_hash: BlockHash, height: u32) -> Self
pub fn new(block_hash: BlockHash, height: u32) -> Self
Returns a BestBlock as identified by the given block hash and height.
sourcepub fn block_hash(&self) -> BlockHash
pub fn block_hash(&self) -> BlockHash
Returns the best block hash.