#include <hashmap.h>
Class used for entries of the HashMap. The entries of a bucket are stored as a singly linked list, you can loop over this list via GetNextInBucket().
Public Types | |
using | KeyType = K |
using | ValueType = V |
![]() | |
using | EntryHandler = ENTRY_HANDLER |
Public Member Functions | |
operator Pair< K, V > () const | |
const Entry * | GetNextWithSameKey () const |
Entry * | GetNextWithSameKey () |
const Entry * | GetNextInBucket () const |
Entry * | GetNextInBucket () |
void | PrivateInitNextInBucket (Entry *next) |
SFINAEHelper< String, V >::type | ToString (const FormatStatement *format) const |
Int | GetMemorySize () const |
![]() | |
V & | GetValue () |
const V & | GetValue () const |
V & | GetSecond () |
const V & | GetSecond () const |
void | SetValue (const V &value) |
void | SetValue (V &&value) |
void | ResetValue () |
UInt | GetHashCode () const |
Int | GetMemorySize () const |
HashMapEntryBase (UInt hash) | |
HashMapEntryBase (UInt hash, const KEY &) | |
HashMapEntryBase (UInt hash, const KEY &, A &&value) | |
Static Public Member Functions | |
static const Entry * | Get (const V *value) |
static Entry * | Get (typename std::remove_const< V >::type *value) |
Private Types | |
using | Super = HashMapEntryBase< K, V, Entry, ENTRY_HANDLER > |
Private Member Functions | |
MAXON_DISALLOW_COPY_AND_ASSIGN (Entry) | |
Friends | |
class | HashMap |
Additional Inherited Members | |
![]() | |
decltype(ENTRY_HANDLER::GetKey(*(V *) nullptr) | GetKey )() const |
decltype(ENTRY_HANDLER::GetKey(*(V *) nullptr) | GetFirst )() const |
![]() | |
MAXON_DISALLOW_COPY_AND_ASSIGN (HashMapEntryBase) | |
![]() | |
Entry * | _next |
UInt | _hashCode |
V | _value |
|
private |
using KeyType = K |
using ValueType = V |
operator Pair< K, V > | ( | ) | const |
const Entry* GetNextWithSameKey | ( | ) | const |
Returns the next entry with the same key. This is needed for multi-maps to iterate over all entries for a key, see InsertMultiEntry().
Entry* GetNextWithSameKey | ( | ) |
Returns the next entry with the same key. This is needed for multi-maps to iterate over all entries for a key, see InsertMultiEntry().
const Entry* GetNextInBucket | ( | ) | const |
Returns the next entry in the same bucket.
Entry* GetNextInBucket | ( | ) |
Returns the next entry in the same bucket.
void PrivateInitNextInBucket | ( | Entry * | next | ) |
SFINAEHelper<String, V>::type ToString | ( | const FormatStatement * | format | ) | const |
Int GetMemorySize | ( | void | ) | const |
|
static |
Returns the pointer to the entry to which #value belongs. You must not use this function if you cannot guarantee that value is a part of an entry.
[in] | value | A pointer to a value which is known to belong to an entry. |
|
static |
Returns the pointer to the entry to which #value belongs. You must not use this function if you cannot guarantee that value is a part of an entry.
[in] | value | A pointer to a value which is known to belong to an entry. |
|
private |
|
friend |