SWC-DB  v0.5.11 C++ documentations
SWC-DB© (Super Wide Column Database) - High Performance Scalable Database (https://github.com/kashirin-alex/swc-db)
SWC::DB::Cell::KeyVec Class Referencefinal

#include <swcdb/db/Cells/CellKeyVec.h>

+ Inheritance diagram for SWC::DB::Cell::KeyVec:
+ Collaboration diagram for SWC::DB::Cell::KeyVec:

Public Types

typedef VecFraction::value_type Fraction
 
- Public Types inherited from SWC::Core::Vector< T, SizeT, GROW_SZ >
using value_type = T
 
using size_type = SizeT
 
typedef value_typepointer
 
typedef const value_typeconst_pointer
 
typedef value_typeiterator
 
typedef const value_typeconst_iterator
 
typedef value_typereference
 
typedef const value_typeconst_reference
 

Public Member Functions

SWC_CAN_INLINE KeyVec () noexcept
 
SWC_CAN_INLINE KeyVec (KeyVec &&other) noexcept
 
 KeyVec (const KeyVec &other)
 
 ~KeyVec () noexcept
 
SWC_CAN_INLINE size_t size_of_internal () const noexcept
 
KeyVecoperator= (const KeyVec &)=delete
 
void copy (const KeyVec &other)
 
bool equal (const KeyVec &other) const noexcept
 
SWC_CAN_INLINE void add (const Fraction &fraction)
 
SWC_CAN_INLINE void add (const std::string &fraction)
 
SWC_CAN_INLINE void add (const char *fraction)
 
SWC_CAN_INLINE void add (const char *fraction, const uint32_t len)
 
void add (const uint8_t *fraction, const uint32_t len)
 
SWC_CAN_INLINE void insert (const uint32_t idx, const Fraction &fraction)
 
SWC_CAN_INLINE void insert (const uint32_t idx, const std::string &fraction)
 
SWC_CAN_INLINE void insert (const uint32_t idx, const char *fraction)
 
SWC_CAN_INLINE void insert (const uint32_t idx, const char *fraction, const uint32_t len)
 
void insert (const uint32_t idx, const uint8_t *fraction, const uint32_t len)
 
SWC_CAN_INLINE void set (const uint32_t idx, const Fraction &fraction)
 
SWC_CAN_INLINE void set (const uint32_t idx, const std::string &fraction)
 
SWC_CAN_INLINE void set (const uint32_t idx, const char *fraction)
 
SWC_CAN_INLINE void set (const uint32_t idx, const char *fraction, const uint32_t len)
 
void set (const uint32_t idx, const uint8_t *fraction, const uint32_t len)
 
void remove (const uint32_t idx)
 
SWC_CAN_INLINE const Fractionget (const uint32_t idx) const
 
SWC_CAN_INLINE void get (const uint32_t idx, Fraction &fraction) const
 
SWC_CAN_INLINE void get (const uint32_t idx, std::string &fraction) const
 
uint32_t encoded_length () const noexcept
 
void encode (uint8_t **bufp) const
 
void decode (const uint8_t **bufp, size_t *remainp)
 
SWC_CAN_INLINE std::string to_string () const
 
void print (std::ostream &out) const
 
constexpr SWC_CAN_INLINE size_type size () const noexcept
 
- Public Member Functions inherited from SWC::Core::Vector< T, SizeT, GROW_SZ >
constexpr SWC_CAN_INLINE Vector () noexcept
 
template<typename... ArgsT>
SWC_CAN_INLINE Vector (size_type sz, ArgsT &&... args)
 
constexpr SWC_CAN_INLINE Vector (Vector &&other) noexcept
 
SWC_CAN_INLINE Vector (const Vector &other)
 
SWC_CAN_INLINE Vector (const_iterator _b, const_iterator _e)
 
SWC_CAN_INLINE Vector (std::initializer_list< value_type > &&l)
 
SWC_CAN_INLINE ~Vector () noexcept(_NoExceptDestructor)
 
SWC_CAN_INLINE void clear () noexcept(_NoExceptDestructor)
 
SWC_CAN_INLINE void free () noexcept
 
SWC_CAN_INLINE Vectoroperator= (Vector &&other) noexcept
 
SWC_CAN_INLINE Vectoroperator= (const Vector &other)
 
SWC_CAN_INLINE void swap (Vector &other) noexcept
 
constexpr SWC_CAN_INLINE bool empty () const noexcept
 
constexpr SWC_CAN_INLINE bool operator== (const Vector &other) const noexcept
 
constexpr SWC_CAN_INLINE bool operator!= (const Vector &other) const noexcept
 
constexpr SWC_CAN_INLINE size_type size () const noexcept
 
constexpr SWC_CAN_INLINE size_type capacity () const noexcept
 
constexpr SWC_CAN_INLINE pointer data () noexcept
 
constexpr SWC_CAN_INLINE const_pointer data () const noexcept
 
constexpr SWC_CAN_INLINE iterator begin () noexcept
 
constexpr SWC_CAN_INLINE const_iterator cbegin () const noexcept
 
constexpr SWC_CAN_INLINE const_iterator begin () const noexcept
 
constexpr SWC_CAN_INLINE iterator end () noexcept
 
constexpr SWC_CAN_INLINE const_iterator cend () const noexcept
 
constexpr SWC_CAN_INLINE const_iterator end () const noexcept
 
constexpr SWC_CAN_INLINE reference front () noexcept
 
constexpr SWC_CAN_INLINE const_reference front () const noexcept
 
constexpr SWC_CAN_INLINE reference back () noexcept
 
constexpr SWC_CAN_INLINE const_reference back () const noexcept
 
constexpr SWC_CAN_INLINE reference operator[] (size_type pos) noexcept
 
constexpr SWC_CAN_INLINE const_reference operator[] (size_type pos) const noexcept
 
SWC_CAN_INLINE void shrink_to_fit (size_type sz=0)
 
SWC_CAN_INLINE void reserve (size_type cap)
 
SWC_CAN_INLINE void reserve ()
 
template<typename... ArgsT>
SWC_CAN_INLINE void resize (size_type sz, ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE void push_back (ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE void push_back_unsafe (ArgsT &&... args) noexcept(std::is_nothrow_constructible_v< value_type, ArgsT... >)
 
template<typename... ArgsT>
SWC_CAN_INLINE reference emplace_back (ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE reference emplace_back_unsafe (ArgsT &&... args) noexcept(std::is_nothrow_constructible_v< value_type, ArgsT... >)
 
template<typename... ArgsT>
SWC_CAN_INLINE iterator insert (size_type offset, ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE iterator insert (const_iterator it, ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE reference emplace (const_iterator it, ArgsT &&... args)
 
template<typename... ArgsT>
SWC_CAN_INLINE iterator insert_unsafe (const_iterator it, ArgsT &&... args) noexcept(_NoExceptMove &&_NoExceptDestructor &&std::is_nothrow_constructible_v< value_type, ArgsT... >)
 
SWC_CAN_INLINE iterator insert (size_type offset, const_iterator first, const_iterator last)
 
SWC_CAN_INLINE iterator insert (const_iterator it, const_iterator first, const_iterator last)
 
template<typename IteratorT >
SWC_CAN_INLINE void assign (IteratorT first, IteratorT last)
 
SWC_CAN_INLINE iterator erase (size_type offset) noexcept(_NoExceptMoveAssign &&_NoExceptDestructor)
 
SWC_CAN_INLINE iterator erase (const_iterator it) noexcept(_NoExceptMoveAssign &&_NoExceptDestructor)
 
SWC_CAN_INLINE iterator erase (const_iterator first, const_iterator last) noexcept(_NoExceptMoveAssign &&_NoExceptDestructor)
 
SWC_CAN_INLINE void pop_back () noexcept(_NoExceptDestructor)
 

Friends

std::ostream & operator<< (std::ostream &out, const KeyVec &key)
 

Additional Inherited Members

- Static Public Member Functions inherited from SWC::Core::Vector< T, SizeT, GROW_SZ >
constexpr static SWC_CAN_INLINE size_type max_size () noexcept
 

Detailed Description

Definition at line 21 of file CellKeyVec.h.

Member Typedef Documentation

◆ Fraction

Constructor & Destructor Documentation

◆ KeyVec() [1/3]

SWC_CAN_INLINE SWC::DB::Cell::KeyVec::KeyVec ( )
inlineexplicitnoexcept

Definition at line 29 of file CellKeyVec.h.

◆ KeyVec() [2/3]

SWC_CAN_INLINE SWC::DB::Cell::KeyVec::KeyVec ( KeyVec &&  other)
inlineexplicitnoexcept

Definition at line 32 of file CellKeyVec.h.

◆ KeyVec() [3/3]

SWC_CAN_INLINE SWC::DB::Cell::KeyVec::KeyVec ( const KeyVec other)
explicit

Definition at line 171 of file CellKeyVec.h.

◆ ~KeyVec()

SWC::DB::Cell::KeyVec::~KeyVec ( )
inlinenoexcept

Definition at line 38 of file CellKeyVec.h.

Member Function Documentation

◆ add() [1/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::add ( const char *  fraction)
inline

Definition at line 67 of file CellKeyVec.h.

References add().

+ Here is the call graph for this function:

◆ add() [2/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::add ( const char *  fraction,
const uint32_t  len 
)
inline

Definition at line 72 of file CellKeyVec.h.

References add().

+ Here is the call graph for this function:

◆ add() [3/5]

◆ add() [4/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::add ( const std::string &  fraction)
inline

Definition at line 62 of file CellKeyVec.h.

References add().

+ Here is the call graph for this function:

◆ add() [5/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::add ( const uint8_t *  fraction,
const uint32_t  len 
)

Definition at line 187 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::emplace_back().

+ Here is the call graph for this function:

◆ copy()

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::copy ( const KeyVec other)

Definition at line 176 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::assign(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cend(), and SWC::Core::Vector< T, SizeT, GROW_SZ >::clear().

Referenced by SWC::Common::Query::Update::Metric::Item_Mem::definitions(), SWC::Common::Query::Update::Metric::Item_CPU::definitions(), SWC::Common::Query::Update::Metric::Item_FS::definitions(), SWC::FsBroker::Metric::Item_Fds::definitions(), SWC::client::Query::Update::Handlers::Metric::Level::definitions(), SWC::Ranger::Range::expand_and_align(), SWC::Common::Query::Update::Metric::Item_Net< SWC::Comm::Protocol::FsBroker::Commands >::report(), SWC::Common::Query::Update::Metric::Item_Mem::report(), SWC::Common::Query::Update::Metric::Item_CPU::report(), SWC::client::Query::Update::Handlers::Metric::Level::report(), SWC::client::Query::Update::Handlers::Metric::Item_MinMaxAvgCount::report(), SWC::client::Query::Update::Handlers::Metric::Item_Count::report(), SWC::client::Query::Update::Handlers::Metric::Item_Volume::report(), SWC::client::Query::Update::Handlers::Metric::Item_CountVolume::report(), SWC::DB::Cells::Interval::set_aligned_max(), and SWC::DB::Cells::Interval::set_aligned_min().

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

◆ decode()

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::decode ( const uint8_t **  bufp,
size_t *  remainp 
)

Definition at line 229 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::begin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cend(), SWC::Core::Vector< T, SizeT, GROW_SZ >::clear(), SWC::Serialization::decode_vi32(), and SWC::Core::Vector< T, SizeT, GROW_SZ >::resize().

Referenced by SWC::Ranger::Range::check_meta(), and SWC::DB::Cells::Interval::decode().

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

◆ encode()

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::encode ( uint8_t **  bufp) const

Definition at line 218 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cend(), SWC::Serialization::encode_vi32(), and size().

Referenced by SWC::DB::Cells::Interval::encode().

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

◆ encoded_length()

SWC_CAN_INLINE uint32_t SWC::DB::Cell::KeyVec::encoded_length ( ) const
noexcept

Definition at line 210 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cend(), SWC::Serialization::encoded_length_vi32(), and size().

Referenced by SWC::DB::Cells::Interval::encoded_length().

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

◆ equal()

SWC_CAN_INLINE bool SWC::DB::Cell::KeyVec::equal ( const KeyVec other) const
noexcept

Definition at line 182 of file CellKeyVec.h.

Referenced by SWC::Ranger::Range::expand_and_align().

+ Here is the caller graph for this function:

◆ get() [1/3]

SWC_CAN_INLINE const Fraction& SWC::DB::Cell::KeyVec::get ( const uint32_t  idx) const
inline

Definition at line 125 of file CellKeyVec.h.

◆ get() [2/3]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::get ( const uint32_t  idx,
Fraction fraction 
) const
inline

Definition at line 130 of file CellKeyVec.h.

◆ get() [3/3]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::get ( const uint32_t  idx,
std::string &  fraction 
) const
inline

Definition at line 135 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::data(), and size().

+ Here is the call graph for this function:

◆ insert() [1/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::insert ( const uint32_t  idx,
const char *  fraction 
)
inline

Definition at line 89 of file CellKeyVec.h.

References insert().

+ Here is the call graph for this function:

◆ insert() [2/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::insert ( const uint32_t  idx,
const char *  fraction,
const uint32_t  len 
)
inline

Definition at line 94 of file CellKeyVec.h.

References insert().

+ Here is the call graph for this function:

◆ insert() [3/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::insert ( const uint32_t  idx,
const Fraction fraction 
)
inline

Definition at line 79 of file CellKeyVec.h.

Referenced by insert().

+ Here is the caller graph for this function:

◆ insert() [4/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::insert ( const uint32_t  idx,
const std::string &  fraction 
)
inline

Definition at line 84 of file CellKeyVec.h.

References insert().

+ Here is the call graph for this function:

◆ insert() [5/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::insert ( const uint32_t  idx,
const uint8_t *  fraction,
const uint32_t  len 
)

Definition at line 192 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), and SWC::Core::Vector< T, SizeT, GROW_SZ >::emplace().

+ Here is the call graph for this function:

◆ operator=()

KeyVec& SWC::DB::Cell::KeyVec::operator= ( const KeyVec )
delete

◆ print()

void SWC::DB::Cell::KeyVec::print ( std::ostream &  out) const

Definition at line 13 of file CellKeyVec.cc.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::cend(), and size().

Referenced by to_string().

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

◆ remove()

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::remove ( const uint32_t  idx)

Definition at line 204 of file CellKeyVec.h.

References SWC::Core::Vector< T, SizeT, GROW_SZ >::cbegin(), SWC::Core::Vector< T, SizeT, GROW_SZ >::erase(), and size().

Referenced by SWC::Ranger::Range::check_meta().

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

◆ set() [1/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::set ( const uint32_t  idx,
const char *  fraction 
)
inline

Definition at line 111 of file CellKeyVec.h.

References set().

+ Here is the call graph for this function:

◆ set() [2/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::set ( const uint32_t  idx,
const char *  fraction,
const uint32_t  len 
)
inline

Definition at line 116 of file CellKeyVec.h.

References set().

+ Here is the call graph for this function:

◆ set() [3/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::set ( const uint32_t  idx,
const Fraction fraction 
)
inline

Definition at line 101 of file CellKeyVec.h.

Referenced by set().

+ Here is the caller graph for this function:

◆ set() [4/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::set ( const uint32_t  idx,
const std::string &  fraction 
)
inline

Definition at line 106 of file CellKeyVec.h.

References set().

+ Here is the call graph for this function:

◆ set() [5/5]

SWC_CAN_INLINE void SWC::DB::Cell::KeyVec::set ( const uint32_t  idx,
const uint8_t *  fraction,
const uint32_t  len 
)

Definition at line 198 of file CellKeyVec.h.

◆ size()

◆ size_of_internal()

SWC_CAN_INLINE size_t SWC::DB::Cell::KeyVec::size_of_internal ( ) const
inlinenoexcept

Definition at line 41 of file CellKeyVec.h.

Referenced by SWC::DB::Cells::Interval::size_of_internal().

+ Here is the caller graph for this function:

◆ to_string()

SWC_CAN_INLINE std::string SWC::DB::Cell::KeyVec::to_string ( ) const
inline

Definition at line 149 of file CellKeyVec.h.

References print().

+ Here is the call graph for this function:

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const KeyVec key 
)
friend

Definition at line 161 of file CellKeyVec.h.


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