![]() |
Elm
2
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
|
#include <elm/avl/Set.h>
Inheritance diagram for Set< T, C >:Public Types | |
| typedef T | t |
| typedef Set< T, C > | self_t |
| typedef GenTree< T, IdAdapter< T >, C > | base_t |
Public Types inherited from GenTree< T, IdAdapter< T >, elm::Comparator< T > > | |
| typedef T | t |
| typedef GenTree< T, IdAdapter< T >, elm::Comparator< T >, DefaultAlloc > | self_t |
Public Types inherited from Comparator< T > | |
| typedef T | t |
Public Member Functions | |
| self_t & | operator+= (const T &x) |
| self_t & | operator-= (const T &x) |
| self_t & | operator= (const self_t &s) |
| void | insert (const T &x) |
| bool | subsetOf (const Set< T, C > &s) const |
| void | join (const Set< T, C > &s) |
| void | diff (const Set< T, C > &s) |
| void | meet (const Set< T, C > &s) |
| self_t & | operator+= (const Set< T, C > &s) |
| self_t & | operator|= (const Set< T, C > &s) |
| self_t & | operator-= (const Set< T, C > &s) |
| self_t & | operator&= (const Set< T, C > &s) |
| self_t & | operator*= (const Set< T, C > &s) |
| self_t | operator+ (const Set< T, C > &s) const |
| self_t | operator| (const Set< T, C > &s) const |
| self_t | operator- (const Set< T, C > &s) const |
| self_t | operator* (const Set< T, C > &s) const |
| self_t | operator& (const Set< T, C > &s) const |
Public Member Functions inherited from GenTree< T, IdAdapter< T >, elm::Comparator< T > > | |
| GenTree (void) | |
| GenTree (const GenTree< T > &tree) | |
| ~GenTree (void) | |
| const elm::Comparator< T > & | comparator () const |
| elm::Comparator< T > & | comparator () |
| const DefaultAlloc & | allocator () const |
| DefaultAlloc & | allocator () |
| T * | get (const typename K::key_t &key) |
| const T * | get (const typename K::key_t &key) const |
| void | set (const T &item) |
| void | removeByKey (const typename K::key_t &item) |
| int | count (void) const |
| bool | contains (const typename K::key_t &item) const |
| bool | containsAll (const CC &c) const |
| bool | isEmpty (void) const |
| operator bool (void) const | |
| Iter | begin (void) const |
| Iter | end (void) const |
| bool | equals (const GenTree< T, IdAdapter< T >, elm::Comparator< T > > &tree) const |
| bool | operator== (const GenTree< T, IdAdapter< T >, elm::Comparator< T > > &tree) const |
| bool | operator!= (const GenTree< T, IdAdapter< T >, elm::Comparator< T > > &tree) const |
| void | clear (void) |
| void | add (const T &item) |
| void | addAll (const CC &c) |
| void | remove (const T &x) |
| void | remove (const Iter &iter) |
| void | removeAll (const CC &c) |
| self_t & | operator+= (const T &x) |
| self_t & | operator-= (const T &x) |
| void | copy (const GenTree< T, IdAdapter< T >, elm::Comparator< T > > &tree) |
| GenTree< T, IdAdapter< T >, elm::Comparator< T > > & | operator= (const GenTree< T, IdAdapter< T >, elm::Comparator< T > > &tree) |
Public Member Functions inherited from AbstractTree | |
| int | count (void) const |
Public Member Functions inherited from Comparator< T > | |
| int | doCompare (const T &v1, const T &v2) const |
Public Member Functions inherited from DefaultAllocatorDelegate | |
| t::ptr | allocate (t::size size) const |
| void | free (t::ptr p) const |
| template<class T > | |
| T * | alloc () const |
Additional Inherited Members | |
Static Public Member Functions inherited from Comparator< T > | |
| static int | compare (const T &v1, const T &v2) |
Protected Types inherited from AbstractTree | |
| enum | dir_t { LEFT = -1 , NONE = 0 , RIGHT = +1 } |
| typedef signed char | balance_t |
Protected Member Functions inherited from GenTree< T, IdAdapter< T >, elm::Comparator< T > > | |
| Node * | root (void) const |
| void | remove (Stack &s, Node *n) |
| int | compare (const typename K::key_t &k1, const typename K::key_t &k2) const |
| Node * | lookup (Stack &s, const typename K::key_t &key) const |
| Node * | find (const typename K::key_t &key) const |
| void | exchange (Node *n, Node *p) |
Protected Member Functions inherited from AbstractTree | |
| AbstractTree (void) | |
| Node ** | link (const Stack &s) |
| void | exchange (Node *n, Node *m) |
| void | insert (Stack &stack, Node *node) |
| void | rotateRight (Stack &s) |
| void | rotateLeft (Stack &s) |
| void | remove (Stack &stack, Node *n) |
| Node * | leftMost (Stack &s, Node *n) |
Protected Attributes inherited from AbstractTree | |
| Node * | _root |
| int | _cnt |
Static Protected Attributes inherited from AbstractTree | |
| static const int | MAX_HEIGHT = 32 |
Implements a set collection based on an AVL tree, that is, supporting access and modifications with a O(log n) complexity.
| T | Type of stored items. |
| C | Comparator used to sort the items (must implements the elm::concept::Comparator<T> concept, as a default elm::Comparator<T>). |
| typedef T t |
References GenTree< T, K, C, A >::remove().
Referenced by Set< T, C >::operator-(), and Set< T, C >::operator-=().
|
inline |
References GenTree< T, K, C, A >::add().
Referenced by Set< T, C >::operator+=().
References GenTree< T, K, C, A >::add().
Referenced by Set< T, C >::operator+(), Set< T, C >::operator+=(), Set< T, C >::operator|(), and Set< T, C >::operator|=().
References GenTree< T, K, C, A >::contains(), GenTree< T, K, C, A >::copy(), and elm::is().
Referenced by Set< T, C >::operator&(), Set< T, C >::operator&=(), Set< T, C >::operator*(), and Set< T, C >::operator*=().
References Set< T, C >::meet().
References Set< T, C >::meet().
References Set< T, C >::meet().
References Set< T, C >::meet().
References Set< T, C >::join().
References Set< T, C >::join().
|
inline |
References Set< T, C >::insert().
References Set< T, C >::diff().
References Set< T, C >::diff().
|
inline |
References GenTree< T, K, C, A >::remove().
References GenTree< T, K, C, A >::copy().
References Set< T, C >::join().
References Set< T, C >::join().
References GenTree< T, K, C, A >::begin().