Bitcoin Core  22.99.0
P2P Digital Currency
Public Member Functions | Private Attributes | List of all members
SketchImpl< F > Class Template Referencefinal

#include <sketch_impl.h>

Inheritance diagram for SketchImpl< F >:
[legend]
Collaboration diagram for SketchImpl< F >:
[legend]

Public Member Functions

template<typename... Args>
 SketchImpl (int implementation, int bits, const Args &... args)
 
size_t Syndromes () const override
 
void Init (int count) override
 
void Add (uint64_t val) override
 
void Serialize (unsigned char *ptr) const override
 
void Deserialize (const unsigned char *ptr) override
 
int Decode (int max_count, uint64_t *out) const override
 
size_t Merge (const Sketch *other_sketch) override
 
void SetSeed (uint64_t seed) override
 
- Public Member Functions inherited from Sketch
 Sketch (int implementation, int bits)
 
void Ready ()
 
void Check () const
 
void UnReady ()
 
int Implementation () const
 
int Bits () const
 
virtual ~Sketch ()
 

Private Attributes

const F m_field
 
std::vector< typename F::Elem > m_syndromes
 
F::Elem m_basis
 

Detailed Description

template<typename F>
class SketchImpl< F >

Definition at line 354 of file sketch_impl.h.

Constructor & Destructor Documentation

◆ SketchImpl()

template<typename F >
template<typename... Args>
SketchImpl< F >::SketchImpl ( int  implementation,
int  bits,
const Args &...  args 
)
inline

Definition at line 362 of file sketch_impl.h.

Member Function Documentation

◆ Add()

template<typename F >
void SketchImpl< F >::Add ( uint64_t  val)
inlineoverridevirtual

Implements Sketch.

Definition at line 371 of file sketch_impl.h.

Here is the call graph for this function:

◆ Decode()

template<typename F >
int SketchImpl< F >::Decode ( int  max_count,
uint64_t *  out 
) const
inlineoverridevirtual

Implements Sketch.

Definition at line 394 of file sketch_impl.h.

Here is the call graph for this function:

◆ Deserialize()

template<typename F >
void SketchImpl< F >::Deserialize ( const unsigned char *  ptr)
inlineoverridevirtual

Implements Sketch.

Definition at line 386 of file sketch_impl.h.

◆ Init()

template<typename F >
void SketchImpl< F >::Init ( int  count)
inlineoverridevirtual

Implements Sketch.

Definition at line 369 of file sketch_impl.h.

◆ Merge()

template<typename F >
size_t SketchImpl< F >::Merge ( const Sketch other_sketch)
inlineoverridevirtual

Implements Sketch.

Definition at line 411 of file sketch_impl.h.

◆ Serialize()

template<typename F >
void SketchImpl< F >::Serialize ( unsigned char *  ptr) const
inlineoverridevirtual

Implements Sketch.

Definition at line 377 of file sketch_impl.h.

Here is the call graph for this function:

◆ SetSeed()

template<typename F >
void SketchImpl< F >::SetSeed ( uint64_t  seed)
inlineoverridevirtual

Implements Sketch.

Definition at line 423 of file sketch_impl.h.

◆ Syndromes()

template<typename F >
size_t SketchImpl< F >::Syndromes ( ) const
inlineoverridevirtual

Implements Sketch.

Definition at line 368 of file sketch_impl.h.

Member Data Documentation

◆ m_basis

template<typename F >
F::Elem SketchImpl< F >::m_basis
private

Definition at line 358 of file sketch_impl.h.

◆ m_field

template<typename F >
const F SketchImpl< F >::m_field
private

Definition at line 356 of file sketch_impl.h.

◆ m_syndromes

template<typename F >
std::vector<typename F::Elem> SketchImpl< F >::m_syndromes
private

Definition at line 357 of file sketch_impl.h.


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