![]() |
Bitcoin Core 22.99.0
P2P Digital Currency
|
Complete block filter struct as defined in BIP 157. More...
#include <blockfilter.h>
Public Member Functions | |
| BlockFilter ()=default | |
| BlockFilter (BlockFilterType filter_type, const uint256 &block_hash, std::vector< unsigned char > filter) | |
| Reconstruct a BlockFilter from parts. More... | |
| BlockFilter (BlockFilterType filter_type, const CBlock &block, const CBlockUndo &block_undo) | |
| Construct a new BlockFilter of the specified type from a block. More... | |
| BlockFilterType | GetFilterType () const |
| const uint256 & | GetBlockHash () const |
| const GCSFilter & | GetFilter () const |
| const std::vector< unsigned char > & | GetEncodedFilter () const |
| uint256 | GetHash () const |
| Compute the filter hash. More... | |
| uint256 | ComputeHeader (const uint256 &prev_header) const |
| Compute the filter header given the previous one. More... | |
| template<typename Stream > | |
| void | Serialize (Stream &s) const |
| template<typename Stream > | |
| void | Unserialize (Stream &s) |
Private Member Functions | |
| bool | BuildParams (GCSFilter::Params ¶ms) const |
Private Attributes | |
| BlockFilterType | m_filter_type = BlockFilterType::INVALID |
| uint256 | m_block_hash |
| GCSFilter | m_filter |
Complete block filter struct as defined in BIP 157.
Serialization matches payload of "cfilter" messages.
Definition at line 110 of file blockfilter.h.
|
default |
| BlockFilter::BlockFilter | ( | BlockFilterType | filter_type, |
| const uint256 & | block_hash, | ||
| std::vector< unsigned char > | filter | ||
| ) |
Reconstruct a BlockFilter from parts.
Definition at line 252 of file blockfilter.cpp.
| BlockFilter::BlockFilter | ( | BlockFilterType | filter_type, |
| const CBlock & | block, | ||
| const CBlockUndo & | block_undo | ||
| ) |
Construct a new BlockFilter of the specified type from a block.
Definition at line 263 of file blockfilter.cpp.
|
private |
Definition at line 273 of file blockfilter.cpp.
Compute the filter header given the previous one.
Definition at line 298 of file blockfilter.cpp.
|
inline |
|
inline |
Definition at line 134 of file blockfilter.h.
|
inline |
|
inline |
| uint256 BlockFilter::GetHash | ( | ) | const |
Compute the filter hash.
Definition at line 289 of file blockfilter.cpp.
|
inline |
|
inline |
|
private |
Definition at line 114 of file blockfilter.h.
|
private |
Definition at line 115 of file blockfilter.h.
|
private |
Definition at line 113 of file blockfilter.h.