MCPcopy Create free account
hub / github.com/QMHTMY/RustBook / BlockHeader

Class BlockHeader

code/chapter09/blockchain/blockchain2/core/src/block.rs:8–14  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6// 区块头
7#[derive(Serialize, Debug, PartialEq, Eq)]
8pub struct BlockHeader {
9 pub nonce: u32,
10 pub bits: u32,
11 pub time: i64,
12 pub txs_hash: String,
13 pub pre_hash: String,
14}
15
16// 区块
17#[derive(Debug)]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected