![]() |
PIVX Core
5.6.99
P2P Digital Currency
|
The block chain is a tree shaped structure starting with the genesis block at the root, with each block potentially having multiple candidates to be the next block. More...
#include <chain.h>
Public Member Functions | |
| CBlockIndex () | |
| CBlockIndex (const CBlock &block) | |
| std::string | ToString () const |
| FlatFilePos | GetBlockPos () const |
| FlatFilePos | GetUndoPos () const |
| CBlockHeader | GetBlockHeader () const |
| uint256 | GetBlockHash () const |
| int64_t | GetBlockTime () const |
| int64_t | GetBlockTimeMax () const |
| int64_t | GetMedianTimePast () const |
| int64_t | MaxFutureBlockTime () const |
| int64_t | MinPastBlockTime () const |
| bool | IsProofOfStake () const |
| bool | IsProofOfWork () const |
| void | SetProofOfStake () |
| unsigned int | GetStakeEntropyBit () const |
| bool | SetStakeEntropyBit (unsigned int nEntropyBit) |
| bool | GeneratedStakeModifier () const |
| void | SetStakeModifier (const uint64_t nStakeModifier, bool fGeneratedStakeModifier) |
| void | SetNewStakeModifier () |
| void | SetStakeModifier (const uint256 &nStakeModifier) |
| void | SetNewStakeModifier (const uint256 &prevoutId) |
| uint64_t | GetStakeModifierV1 () const |
| uint256 | GetStakeModifierV2 () const |
| void | SetChainSaplingValue () |
| bool | IsValid (enum BlockStatus nUpTo=BLOCK_VALID_TRANSACTIONS) const |
| Check whether this block index entry is valid up to the passed validity level. More... | |
| bool | RaiseValidity (enum BlockStatus nUpTo) |
| Raise the validity level of this block index entry. More... | |
| void | BuildSkip () |
| Build the skiplist pointer for this entry. More... | |
| CBlockIndex * | GetAncestor (int height) |
| Efficiently find an ancestor of this block. More... | |
| const CBlockIndex * | GetAncestor (int height) const |
Public Attributes | |
| const uint256 * | phashBlock {nullptr} |
| pointer to the hash of the block, if any. memory is owned by this CBlockIndex More... | |
| CBlockIndex * | pprev {nullptr} |
| pointer to the index of the predecessor of this block More... | |
| CBlockIndex * | pskip {nullptr} |
| pointer to the index of some further predecessor of this block More... | |
| int | nHeight {0} |
| height of the entry in the chain. The genesis block has height 0 More... | |
| int | nFile {0} |
| Which # file this block is stored in (blk?????.dat) More... | |
| unsigned int | nDataPos {0} |
| Byte offset within blk?????.dat where this block's data is stored. More... | |
| unsigned int | nUndoPos {0} |
| Byte offset within rev?????.dat where this block's undo data is stored. More... | |
| arith_uint256 | nChainWork {} |
| (memory only) Total amount of work (expected number of hashes) in the chain up to and including this block More... | |
| unsigned int | nTx {0} |
| Number of transactions in this block. More... | |
| unsigned int | nChainTx {0} |
| (memory only) Number of transactions in the chain up to and including this block. More... | |
| uint32_t | nStatus {0} |
| Verification status of this block. See enum BlockStatus. More... | |
| std::vector< unsigned char > | vStakeModifier {} |
| unsigned int | nFlags {0} |
| CAmount | nSaplingValue {0} |
| Change in value held by the Sapling circuit over this block. More... | |
| Optional< CAmount > | nChainSaplingValue {nullopt} |
| (memory only) Total value held by the Sapling circuit up to and including this block. More... | |
| int32_t | nVersion {0} |
| block header More... | |
| uint256 | hashMerkleRoot {} |
| uint256 | hashFinalSaplingRoot {} |
| uint32_t | nTime {0} |
| uint32_t | nBits {0} |
| uint32_t | nNonce {0} |
| uint256 | nAccumulatorCheckpoint {} |
| uint32_t | nSequenceId {0} |
| (memory only) Sequential id assigned to distinguish order in which blocks are received. More... | |
| unsigned int | nTimeMax {0} |
| (memory only) Maximum nTime in the chain upto and including this block. More... | |
The block chain is a tree shaped structure starting with the genesis block at the root, with each block potentially having multiple candidates to be the next block.
A blockindex may have multiple pprev pointing to it, but at most one of them can be part of the currently active branch.
|
explicit |
| void CBlockIndex::BuildSkip | ( | ) |
|
inline |
| CBlockIndex * CBlockIndex::GetAncestor | ( | int | height | ) |
| const CBlockIndex * CBlockIndex::GetAncestor | ( | int | height | ) | const |
| CBlockHeader CBlockIndex::GetBlockHeader | ( | ) | const |
| FlatFilePos CBlockIndex::GetBlockPos | ( | ) | const |
|
inline |
|
inline |
| int64_t CBlockIndex::GetMedianTimePast | ( | ) | const |
| unsigned int CBlockIndex::GetStakeEntropyBit | ( | ) | const |
| uint64_t CBlockIndex::GetStakeModifierV1 | ( | ) | const |
| uint256 CBlockIndex::GetStakeModifierV2 | ( | ) | const |
| FlatFilePos CBlockIndex::GetUndoPos | ( | ) | const |
|
inline |
|
inline |
| bool CBlockIndex::IsValid | ( | enum BlockStatus | nUpTo = BLOCK_VALID_TRANSACTIONS | ) | const |
| int64_t CBlockIndex::MaxFutureBlockTime | ( | ) | const |
| int64_t CBlockIndex::MinPastBlockTime | ( | ) | const |
| bool CBlockIndex::RaiseValidity | ( | enum BlockStatus | nUpTo | ) |
| void CBlockIndex::SetNewStakeModifier | ( | ) |
| void CBlockIndex::SetNewStakeModifier | ( | const uint256 & | prevoutId | ) |
|
inline |
| bool CBlockIndex::SetStakeEntropyBit | ( | unsigned int | nEntropyBit | ) |
| void CBlockIndex::SetStakeModifier | ( | const uint256 & | nStakeModifier | ) |
| void CBlockIndex::SetStakeModifier | ( | const uint64_t | nStakeModifier, |
| bool | fGeneratedStakeModifier | ||
| ) |
| std::string CBlockIndex::ToString | ( | ) | const |
| unsigned int CBlockIndex::nChainTx {0} |
| arith_uint256 CBlockIndex::nChainWork {} |
| unsigned int CBlockIndex::nDataPos {0} |
| int CBlockIndex::nFile {0} |
| int CBlockIndex::nHeight {0} |
| CAmount CBlockIndex::nSaplingValue {0} |
| uint32_t CBlockIndex::nSequenceId {0} |
| uint32_t CBlockIndex::nStatus {0} |
| unsigned int CBlockIndex::nTimeMax {0} |
| unsigned int CBlockIndex::nTx {0} |
| unsigned int CBlockIndex::nUndoPos {0} |
| const uint256* CBlockIndex::phashBlock {nullptr} |
pointer to the hash of the block, if any. memory is owned by this CBlockIndex
| CBlockIndex* CBlockIndex::pprev {nullptr} |
| CBlockIndex* CBlockIndex::pskip {nullptr} |