A basic tree-based associative container specialized for underlying data-structure which do not support reverse iteration.
Parameter | Description | Default Value |
Key |
Key type. |
- |
Data |
Data type. |
- |
Cmp_Fn |
Comparison functor. |
- |
Node_Updator |
Node updator type. Node Invariants explains this concept. |
- |
Allocator |
Allocator type. |
- |
Class | Derivation Type |
Node_Updator |
public |
Type | Definition | Description |
size_type |
typename Allocator::size_type |
Size type. |
Type | Definition | Description |
const_key_reference |
typename Allocator::template rebind< Key>::other::const_reference |
Const key reference type. |
Type | Definition | Description |
cmp_fn |
Cmp_Fn |
Comparison functor type. |
node_updator |
Node_Updator |
Node updator type. |
Type | Definition | Description |
const_iterator |
Underlying data-structure's const range-type iterator. |
Const range-type iterator. |
iterator |
Underlying data-structure's range-type iterator. |
Range-type iterator. |
const_node_iterator |
basic_tree_assoc_cntnr::const_node_iterator |
Const node iterator. |
node_iterator |
basic_tree_assoc_cntnr::node_iterator |
Node iterator. |
Method | Description |
virtual ~basic_tree_assoc_cntnr () |
Destructor. |
Method | Description |
cmp_fn & get_cmp_fn () |
Access to the cmp_fn object. |
const cmp_fn & get_cmp_fn () const |
Const access to the cmp_fn object. |
node_updator & get_node_updator () |
Access to the node_updator object. |
const node_updator & get_node_updator () const |
Const access to the node_updator object. |
Method | Description |
inline size_type erase (const_key_reference r_key) |
Erases the value_type associated with r_key; returns the number of value_types erased (0 or 1). |
inline iterator erase (iterator it) |
Erases the value_type corresponding to the iterator it. Returns the iterator corresponding to the next value_type. |
Method | Description |
inline node_iterator node_begin () |
Returns a node_iterator corresponding to the value_type at the root of the tree. |
inline const_node_iterator node_begin () const |
Returns a const_node_iterator corresponding to the value_type at the root of the tree. |
inline node_iterator node_end () |
Returns a node_iterator corresponding to a value_type just after a leaf of the tree. |
inline const_node_iterator node_end () const |
Returns a const_node_iterator corresponding to a value_type just after a leaf of the tree. |
Method | Description |
void join (basic_tree_assoc_cntnr &r_other) |
Joins two trees. When this function returns, r_other will be empty. |
inline void split (const_key_reference r_key, basic_tree_assoc_cntnr &r_other) |
Joins two trees. When this function returns, r_other will be empty. |