BlockHeader class

Interface for block header with BlockHeader.nonce varied by PeerNetwork miners

Implementers

Constructors

BlockHeader()

Properties

chainWork BlockId
Total cumulative chain work. blockWork(genesisBock) + deltaWork(genesisBlock).
read-only
dateTime DateTime
Time this block was mined.
read-only
hashCode int
The hash code for this object. [...]
read-only, inherited
hashListRoot TransactionId
Checksum of all the transaction in this block.
read-only
height int
The BlockHeader.height of previous plus one.
read-only
nonce int
Parameter varied by miners for Proof of Work.
read-only
previous BlockId
ID of the previous block in this chain.
read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
target BlockId
Threshold new Block must hash under for Proof of Work.
read-only
transactionCount int
The number of transactions in this block. Strictly positive if coinbase transactions are required.
read-only

Methods

blockWork() BigInt
Expected number of random hashes before mining this block.
deltaTime(BlockHeader x) Duration
Difference in time between x and this block.
deltaWork(BlockHeader x) BigInt
Difference in work between x and this block.
hashRate(BlockHeader x) int
Expected hashes per second from x to this block.
id() BlockId
Computes an ID for this block.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toJson() Map<String, dynamic>
Marshals this BlockHeader as a JSON-encoded string.
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited

Static Methods

compareHeight(dynamic a, dynamic b) int
Compare BlockHeader.height of a and b.