We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
BestBlock
1 parent a254fcd commit 928c33fCopy full SHA for 928c33f
lightning/src/chain/mod.rs
@@ -38,15 +38,16 @@ pub struct BestBlock {
38
}
39
40
impl BestBlock {
41
- /// Returns the best block from the genesis of the given network.
+ /// Constructs a `BestBlock` that represents the genesis block at height 0 of the given
42
+ /// network.
43
pub fn from_genesis(network: Network) -> Self {
44
BestBlock {
45
block_hash: genesis_block(network).header.block_hash(),
46
height: 0,
47
48
49
- /// Returns the best block as identified by the given block hash and height.
50
+ /// Returns a `BestBlock` as identified by the given block hash and height.
51
pub fn new(block_hash: BlockHash, height: u32) -> Self {
52
BestBlock { block_hash, height }
53
0 commit comments