|
AGX Dynamics
2.37.2.0
|
Same as hash table, but only containing keys, not key-value pairs. More...
#include <HashSet.h>
Inheritance diagram for agx::HashSetImplementation< KeyT, HashT, AllocatorT >:Classes | |
| class | Bucket |
| class | insert_iterator |
| class | template_iterator |
Public Types | |
| typedef template_iterator< const HashSetImplementation< KeyT, HashT, AllocatorT > > | const_iterator |
| typedef const KeyT * | const_pointer |
| typedef const KeyT & | const_reference |
| typedef size_t | difference_type |
| typedef template_iterator< HashSetImplementation< KeyT, HashT, AllocatorT > > | iterator |
| Iterators. More... | |
| typedef std::bidirectional_iterator_tag | iterator_category |
| typedef KeyT * | pointer |
| typedef KeyT & | reference |
| typedef size_t | size_type |
| typedef KeyT | value_type |
Public Types inherited from agx::Container | |
| enum | ClearPolicy { SHRINK_BUFFER, SHRINK_BUFFER_AVERAGED, MAINTAIN_BUFFER } |
| agxData::Values from this enumeration is passed to the subclasses' 'clear' method in order to control what should become of the container's memory. More... | |
Public Member Functions | |
| HashSetImplementation (const AllocatorT &allocator=AllocatorT()) | |
| Constructor. More... | |
| HashSetImplementation (const HashSetImplementation< KeyT, HashT, AllocatorT > &other) | |
| Copy constructor. More... | |
| ~HashSetImplementation () | |
| Destructor. More... | |
| AllocatorT & | allocator () |
| const AllocatorT & | allocator () const |
| iterator | begin () |
| Iterator to first element in hash set. More... | |
| const_iterator | begin () const |
| void | clear (ClearPolicy policy=SHRINK_BUFFER_AVERAGED) |
| Remove all elements. More... | |
| bool | contains (const KeyT &key) const |
| Boolean query to test existence of an element. More... | |
| iterator | end () |
| Iterator marking end of hash set. More... | |
| const_iterator | end () const |
| bool | erase (const KeyT &key) |
| Erase an element from the hash set. More... | |
| iterator | erase (const iterator &it) |
| Erase an element using an iterator. More... | |
| iterator | find (const KeyT &key) |
| Find an element. More... | |
| const_iterator | find (const KeyT &key) const |
| insert_iterator | insert (const KeyT &key) |
| Insert an element, overwriting if key already exists. More... | |
| HashSetImplementation< KeyT, HashT, AllocatorT > & | operator= (const HashSetImplementation< KeyT, HashT, AllocatorT > &other) |
| Assignment operator. More... | |
| KeyT & | operator[] (const KeyT &key) |
| Index operator for accessing elements in the hash, inserting it if not found. More... | |
| const KeyT & | operator[] (const KeyT &key) const |
| template<typename T > | |
| void | purge (T purger) |
| Purge the hash set. More... | |
| void | reserve (size_t size) |
| Reserve capacity in the hash set. More... | |
Public Member Functions inherited from agx::Container | |
| size_t | capacity () const |
| Returns the size of the memory are used by the container to store its elements. More... | |
| bool | empty () const |
| void * | ptr () |
| const void * | ptr () const |
| size_t | size () const |
Protected Member Functions | |
| Bucket * | buckets () const |
| bool | eraseBucket (size_t index) |
| template<typename T2 > | |
| size_t | findBucket (const T2 &key) const |
| size_t & | numBuckets () |
| size_t | numBuckets () const |
| size_t & | numFilled () |
| size_t | numFilled () const |
| void | rebuild (size_t size) |
| Rebuild, and optionally resize hash set. More... | |
Protected Member Functions inherited from agx::Container | |
| Container () | |
| Container (Container &&other) | |
| Container (const Container &other) | |
| ~Container () | |
Additional Inherited Members | |
Protected Attributes inherited from agx::Container | |
| void * | m_buffer |
| size_t | m_capacity |
| size_t | m_size |
Same as hash table, but only containing keys, not key-value pairs.
| typedef template_iterator< const HashSetImplementation<KeyT, HashT, AllocatorT> > agx::HashSetImplementation< KeyT, HashT, AllocatorT >::const_iterator |
| typedef const KeyT* agx::HashSetImplementation< KeyT, HashT, AllocatorT >::const_pointer |
| typedef const KeyT& agx::HashSetImplementation< KeyT, HashT, AllocatorT >::const_reference |
| typedef size_t agx::HashSetImplementation< KeyT, HashT, AllocatorT >::difference_type |
| typedef template_iterator< HashSetImplementation<KeyT, HashT, AllocatorT> > agx::HashSetImplementation< KeyT, HashT, AllocatorT >::iterator |
| typedef std::bidirectional_iterator_tag agx::HashSetImplementation< KeyT, HashT, AllocatorT >::iterator_category |
| typedef KeyT* agx::HashSetImplementation< KeyT, HashT, AllocatorT >::pointer |
| typedef KeyT& agx::HashSetImplementation< KeyT, HashT, AllocatorT >::reference |
| typedef size_t agx::HashSetImplementation< KeyT, HashT, AllocatorT >::size_type |
| typedef KeyT agx::HashSetImplementation< KeyT, HashT, AllocatorT >::value_type |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Iterator to first element in hash set.
Definition at line 360 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator=().
|
inline |
|
inlineprotected |
Definition at line 527 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::clear(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::eraseBucket(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::findBucket(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::insert(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::purge(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::rebuild(), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::~HashSetImplementation().
|
inline |
Remove all elements.
Definition at line 399 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator=().
|
inline |
Boolean query to test existence of an element.
Definition at line 314 of file HashSet.h.
Referenced by agx::createMissingTiers().
|
inline |
Iterator marking end of hash set.
Definition at line 370 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator=(), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator[]().
|
inline |
|
inline |
|
inline |
|
inlineprotected |
Definition at line 598 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::erase(), and agx::HashSet< agx::ref_ptr< KeyT >, HashT, AllocatorT >::erase().
|
inline |
Find an element.
Definition at line 346 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator[]().
|
inline |
|
inlineprotected |
Definition at line 571 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::contains(), agx::HashSet< agx::ref_ptr< KeyT >, HashT, AllocatorT >::contains(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::erase(), agx::HashSet< agx::ref_ptr< KeyT >, HashT, AllocatorT >::erase(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::find(), and agx::HashSet< agx::ref_ptr< KeyT >, HashT, AllocatorT >::find().
|
inline |
Insert an element, overwriting if key already exists.
Definition at line 250 of file HashSet.h.
Referenced by agx::createMissingTiers(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::insert(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator=(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator[](), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::rebuild().
|
inlineprotected |
Definition at line 524 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::allocator(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::clear(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::contains(), agx::HashSet< agx::ref_ptr< KeyT >, HashT, AllocatorT >::contains(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::end(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::eraseBucket(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::findBucket(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::insert(), agx::HashSetImplementation< KeyT, HashT, AllocatorT >::template_iterator< T >::operator=(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::purge(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::rebuild(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::reserve(), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::~HashSetImplementation().
|
inlineprotected |
|
inlineprotected |
Definition at line 525 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::clear(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::eraseBucket(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::insert(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::purge(), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::rebuild().
|
inlineprotected |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineprotected |
Rebuild, and optionally resize hash set.
Definition at line 534 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::insert(), agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::purge(), and agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::reserve().
|
inline |
Reserve capacity in the hash set.
Definition at line 455 of file HashSet.h.
Referenced by agx::HashSetImplementation< CellPtr, HashFn< CellPtr >, ByteAllocator >::operator=().