ADUL
Collection of reusable C++ utilities
|
Vector of chunks, where in which chunk you can edit every bit. More...
#include <bitVector.hpp>
Public Member Functions | |
void | pushChunk () |
void | pushChunk (const ChunkT &pChunk) |
void | popChunk () |
ChunkT | getLastChunk () const |
ChunkT | getFirstChunk () const |
void | setChunk (const uint64_t &idx, const ChunkT &pChunk) |
ChunkT | getChunk (const uint64_t &idx) const |
void | resetChunk (const uint64_t &idx) |
void | activateBit (const uint64_t &idx) |
void | clearBit (const uint64_t &idx) |
void | setBitValue (const uint64_t &idx, const bool &value) |
bool | getBit (const uint64_t &idx) const |
void | setChunksVector (const std::vector< ChunkT > &pVector) |
std::vector< ChunkT > | getChunksVector () const |
void | clearChunksVector () |
bool | isEmpty () const |
uint64_t | oneChunkSize () const |
uint64_t | chunksVectorSize () const |
uint64_t | chunksVectorMaxSize () const |
uint64_t | chunksVectorCapacity () const |
void | chunksVectorReserve (const uint64_t &pCapacity) |
void | chunksVectorShrinkToFit () |
void | chunksVectorResize (const uint64_t &pCapacity) |
uint64_t | bitsSize () const |
uint64_t | bitsMaxSize () const |
uint64_t | bitsCapacity () const |
void | swap (BitVector< ChunkT > &that) noexcept |
bool | isEqualTo (const adul::atm::BitVector< ChunkT > &that) const |
Vector of chunks, where in which chunk you can edit every bit.
It's in fact just a basic wrapper for std::vector<ChunkT> with additional functions for bits manipulation
elements always must be unsigned integers
Every Chunk is just an element of source vector "dataChunks"
ChunkT | represents the type of every vector element type |
ChunkT must be unsigned integer type
it defines the size of every Chunk
void adul::atm::BitVector< ChunkT >::activateBit | ( | const uint64_t & | idx | ) |
uint64_t adul::atm::BitVector< ChunkT >::bitsCapacity | ( | ) | const |
uint64_t adul::atm::BitVector< ChunkT >::bitsMaxSize | ( | ) | const |
uint64_t adul::atm::BitVector< ChunkT >::bitsSize | ( | ) | const |
uint64_t adul::atm::BitVector< ChunkT >::chunksVectorCapacity | ( | ) | const |
uint64_t adul::atm::BitVector< ChunkT >::chunksVectorMaxSize | ( | ) | const |
void adul::atm::BitVector< ChunkT >::chunksVectorReserve | ( | const uint64_t & | pCapacity | ) |
void adul::atm::BitVector< ChunkT >::chunksVectorResize | ( | const uint64_t & | pCapacity | ) |
void adul::atm::BitVector< ChunkT >::chunksVectorShrinkToFit | ( | ) |
uint64_t adul::atm::BitVector< ChunkT >::chunksVectorSize | ( | ) | const |
void adul::atm::BitVector< ChunkT >::clearBit | ( | const uint64_t & | idx | ) |
void adul::atm::BitVector< ChunkT >::clearChunksVector | ( | ) |
bool adul::atm::BitVector< ChunkT >::getBit | ( | const uint64_t & | idx | ) | const |
ChunkT adul::atm::BitVector< ChunkT >::getChunk | ( | const uint64_t & | idx | ) | const |
std::vector< ChunkT > adul::atm::BitVector< ChunkT >::getChunksVector | ( | ) | const |
ChunkT adul::atm::BitVector< ChunkT >::getFirstChunk | ( | ) | const |
ChunkT adul::atm::BitVector< ChunkT >::getLastChunk | ( | ) | const |
bool adul::atm::BitVector< ChunkT >::isEmpty | ( | ) | const |
bool adul::atm::BitVector< ChunkT >::isEqualTo | ( | const adul::atm::BitVector< ChunkT > & | that | ) | const |
uint64_t adul::atm::BitVector< ChunkT >::oneChunkSize | ( | ) | const |
void adul::atm::BitVector< ChunkT >::popChunk | ( | ) |
void adul::atm::BitVector< ChunkT >::pushChunk | ( | ) |
void adul::atm::BitVector< ChunkT >::pushChunk | ( | const ChunkT & | pChunk | ) |
void adul::atm::BitVector< ChunkT >::resetChunk | ( | const uint64_t & | idx | ) |
void adul::atm::BitVector< ChunkT >::setBitValue | ( | const uint64_t & | idx, |
const bool & | value ) |
void adul::atm::BitVector< ChunkT >::setChunk | ( | const uint64_t & | idx, |
const ChunkT & | pChunk ) |
void adul::atm::BitVector< ChunkT >::setChunksVector | ( | const std::vector< ChunkT > & | pVector | ) |
|
noexcept |