[#kernel-ComputeUTXOStats]
= xref:kernel.adoc[kernel]::ComputeUTXOStats
:relfileprefix: ../
:mrdocs:

Computes aggregate statistics over the UTXO set&period;

== Synopsis

Declared in `&lt;kernel&sol;coinstats&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
std::optional&lt;CCoinsStats&gt;
ComputeUTXOStats(
    xref:kernel/CoinStatsHashType.adoc[CoinStatsHashType] hash&lowbar;type,
    xref:CCoinsViewDB.adoc[CCoinsViewDB] const& view,
    xref:node/BlockManager.adoc[node::BlockManager]& blockman,
    std::function&lt;void()&gt; const& interruption&lowbar;point = &lcub;&rcub;);
----

== Return Value

The computed statistics, or `std&colon;&colon;nullopt` on failure&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *hash&lowbar;type*
| The hashing scheme used to summarize the set&period;
| *view*
| The UTXO database to read from&period;
| *blockman*
| The block manager providing block data&period;
| *interruption&lowbar;point*
| Callback invoked to allow the computation to be interrupted&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
