37 template<
class K,
class Comp>
48 template<
class K,
class Comp>
61 template<
class K,
class Comp>
62 template<
typename InputIterator>
65 m_tree.insert(first, last);
74 template<
class K,
class Comp>
88 template<
class K,
class Comp>
89 template<
typename InputIterator>
92 m_tree.insert(first, last);
101 template<
class K,
class Comp>
112 template<
class K,
class Comp>
123 template<
class K,
class Comp>
126 return m_tree.size();
134 template<
class K,
class Comp>
137 return m_tree.empty();
144 template<
class K,
class Comp>
148 return m_tree.begin();
155 template<
class K,
class Comp>
166 template<
class K,
class Comp>
170 return m_tree.find(key);
179 template<
class K,
class Comp>
183 return m_tree.find_nearest_greater(key);
192 template<
class K,
class Comp>
196 return m_tree.find_nearest_lower(key);
203 template<
class K,
class Comp>
207 return m_tree.lower_bound();
214 template<
class K,
class Comp>
218 return m_tree.upper_bound();
226 template<
class K,
class Comp>
229 m_tree = that.m_tree;
238 template<
class K,
class Comp>
241 return m_tree == that.m_tree;
249 template<
class K,
class Comp>
252 return m_tree != that.m_tree;
260 template<
class K,
class Comp>
263 return m_tree < that.m_tree;
271 template<
class K,
class Comp>
274 return m_tree > that.m_tree;
282 template<
class K,
class Comp>
285 return m_tree <= that.m_tree;
293 template<
class K,
class Comp>
296 return m_tree >= that.m_tree;
void insert(const K &key)
Add a value in a tree.
unsigned int size() const
Get the size of a tree.
bool operator<=(const avl< K, Comp > &that) const
Less or equal operator.
const_iterator upper_bound() const
Get an iterator on the gratest value of the tree.
bool operator!=(const avl< K, Comp > &that) const
Disequality.
Binary search tree AVL implementation.
const_iterator end() const
Get an iterator after the end of the tree.
void erase(const K &key)
Delete a value in a tree.
bool operator>(const avl< K, Comp > &that) const
Greater than operator.
void clear()
Clear a tree.
bool empty() const
Tell if a tree is empty or not.
Fuction object to get the first element of a std::pair.
bool operator==(const avl< K, Comp > &that) const
Equality.
bool operator<(const avl< K, Comp > &that) const
Less than operator.
bool operator>=(const avl< K, Comp > &that) const
Greater or equal operator.
const_iterator find_nearest_greater(const K &key) const
Get an iterator on the nodes of the tree on the key imediatly after from a specified key...
const_iterator find_nearest_lower(const K &key) const
Get an iterator on the nodes of the tree on the key imediatly before from a specified key...
const_iterator find(const K &key) const
Get an iterator on the nodes of the tree from a specified key.
avl< K, Comp > & operator=(const avl< K, Comp > &that)
Assignment.
const_iterator lower_bound() const
Get an iterator on the lowest value of the tree.
const_iterator begin() const
Get an iterator on the nodes of the tree.