Bitcoin Core  27.99.0
P2P Digital Currency
Public Member Functions | Public Attributes | Private Attributes | List of all members
node::SnapshotMetadata Class Reference

Metadata describing a serialized version of a UTXO set from which an assumeutxo Chainstate can be constructed. More...

#include <utxo_snapshot.h>

Collaboration diagram for node::SnapshotMetadata:
[legend]

Public Member Functions

 SnapshotMetadata (const MessageStartChars network_magic)
 
 SnapshotMetadata (const MessageStartChars network_magic, const uint256 &base_blockhash, const int base_blockheight, uint64_t coins_count)
 
template<typename Stream >
void Serialize (Stream &s) const
 
template<typename Stream >
void Unserialize (Stream &s)
 

Public Attributes

uint256 m_base_blockhash
 The hash of the block that reflects the tip of the chain for the UTXO set contained in this snapshot. More...
 
uint32_t m_base_blockheight
 
uint64_t m_coins_count = 0
 The number of coins in the UTXO set contained in this snapshot. More...
 

Private Attributes

const uint16_t m_version {1}
 
const std::set< uint16_t > m_supported_versions {1}
 
const MessageStartChars m_network_magic
 

Detailed Description

Metadata describing a serialized version of a UTXO set from which an assumeutxo Chainstate can be constructed.

Definition at line 31 of file utxo_snapshot.h.

Constructor & Destructor Documentation

◆ SnapshotMetadata() [1/2]

node::SnapshotMetadata::SnapshotMetadata ( const MessageStartChars  network_magic)
inline

Definition at line 47 of file utxo_snapshot.h.

◆ SnapshotMetadata() [2/2]

node::SnapshotMetadata::SnapshotMetadata ( const MessageStartChars  network_magic,
const uint256 base_blockhash,
const int  base_blockheight,
uint64_t  coins_count 
)
inline

Definition at line 50 of file utxo_snapshot.h.

Member Function Documentation

◆ Serialize()

template<typename Stream >
void node::SnapshotMetadata::Serialize ( Stream &  s) const
inline

Definition at line 61 of file utxo_snapshot.h.

◆ Unserialize()

template<typename Stream >
void node::SnapshotMetadata::Unserialize ( Stream &  s)
inline

Definition at line 71 of file utxo_snapshot.h.

Here is the call graph for this function:

Member Data Documentation

◆ m_base_blockhash

uint256 node::SnapshotMetadata::m_base_blockhash

The hash of the block that reflects the tip of the chain for the UTXO set contained in this snapshot.

Definition at line 39 of file utxo_snapshot.h.

◆ m_base_blockheight

uint32_t node::SnapshotMetadata::m_base_blockheight

Definition at line 40 of file utxo_snapshot.h.

◆ m_coins_count

uint64_t node::SnapshotMetadata::m_coins_count = 0

The number of coins in the UTXO set contained in this snapshot.

Used during snapshot load to estimate progress of UTXO set reconstruction.

Definition at line 45 of file utxo_snapshot.h.

◆ m_network_magic

const MessageStartChars node::SnapshotMetadata::m_network_magic
private

Definition at line 35 of file utxo_snapshot.h.

◆ m_supported_versions

const std::set<uint16_t> node::SnapshotMetadata::m_supported_versions {1}
private

Definition at line 34 of file utxo_snapshot.h.

◆ m_version

const uint16_t node::SnapshotMetadata::m_version {1}
private

Definition at line 33 of file utxo_snapshot.h.


The documentation for this class was generated from the following file: