Bitcoin ABC 0.30.7
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 BlockHash &block_hash, std::vector< uint8_t > 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 BlockHash & | GetBlockHash () const |
const GCSFilter & | GetFilter () const |
const std::vector< uint8_t > & | 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 |
BlockHash | m_block_hash |
GCSFilter | m_filter |
Complete block filter struct as defined in BIP 157.
Serialization matches payload of "cfilter" messages.
Definition at line 111 of file blockfilter.h.
|
default |
BlockFilter::BlockFilter | ( | BlockFilterType | filter_type, |
const BlockHash & | block_hash, | ||
std::vector< uint8_t > | filter | ||
) |
Reconstruct a BlockFilter from parts.
Definition at line 220 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 231 of file blockfilter.cpp.
|
private |
Definition at line 241 of file blockfilter.cpp.
Compute the filter header given the previous one.
Definition at line 264 of file blockfilter.cpp.
|
inline |
|
inline |
Definition at line 134 of file blockfilter.h.
|
inline |
Definition at line 132 of file blockfilter.h.
|
inline |
uint256 BlockFilter::GetHash | ( | ) | const |
Compute the filter hash.
Definition at line 256 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.