kernel::ComputeUTXOStats

Computes aggregate statistics over the UTXO set.

Synopsis

Declared in <kernel/coinstats.h>

std::optional<CCoinsStats>
ComputeUTXOStats(
    CoinStatsHashType hash_type,
    CCoinsViewDB const& view,
    node::BlockManager& blockman,
    std::function<void()> const& interruption_point = {});

Return Value

The computed statistics, or std::nullopt on failure.

Parameters

NameDescription
hash_typeThe hashing scheme used to summarize the set.
viewThe UTXO database to read from.
blockmanThe block manager providing block data.
interruption_pointCallback invoked to allow the computation to be interrupted.