Template Class CoalescedHashTable
Defined in File KnuthHashing.h
Nested Relationships
Nested Types
Class Documentation
-
template<class K, class V, class H = std::hash<K>>
class CoalescedHashTable a hash table with coalesced lists in the table and a cellar
Public Types
-
using size_type = std::size_t
-
using difference_type = std::ptrdiff_t
-
using const_iterator = SlotIterator<CoalescedHashTable, Places>
-
using iterator = const_iterator
Public Functions
-
explicit CoalescedHashTable(std::size_t m, std::size_t cellar = 0, H h = H())
a table of m places addressed by the hash and of cellar more
- Pre:
m >= 1
-
void insert(const K &k, const V &v)
associates v to k
- Pre:
k is there, or the table is not full
- Post:
k has the value v
-
std::size_t size(void) const
-
inline const_iterator begin(void) const
-
inline const_iterator end(void) const
-
inline const_iterator cbegin(void) const
-
inline const_iterator cend(void) const
-
struct Places
the places of the table, for SlotIterator
-
using size_type = std::size_t