Basic allocator that allocates each node individually, using C++ new / delete and pointers. Can throw exception if out of memory.  
 More...
|  | 
| unsigned int | get_nv_per_node () const | 
|  | 
|  | NodeAllocatorPtr (unsigned int nv_per_node_) | 
|  | 
| Node & | get_node (NodeHandle x) | 
|  | get reference to a modifiable node 
 | 
|  | 
| const Node & | get_node (const NodeHandle x) const | 
|  | get reference to a const node 
 | 
|  | 
| Node * | new_node () | 
|  | get new node  More... 
 | 
|  | 
| Node * | new_node (const KeyValue &kv) | 
|  | get new node  More... 
 | 
|  | 
| Node * | new_node (KeyValue &&kv) | 
|  | get new node  More... 
 | 
|  | 
| template<class... T> | 
| Node * | new_node (T &&... kv) | 
|  | get new node  More... 
 | 
|  | 
| void | free_node (NodeHandle n) | 
|  | delete node – tree is not traversed, the caller must arrange to "cut" out the node in question (otherwise the referenced nodes will be lost) 
 | 
|  | 
| void | clear_tree () | 
|  | clear tree, i.e. free all nodes, but keep root (sentinel) and nil, so that tree can be used again 
 | 
|  | 
| void | free_tree_nodes_r (Node *n) | 
|  | free whole tree (starting from root) 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | init_node (typename std::enable_if< simple_, Node *>::type n) | 
|  | safely initialize new node, throw an exception if memory allocation failed 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | init_node (typename std::enable_if<!simple_, Node *>::type n) | 
|  | safely initialize new node, throw an exception if memory allocation failed 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | get_node_sum (NodeHandle n, typename std::enable_if< simple_, NVType *>::type s) const | 
|  | get the value of the partial sum of weights stored in this node – simple case when the weight function returns only one value 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | get_node_sum (NodeHandle n, typename std::enable_if<!simple_, NVType *>::type s) const | 
|  | get the value of the partial sum of weights stored in this node – case when the weight function returns a vector 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | set_node_sum (NodeHandle n1, typename std::enable_if< simple_, const NVType *>::type s) | 
|  | set the value of the partial sum stored in this node – simple case when the weight function returns only one value 
 | 
|  | 
| template<bool simple_ = simple> | 
| void | set_node_sum (NodeHandle n1, typename std::enable_if<!simple_, const NVType *>::type s) | 
|  | set the value of the partial sum stored in this node – case when the weight function returns a vector 
 | 
|  | 
template<class KeyValueT, class NVTypeT, bool simple = false>
class orbtree::NodeAllocatorPtr< KeyValueT, NVTypeT, simple >
Basic allocator that allocates each node individually, using C++ new / delete and pointers. Can throw exception if out of memory. 
- Template Parameters
- 
  
    | KeyValueT | Type of stored data, should be either KeyOnly or KeyValue |  | NVTypeT | Type of extra data stored along in nodes (i.e. the return value of the function whose sum can be calculated). |