tlx
btree_default_traits< Key, Value > Struct Template Reference

Generates default traits for a B+ tree used as a set or map. More...

#include <btree.hpp>

Static Public Attributes

static const bool self_verify
 If true, the tree will self verify its invariants after each insert() or erase(). More...
 
static const bool debug
 If true, the tree will print out debug information and a tree dump during insert() or erase() operation. More...
 
static const int leaf_slots
 Number of slots in each leaf of the tree. More...
 
static const int inner_slots
 Number of slots in each inner node of the tree. More...
 
static const size_t binsearch_threshold
 As of stx-btree-0.9, the code does linear search in find_lower() and find_upper() instead of binary_search, unless the node size is larger than this threshold. More...
 

Detailed Description

template<typename Key, typename Value>
struct tlx::btree_default_traits< Key, Value >

Generates default traits for a B+ tree used as a set or map.

It estimates leaf and inner node sizes by assuming a cache line multiple of 256 bytes.

Definition at line 74 of file btree.hpp.

Member Data Documentation

const size_t binsearch_threshold
static

As of stx-btree-0.9, the code does linear search in find_lower() and find_upper() instead of binary_search, unless the node size is larger than this threshold.

See notes at http://panthema.net/2013/0504-STX-B+Tree-Binary-vs-Linear-Search

Definition at line 100 of file btree.hpp.

const bool debug
static

If true, the tree will print out debug information and a tree dump during insert() or erase() operation.

The header must have been compiled with TLX_BTREE_DEBUG defined and key_type must be std::ostream printable.

Definition at line 84 of file btree.hpp.

const int inner_slots
static

Number of slots in each inner node of the tree.

Estimated so that each node has a size of about 256 bytes.

Definition at line 93 of file btree.hpp.

const int leaf_slots
static

Number of slots in each leaf of the tree.

Estimated so that each node has a size of about 256 bytes.

Definition at line 88 of file btree.hpp.

const bool self_verify
static

If true, the tree will self verify its invariants after each insert() or erase().

The header must have been compiled with TLX_BTREE_DEBUG defined.

Definition at line 78 of file btree.hpp.


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