|
| | Iterator (const std::vector< std::optional< std::pair< TKey, TValue > > > *table, size_t index) |
| | Construct iterator from table pointers and index.
|
| reference | operator* () const |
| | Dereference operator to access key-value pair.
|
| pointer | operator-> () const |
| | Arrow operator to access key-value pair members.
|
| Iterator & | operator++ () |
| | Pre-increment operator to advance to next occupied slot.
|
| Iterator | operator++ (int) |
| | Post-increment operator to advance to next occupied slot.
|
| bool | operator== (const Iterator &other) const |
| | Equality comparison operator.
|
| bool | operator!= (const Iterator &other) const |
| | Inequality comparison operator.
|
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
class nfx::containers::PerfectHashMap< TKey, TValue, HashType, Seed, Hasher, KeyEqual >::Iterator
Const forward iterator for PerfectHashMap.
Iterates over occupied slots in the hash table, skipping empty slots. Since PerfectHashMap is immutable, Iterator is always const.
Definition at line 331 of file PerfectHashMap.h.
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
| nfx::containers::PerfectHashMap< TKey, TValue, HashType, Seed, Hasher, KeyEqual >::Iterator::Iterator |
( |
const std::vector< std::optional< std::pair< TKey, TValue > > > * | table, |
|
|
size_t | index ) |
|
inline |
Construct iterator from table pointers and index.
- Parameters
-
| table | Pointer to the hash table storage |
| index | Starting index in the table |
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
Pre-increment operator to advance to next occupied slot.
- Returns
- Reference to this iterator after advancement
template<typename TKey, typename TValue, hashing::Hash32or64 HashType = uint32_t, HashType Seed = ( sizeof( HashType ) == 4 ? hashing::constants::FNV_OFFSET_BASIS_32 : hashing::constants::FNV_OFFSET_BASIS_64 ), typename Hasher = hashing::Hasher<HashType, Seed>, typename KeyEqual = std::equal_to<>>
Post-increment operator to advance to next occupied slot.
- Returns
- Copy of iterator before advancement