bvector<> container
BitMagic Library

The Main bvector<> Group bvector<> template: front end of the BitMagic library. More...

Collaboration diagram for bvector<> container:

## Topics

| bvector<> iterators
| Iterators for compressed bit-vector traversal.
| AVX2 functions
| Processor specific optimizations for AVX2 instructions (internals).
| bvector<> algorithms
| Algorithms for bit intervals
| Algorithms and iterators for bit ranges and intervals.
| three-valued logic
| Functions for three-valued logic (Kleene) https://en.wikipedia.org/wiki/Three-valued_logic.
| Import bvector<> from native bit-arrays
| bvector<> serialization
| Allocator

## Data Structures

class | bm::bvector< Alloc >
| Bitvector Bit-vector container with runtime compression of bits. More...
class | bm::bvector< Alloc >::reference
| Class reference implements an object for bit assignment. More...
struct | bm::bv_statistics
| Structure with statistical information about memory allocation footprint, serialization projection, number of vectors. More...
struct | bm::bv_arena_statistics
| Structure with statistical information about memory allocation for arena based vectors. More...

## Typedefs

typedef int(* | bit_visitor_callback_type) (void *handle_ptr, bm::id_t bit_idx)
| Callback type to visit (callback style) bits in bit-vector(s).
typedef bm::alloc_pool_guard< allocator_pool_type, bvector< Alloc > > | bm::bvector< Alloc >::mem_pool_guard

## Enumerations

enum | bm::strategy { bm::BM_BIT = 0 , bm::BM_GAP = 1 }
| Block allocation strategies. More...
enum class | bm::finalization { bm::finalization::UNDEFINED = 0 , bm::finalization::READONLY = 1 , bm::finalization::READWRITE = 2 }
| copy strategy More...
enum | bm::set_operation { bm::set_AND = 0 , bm::set_OR = 1 , bm::set_SUB = 2 , bm::set_XOR = 3 , bm::set_ASSIGN = 4 , bm::set_COUNT = 5 , bm::set_COUNT_AND = 6 , bm::set_COUNT_XOR = 7 , bm::set_COUNT_OR = 8 , bm::set_COUNT_SUB_AB = 9 , bm::set_COUNT_SUB_BA = 10 , bm::set_COUNT_A = 11 , bm::set_COUNT_B = 12 , bm::set_END }
| Codes of set operations. More...
enum | bm::operation { bm::BM_AND = set_AND , bm::BM_OR = set_OR , bm::BM_SUB = set_SUB , bm::BM_XOR = set_XOR }
| Bit operations. More...
enum | bm::sort_order { bm::BM_UNSORTED = 0 , bm::BM_SORTED = 1 , bm::BM_SORTED_UNIFORM = 2 , bm::BM_UNKNOWN = 3 }
| Sort order declaration. More...
enum | bm::null_support { bm::use_null = 0 , bm::no_null = 1 }
| NULL-able value support. More...

## Detailed Description

The Main bvector<> Group bvector<> template: front end of the BitMagic library.

## Typedef Documentation

## bit_visitor_callback_type

typedef int(* bit_visitor_callback_type) (void *handle_ptr, bm::id_t bit_idx)

Callback type to visit (callback style) bits in bit-vector(s).

Parameters

  handle_ptr | - custom pointer to callback specific data
  bit_idx | - number/index of visited bit

Returns
  negative return code is recognised as a request to interrupt visiting

Definition at line 72 of file bm.h.

## mem_pool_guard

template<class Alloc>

typedef bm::alloc_pool_guard<allocator_pool_type, bvector<Alloc> > bm::bvector< Alloc >::mem_pool_guard

Resource guard for bvector<>::set_allocator_pool()

Examples
  svsample07a.cpp, and xsample07a.cpp.

Definition at line 790 of file bm.h.

## Enumeration Type Documentation

## finalization

enum class bm::finalization

strong

copy strategy

Enumerator
UNDEFINED |
READONLY | immutable (read-only object)
READWRITE | mutable (read-write object)

Definition at line 155 of file bmconst.h.

## null_support

enum bm::null_support

NULL-able value support.

Enumerator
use_null | support "non-assigned" or "NULL" logic
no_null | do not support NULL values

Definition at line 228 of file bmconst.h.

## operation

enum bm::operation

Bit operations.

Enumerator
BM_AND |
BM_OR |
BM_SUB |
BM_XOR |

Definition at line 190 of file bmconst.h.

## set_operation

enum bm::set_operation

Codes of set operations.

Enumerator
set_AND |
set_OR |
set_SUB |
set_XOR |
set_ASSIGN |
set_COUNT |
set_COUNT_AND |
set_COUNT_XOR |
set_COUNT_OR |
set_COUNT_SUB_AB |
set_COUNT_SUB_BA |
set_COUNT_A |
set_COUNT_B |
set_END |

Definition at line 167 of file bmconst.h.

## sort_order

enum bm::sort_order

Sort order declaration.

Enumerator
BM_UNSORTED | input set is NOT sorted
BM_SORTED | input set is sorted (ascending order)
BM_SORTED_UNIFORM | sorted and in one block (internal!)
BM_UNKNOWN | sort order unknown

Definition at line 203 of file bmconst.h.

## strategy

enum bm::strategy

Block allocation strategies.

Enumerator
BM_BIT | No GAP compression strategy. All new blocks are bit blocks.
BM_GAP | GAP compression is ON.

Definition at line 145 of file bmconst.h.