SWC-DB  v0.5.12 C++ documentations
SWC-DB© (Super Wide Column Database) - High Performance Scalable Database (https://github.com/kashirin-alex/swc-db)
SWC::Ranger::CellStore::Block::Header Struct Referencefinal

#include <swcdb/ranger/db/CellStoreBlockHeader.h>

+ Collaboration diagram for SWC::Ranger::CellStore::Block::Header:

Public Member Functions

 Header (DB::Types::KeySeq key_seq) noexcept
 
 Header (const Header &other)
 
 Header (Header &&other) noexcept
 
 ~Header () noexcept
 
void encode (uint8_t **bufp)
 
void decode (const uint8_t **bufp, size_t *remainp)
 
size_t encoded_length_idx () const
 
void encode_idx (uint8_t **bufp) const
 
void decode_idx (const uint8_t **bufp, size_t *remainp)
 
void print (std::ostream &out) const
 

Public Attributes

uint64_t offset_data
 
DB::Cells::Interval interval
 
uint8_t is_any
 
DB::Types::Encoder encoder
 
uint32_t size_plain
 
uint32_t size_enc
 
uint32_t cells_count
 
uint32_t checksum_data
 

Static Public Attributes

static const uint8_t SIZE = 21
 
static const uint8_t ANY_BEGIN = 0x01
 
static const uint8_t ANY_END = 0x2
 

Detailed Description

Definition at line 23 of file CellStoreBlockHeader.h.

Constructor & Destructor Documentation

◆ Header() [1/3]

SWC_CAN_INLINE SWC::Ranger::CellStore::Block::Header::Header ( DB::Types::KeySeq  key_seq)
noexcept

Definition at line 15 of file CellStoreBlockHeader.cc.

◆ Header() [2/3]

SWC_CAN_INLINE SWC::Ranger::CellStore::Block::Header::Header ( const Header other)

Definition at line 27 of file CellStoreBlockHeader.cc.

◆ Header() [3/3]

SWC_CAN_INLINE SWC::Ranger::CellStore::Block::Header::Header ( Header &&  other)
noexcept

Definition at line 39 of file CellStoreBlockHeader.cc.

◆ ~Header()

SWC::Ranger::CellStore::Block::Header::~Header ( )
inlinenoexcept

Definition at line 45 of file CellStoreBlockHeader.h.

Member Function Documentation

◆ decode()

SWC_CAN_INLINE void SWC::Ranger::CellStore::Block::Header::decode ( const uint8_t **  bufp,
size_t *  remainp 
)

Definition at line 65 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, SWC::Serialization::decode_i32(), SWC::Serialization::decode_i8(), encoder, size_enc, and size_plain.

Referenced by SWC::Ranger::CellStore::Block::Read::load_header().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ decode_idx()

SWC_CAN_INLINE void SWC::Ranger::CellStore::Block::Header::decode_idx ( const uint8_t **  bufp,
size_t *  remainp 
)

Definition at line 98 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, SWC::DB::Cells::Interval::decode(), SWC::Serialization::decode_i8(), SWC::Serialization::decode_vi32(), SWC::Serialization::decode_vi64(), encoder, interval, is_any, offset_data, size_enc, and size_plain.

Referenced by SWC::Ranger::CellStore::Read::load_blocks_index().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ encode()

SWC_CAN_INLINE void SWC::Ranger::CellStore::Block::Header::encode ( uint8_t **  bufp)

Definition at line 51 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, SWC::Core::checksum_i32(), SWC::Serialization::encode_i32(), SWC::Serialization::encode_i8(), encoder, SIZE, size_enc, and size_plain.

Referenced by SWC::Ranger::CellStore::Block::Write::encode().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ encode_idx()

SWC_CAN_INLINE void SWC::Ranger::CellStore::Block::Header::encode_idx ( uint8_t **  bufp) const

Definition at line 86 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, SWC::DB::Cells::Interval::encode(), SWC::Serialization::encode_i8(), SWC::Serialization::encode_vi32(), SWC::Serialization::encode_vi64(), encoder, interval, is_any, offset_data, size_enc, and size_plain.

+ Here is the call graph for this function:

◆ encoded_length_idx()

SWC_CAN_INLINE size_t SWC::Ranger::CellStore::Block::Header::encoded_length_idx ( ) const

Definition at line 75 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, SWC::DB::Cells::Interval::encoded_length(), SWC::Serialization::encoded_length_vi32(), SWC::Serialization::encoded_length_vi64(), interval, offset_data, size_enc, and size_plain.

+ Here is the call graph for this function:

◆ print()

void SWC::Ranger::CellStore::Block::Header::print ( std::ostream &  out) const

Definition at line 109 of file CellStoreBlockHeader.cc.

References cells_count, checksum_data, encoder, interval, is_any, offset_data, size_enc, size_plain, and SWC::Core::Encoder::to_string().

Referenced by SWC::Ranger::CellStore::Block::Read::print(), and SWC::Ranger::CellStore::Block::Write::print().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ ANY_BEGIN

◆ ANY_END

◆ cells_count

◆ checksum_data

uint32_t SWC::Ranger::CellStore::Block::Header::checksum_data

◆ encoder

◆ interval

◆ is_any

◆ offset_data

uint64_t SWC::Ranger::CellStore::Block::Header::offset_data

◆ SIZE

const uint8_t SWC::Ranger::CellStore::Block::Header::SIZE = 21
static

◆ size_enc

◆ size_plain


The documentation for this struct was generated from the following files: