UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > Class Template Reference
+ Inheritance diagram for TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >:

Classes

class  TBaseIterator
 
class  TBaseKeyIterator
 
class  TConstIterator
 
class  TConstKeyIterator
 
class  TIterator
 
class  TKeyIterator
 

Public Types

typedef TTypeTraits< KeyType >::ConstPointerType KeyConstPointerType
 
typedef TTypeTraits< KeyType >::ConstInitType KeyInitType
 
typedef TTypeTraits< ValueType >::ConstInitType ValueInitType
 
typedef TPair< KeyType, ValueType > ElementType
 
using TRangedForIterator = typename ElementSetType::TRangedForIterator
 
using TRangedForConstIterator = typename ElementSetType::TRangedForConstIterator
 

Public Member Functions

bool OrderIndependentCompareEqual (const TMAPBASE &Other) const
 
UE_FORCEINLINE_HINT void Empty (int32 ExpectedNumElements=0)
 
UE_FORCEINLINE_HINT void Reset ()
 
UE_FORCEINLINE_HINT void Shrink ()
 
UE_FORCEINLINE_HINT void Compact ()
 
UE_FORCEINLINE_HINT void CompactStable ()
 
UE_FORCEINLINE_HINT void Reserve (int32 Number)
 
bool IsEmpty () const
 
UE_FORCEINLINE_HINT int32 Num () const
 
UE_FORCEINLINE_HINT int32 Max () const
 
UE_FORCEINLINE_HINT int32 GetMaxIndex () const
 
UE_FORCEINLINE_HINT bool IsValidId (FSetElementId Id) const
 
UE_FORCEINLINE_HINT ElementTypeGet (FSetElementId Id)
 
UE_FORCEINLINE_HINT const ElementTypeGet (FSetElementId Id) const
 
template<typename Allocator >
int32 GetKeys (TArray< KeyType, Allocator > &OutKeys) const
 
template<typename InSetKeyFuncs , typename InSetAllocator >
int32 GetKeys (TSet< KeyType, InSetKeyFuncs, InSetAllocator > &OutKeys) const
 
UE_FORCEINLINE_HINT SIZE_T GetAllocatedSize () const
 
UE_FORCEINLINE_HINT void CountBytes (FArchive &Ar) const
 
UE_FORCEINLINE_HINT ValueType & Add (const KeyType &InKey, const ValueType &InValue)
 
UE_FORCEINLINE_HINT ValueType & Add (const KeyType &InKey, ValueType &&InValue)
 
UE_FORCEINLINE_HINT ValueType & Add (KeyType &&InKey, const ValueType &InValue)
 
UE_FORCEINLINE_HINT ValueType & Add (KeyType &&InKey, ValueType &&InValue)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, const KeyType &InKey, const ValueType &InValue)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, const KeyType &InKey, ValueType &&InValue)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, KeyType &&InKey, const ValueType &InValue)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, KeyType &&InKey, ValueType &&InValue)
 
UE_FORCEINLINE_HINT ValueType & Add (const KeyType &InKey)
 
UE_FORCEINLINE_HINT ValueType & Add (KeyType &&InKey)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, const KeyType &InKey)
 
UE_FORCEINLINE_HINT ValueType & AddByHash (uint32 KeyHash, KeyType &&InKey)
 
UE_FORCEINLINE_HINT ValueType & Add (const TTuple< KeyType, ValueType > &InKeyValue)
 
UE_FORCEINLINE_HINT ValueType & Add (TTuple< KeyType, ValueType > &&InKeyValue)
 
template<typename InitKeyType = KeyType, typename InitValueType = ValueType>
ValueType & Emplace (InitKeyType &&InKey, InitValueType &&InValue)
 
template<typename InitKeyType = KeyType, typename InitValueType = ValueType>
ValueType & EmplaceByHash (uint32 KeyHash, InitKeyType &&InKey, InitValueType &&InValue)
 
template<typename InitKeyType = KeyType>
ValueType & Emplace (InitKeyType &&InKey)
 
template<typename InitKeyType = KeyType>
ValueType & EmplaceByHash (uint32 KeyHash, InitKeyType &&InKey)
 
int32 Remove (KeyConstPointerType InKey)
 
int32 RemoveStable (KeyConstPointerType InKey)
 
template<typename ComparableKey >
int32 RemoveByHash (uint32 KeyHash, const ComparableKey &Key)
 
UE_FORCEINLINE_HINT void Remove (FSetElementId Id)
 
const KeyType * FindKey (ValueInitType Value) const
 
template<typename Predicate >
TMAP< KeyType, ValueType, SetAllocator, KeyFuncs > FilterByPredicate (Predicate Pred) const
 
ValueType * Find (KeyConstPointerType Key)
 
UE_FORCEINLINE_HINT const ValueType * Find (KeyConstPointerType Key) const
 
template<typename ComparableKey >
ValueType * FindByHash (uint32 KeyHash, const ComparableKey &Key)
 
template<typename ComparableKey >
UE_FORCEINLINE_HINT const ValueType * FindByHash (uint32 KeyHash, const ComparableKey &Key) const
 
template<typename ComparableKey >
ValueType & FindByHashChecked (uint32 KeyHash, const ComparableKey &Key)
 
template<typename ComparableKey >
UE_FORCEINLINE_HINT const ValueType & FindByHashChecked (uint32 KeyHash, const ComparableKey &Key) const
 
UE_FORCEINLINE_HINT FSetElementId FindId (KeyInitType Key) const
 
template<typename ComparableKey >
UE_FORCEINLINE_HINT FSetElementId FindIdByHash (uint32 KeyHash, const ComparableKey &Key) const
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (const KeyType &Key)
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (KeyType &&Key)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, const KeyType &Key)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, KeyType &&Key)
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (const KeyType &Key, const ValueType &Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (const KeyType &Key, ValueType &&Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (KeyType &&Key, const ValueType &Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAdd (KeyType &&Key, ValueType &&Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, const KeyType &Key, const ValueType &Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, const KeyType &Key, ValueType &&Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, KeyType &&Key, const ValueType &Value)
 
UE_FORCEINLINE_HINT ValueType & FindOrAddByHash (uint32 KeyHash, KeyType &&Key, ValueType &&Value)
 
const ValueType & FindChecked (KeyConstPointerType Key) const
 
ValueType & FindChecked (KeyConstPointerType Key)
 
ValueType FindRef (KeyConstPointerType Key) const
 
ValueType FindRef (KeyConstPointerType Key, ValueType DefaultValue) const
 
ElementTypeFindArbitraryElement ()
 
const ElementTypeFindArbitraryElement () const
 
UE_FORCEINLINE_HINT bool Contains (KeyConstPointerType Key) const
 
template<typename ComparableKey >
UE_FORCEINLINE_HINT bool ContainsByHash (uint32 KeyHash, const ComparableKey &Key) const
 
TArray< ElementTypeArray () const
 
template<typename Allocator >
void GenerateKeyArray (TArray< KeyType, Allocator > &OutArray) const
 
template<typename Allocator >
void GenerateValueArray (TArray< ValueType, Allocator > &OutArray) const
 
void Dump (FOutputDevice &Ar)
 
void WriteMemoryImage (FMemoryImageWriter &Writer) const
 
void CopyUnfrozen (const FMemoryUnfreezeContent &Context, void *Dst) const
 
UE_FORCEINLINE_HINT TIterator CreateIterator ()
 
UE_FORCEINLINE_HINT TConstIterator CreateConstIterator () const
 
UE_FORCEINLINE_HINT TKeyIterator CreateKeyIterator (typename TKeyIterator::KeyArgumentType InKey)
 
UE_FORCEINLINE_HINT TConstKeyIterator CreateConstKeyIterator (typename TConstKeyIterator::KeyArgumentType InKey) const
 
UE_FORCEINLINE_HINT TRangedForIterator begin ()
 
UE_FORCEINLINE_HINT TRangedForConstIterator begin () const
 
UE_FORCEINLINE_HINT TRangedForIterator end ()
 
UE_FORCEINLINE_HINT TRangedForConstIterator end () const
 

Static Public Member Functions

static void AppendHash (const FPlatformTypeLayoutParameters &LayoutParams, FSHA1 &Hasher)
 

Protected Types

using IntrusiveUnsetOptionalStateType = TMAPBASE
 
using ElementSetType = TSET< ElementType, KeyFuncs, SetAllocator >
 

Protected Member Functions

constexpr TMAPBASE ()=default
 
consteval TMAPBASE (EConstEval)
 
 TMAPBASE (TMAPBASE &&)=default
 
 TMAPBASE (const TMAPBASE &)=default
 
TMAPBASEoperator= (TMAPBASE &&)=default
 
TMAPBASEoperator= (const TMAPBASE &)=default
 
template<typename OtherSetAllocator >
 TMAPBASE (TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &&Other)
 
template<typename OtherSetAllocator >
 TMAPBASE (const TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &Other)
 
 ~TMAPBASE ()
 
 TMAPBASE (FIntrusiveUnsetOptionalState Tag)
 
bool operator== (FIntrusiveUnsetOptionalState Tag) const
 
template<typename OtherSetAllocator >
TMAPBASEoperator= (TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &&Other)
 
template<typename OtherSetAllocator >
TMAPBASEoperator= (const TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &Other)
 

Protected Attributes

ElementSetType Pairs
 

Static Protected Attributes

static constexpr bool bHasIntrusiveUnsetOptionalState = true
 

Friends

template<typename OtherKeyType , typename OtherValueType , typename OtherSetAllocator , typename OtherKeyFuncs >
class TMAPBASE
 
struct TMAPPRIVATEFRIEND
 
uint32 GetTypeHash (const TMAPBASE &Map)=delete
 
bool operator== (const TMAPBASE &, const TMAPBASE &)=delete
 
bool operator!= (const TMAPBASE &, const TMAPBASE &)=delete
 

Detailed Description

template<typename KeyType, typename ValueType, typename SetAllocator, typename KeyFuncs>
class TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >

The base class of maps from keys to values. Implemented using a TSet of key-value pairs with a custom KeyFuncs, with the same O(1) addition, removal, and finding.

The ByHash() functions are somewhat dangerous but particularly useful in two scenarios: – Heterogeneous lookup to avoid creating expensive keys like FString when looking up by const TCHAR*. You must ensure the hash is calculated in the same way as ElementType is hashed. If possible put both ComparableKey and ElementType hash functions next to each other in the same header to avoid bugs when the ElementType hash function is changed. – Reducing contention around hash tables protected by a lock. It is often important to incur the cache misses of reading key data and doing the hashing before acquiring the lock.

Member Typedef Documentation

◆ ElementSetType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
using TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::ElementSetType = TSET<ElementType, KeyFuncs, SetAllocator>
protected

◆ ElementType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
typedef TPair<KeyType, ValueType> TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::ElementType

◆ IntrusiveUnsetOptionalStateType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
using TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::IntrusiveUnsetOptionalStateType = TMAPBASE
protected

◆ KeyConstPointerType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
typedef TTypeTraits<KeyType>::ConstPointerType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::KeyConstPointerType

◆ KeyInitType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
typedef TTypeTraits<KeyType>::ConstInitType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::KeyInitType

◆ TRangedForConstIterator

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
using TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TRangedForConstIterator = typename ElementSetType::TRangedForConstIterator

◆ TRangedForIterator

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
using TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TRangedForIterator = typename ElementSetType::TRangedForIterator

◆ ValueInitType

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
typedef TTypeTraits<ValueType>::ConstInitType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::ValueInitType

Constructor & Destructor Documentation

◆ TMAPBASE() [1/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
constexpr TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( )
constexprprotecteddefault

◆ TMAPBASE() [2/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
consteval TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( EConstEval  )
inlineexplicitprotected

◆ TMAPBASE() [3/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &&  )
protecteddefault

◆ TMAPBASE() [4/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  )
protecteddefault

◆ TMAPBASE() [5/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &&  Other)
inlineprotected

Constructor for moving elements from a TMAP with a different SetAllocator

◆ TMAPBASE() [6/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( const TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &  Other)
inlineprotected

Constructor for copying elements from a TMAP with a different SetAllocator

◆ ~TMAPBASE()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::~TMAPBASE ( )
inlineprotected

◆ TMAPBASE() [7/7]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::TMAPBASE ( FIntrusiveUnsetOptionalState  Tag)
inlineexplicitprotected

Member Function Documentation

◆ Add() [1/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( const KeyType &  InKey)
inline

Set a default value associated with a key.

Parameters
InKeyThe key to associate the value with.
Returns
A reference to the value as stored in the map. The reference is only valid until the next change to any key in the map.

◆ Add() [2/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( const KeyType &  InKey,
const ValueType &  InValue 
)
inline

Set the value associated with a key.

Parameters
InKeyThe key to associate the value with.
InValueThe value to associate with the key.
Returns
A reference to the value as stored in the map. The reference is only valid until the next change to any key in the map.

◆ Add() [3/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( const KeyType &  InKey,
ValueType &&  InValue 
)
inline

◆ Add() [4/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( const TTuple< KeyType, ValueType > &  InKeyValue)
inline

Set the value associated with a key.

Parameters
InKeyValueA Tuple containing the Key and Value to associate together
Returns
A reference to the value as stored in the map. The reference is only valid until the next change to any key in the map.

◆ Add() [5/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( KeyType &&  InKey)
inline

◆ Add() [6/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( KeyType &&  InKey,
const ValueType &  InValue 
)
inline

◆ Add() [7/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( KeyType &&  InKey,
ValueType &&  InValue 
)
inline

◆ Add() [8/8]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Add ( TTuple< KeyType, ValueType > &&  InKeyValue)
inline

◆ AddByHash() [1/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
const KeyType &  InKey 
)
inline

See Add() and class documentation section on ByHash() functions

◆ AddByHash() [2/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
const KeyType &  InKey,
const ValueType &  InValue 
)
inline

See Add() and class documentation section on ByHash() functions

◆ AddByHash() [3/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
const KeyType &  InKey,
ValueType &&  InValue 
)
inline

◆ AddByHash() [4/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
KeyType &&  InKey 
)
inline

◆ AddByHash() [5/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
KeyType &&  InKey,
const ValueType &  InValue 
)
inline

◆ AddByHash() [6/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AddByHash ( uint32  KeyHash,
KeyType &&  InKey,
ValueType &&  InValue 
)
inline

◆ AppendHash()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
static void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::AppendHash ( const FPlatformTypeLayoutParameters LayoutParams,
FSHA1 Hasher 
)
inlinestatic

◆ Array()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TArray< ElementType > TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Array ( ) const
inline

Copy the key/value pairs in this map into an array.

◆ begin() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TRangedForIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::begin ( )
inline

DO NOT USE DIRECTLY STL-like iterators to enable range-based for loop support.

◆ begin() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TRangedForConstIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::begin ( ) const
inline

◆ Compact()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Compact ( )
inline

Compacts the pair set to remove holes

◆ CompactStable()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CompactStable ( )
inline

Compacts the pair set to remove holes. Does not change the iteration order of the elements.

◆ Contains()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Contains ( KeyConstPointerType  Key) const
inline

Check if map contains the specified key.

Parameters
KeyThe key to check for.
Returns
true if the map contains the key.

◆ ContainsByHash()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
UE_FORCEINLINE_HINT bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::ContainsByHash ( uint32  KeyHash,
const ComparableKey Key 
) const
inline

See Contains() and class documentation section on ByHash() functions

◆ CopyUnfrozen()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CopyUnfrozen ( const FMemoryUnfreezeContent Context,
void Dst 
) const
inline

◆ CountBytes()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CountBytes ( FArchive Ar) const
inline

Track the container's memory use through an archive.

Parameters
ArThe archive to use.
See also
GetAllocatedSize

◆ CreateConstIterator()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TConstIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CreateConstIterator ( ) const
inline

Creates a const iterator over all the pairs in this map

◆ CreateConstKeyIterator()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TConstKeyIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CreateConstKeyIterator ( typename TConstKeyIterator::KeyArgumentType  InKey) const
inline

Creates a const iterator over the values associated with a specified key in a map

◆ CreateIterator()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CreateIterator ( )
inline

Creates an iterator over all the pairs in this map

◆ CreateKeyIterator()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TKeyIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::CreateKeyIterator ( typename TKeyIterator::KeyArgumentType  InKey)
inline

Creates an iterator over the values associated with a specified key in a map

◆ Dump()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Dump ( FOutputDevice Ar)
inline

Describes the map's contents through an output device.

Parameters
ArThe output device to describe the map's contents through.

◆ Emplace() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename InitKeyType = KeyType>
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Emplace ( InitKeyType &&  InKey)
inline

Set a default value associated with a key.

Parameters
InKeyThe key to associate the value with.
Returns
A reference to the value as stored in the map. The reference is only valid until the next change to any key in the map.

◆ Emplace() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename InitKeyType = KeyType, typename InitValueType = ValueType>
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Emplace ( InitKeyType &&  InKey,
InitValueType &&  InValue 
)
inline

Sets the value associated with a key.

Parameters
InKeyThe key to associate the value with.
InValueThe value to associate with the key.
Returns
A reference to the value as stored in the map. The reference is only valid until the next change to any key in the map.

◆ EmplaceByHash() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename InitKeyType = KeyType>
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::EmplaceByHash ( uint32  KeyHash,
InitKeyType &&  InKey 
)
inline

See Emplace() and class documentation section on ByHash() functions

◆ EmplaceByHash() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename InitKeyType = KeyType, typename InitValueType = ValueType>
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::EmplaceByHash ( uint32  KeyHash,
InitKeyType &&  InKey,
InitValueType &&  InValue 
)
inline

See Emplace() and class documentation section on ByHash() functions

◆ Empty()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Empty ( int32  ExpectedNumElements = 0)
inline

Removes all elements from the map.

This method potentially leaves space allocated for an expected number of elements about to be added.

Parameters
ExpectedNumElementsThe number of elements about to be added to the set.

◆ end() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TRangedForIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::end ( )
inline

◆ end() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT TRangedForConstIterator TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::end ( ) const
inline

◆ FilterByPredicate()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename Predicate >
TMAP< KeyType, ValueType, SetAllocator, KeyFuncs > TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FilterByPredicate ( Predicate  Pred) const
inline

Filters the elements in the map based on a predicate functor.

Parameters
PredThe functor to apply to each element.
Returns
TMAP with the same type as this object which contains the subset of elements for which the functor returns true.

◆ Find() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ValueType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Find ( KeyConstPointerType  Key)
inline

Find the value associated with a specified key.

Parameters
KeyThe key to search for.
Returns
A pointer to the value associated with the specified key, or nullptr if the key isn't contained in this map. The pointer is only valid until the next change to any key in the map.

◆ Find() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT const ValueType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Find ( KeyConstPointerType  Key) const
inline

◆ FindArbitraryElement() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ElementType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindArbitraryElement ( )
inline

Finds any pair in the map and returns a pointer to it. Callers should not depend on particular patterns in the behaviour of this function.

Returns
A pointer to an arbitrary pair, or nullptr if the container is empty.

◆ FindArbitraryElement() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
const ElementType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindArbitraryElement ( ) const
inline

◆ FindByHash() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
ValueType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindByHash ( uint32  KeyHash,
const ComparableKey Key 
)
inline

See Find() and class documentation section on ByHash() functions

◆ FindByHash() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
UE_FORCEINLINE_HINT const ValueType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindByHash ( uint32  KeyHash,
const ComparableKey Key 
) const
inline

◆ FindByHashChecked() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindByHashChecked ( uint32  KeyHash,
const ComparableKey Key 
)
inline

◆ FindByHashChecked() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
UE_FORCEINLINE_HINT const ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindByHashChecked ( uint32  KeyHash,
const ComparableKey Key 
) const
inline

◆ FindChecked() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindChecked ( KeyConstPointerType  Key)
inline

Find a reference to the value associated with a specified key.

Parameters
KeyThe key to search for.
Returns
The value associated with the specified key, or triggers an assertion if the key does not exist.

◆ FindChecked() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
const ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindChecked ( KeyConstPointerType  Key) const
inline

Find a reference to the value associated with a specified key.

Parameters
KeyThe key to search for.
Returns
The value associated with the specified key, or triggers an assertion if the key does not exist.

◆ FindId()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT FSetElementId TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindId ( KeyInitType  Key) const
inline

Finds the index of the first element that is assigned to the specified key. The returned index is only valid until the map is changed.

Parameters
KeyThe key to search for.

◆ FindIdByHash()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
UE_FORCEINLINE_HINT FSetElementId TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindIdByHash ( uint32  KeyHash,
const ComparableKey Key 
) const
inline

See FindId() and class documentation section on ByHash() functions

◆ FindKey()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
const KeyType * TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindKey ( ValueInitType  Value) const
inline

Find the key associated with the specified value.

The time taken is O(N) in the number of pairs.

Parameters
ValueThe value to search for
Returns
A pointer to the key associated with the specified value, or nullptr if the value isn't contained in this map. The pointer is only valid until the next change to any key in the map.

◆ FindOrAdd() [1/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( const KeyType &  Key)
inline

Find the value associated with a specified key, or if none exists, adds a value using the default constructor.

Parameters
KeyThe key to search for.
Returns
A reference to the value associated with the specified key.

◆ FindOrAdd() [2/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( const KeyType &  Key,
const ValueType &  Value 
)
inline

Find the value associated with a specified key, or if none exists, adds a value using the default constructor.

Parameters
KeyThe key to search for.
ValueThe value to associate with the key.
Returns
A reference to the value associated with the specified key.

◆ FindOrAdd() [3/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( const KeyType &  Key,
ValueType &&  Value 
)
inline

◆ FindOrAdd() [4/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( KeyType &&  Key)
inline

◆ FindOrAdd() [5/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( KeyType &&  Key,
const ValueType &  Value 
)
inline

◆ FindOrAdd() [6/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAdd ( KeyType &&  Key,
ValueType &&  Value 
)
inline

◆ FindOrAddByHash() [1/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
const KeyType &  Key 
)
inline

See FindOrAdd() and class documentation section on ByHash() functions

◆ FindOrAddByHash() [2/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
const KeyType &  Key,
const ValueType &  Value 
)
inline

See FindOrAdd() and class documentation section on ByHash() functions

◆ FindOrAddByHash() [3/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
const KeyType &  Key,
ValueType &&  Value 
)
inline

◆ FindOrAddByHash() [4/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
KeyType &&  Key 
)
inline

◆ FindOrAddByHash() [5/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
KeyType &&  Key,
const ValueType &  Value 
)
inline

◆ FindOrAddByHash() [6/6]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ValueType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindOrAddByHash ( uint32  KeyHash,
KeyType &&  Key,
ValueType &&  Value 
)
inline

◆ FindRef() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ValueType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindRef ( KeyConstPointerType  Key) const
inline

Find the value associated with a specified key.

Parameters
KeyThe key to search for.
Returns
The value associated with the specified key, or the default value for the ValueType if the key isn't contained in this map.

◆ FindRef() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ValueType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::FindRef ( KeyConstPointerType  Key,
ValueType  DefaultValue 
) const
inline

Find the value associated with a specified key.

Parameters
KeyThe key to search for.
DefaultValueThe fallback value if the key is not found.
Returns
The value associated with the specified key, or DefaultValue if the key isn't contained in this map.

◆ GenerateKeyArray()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename Allocator >
void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GenerateKeyArray ( TArray< KeyType, Allocator > &  OutArray) const
inline

Generate an array from the keys in this map.

Parameters
OutArrayWill contain the collection of keys.

◆ GenerateValueArray()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename Allocator >
void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GenerateValueArray ( TArray< ValueType, Allocator > &  OutArray) const
inline

Generate an array from the values in this map.

Parameters
OutArrayWill contain the collection of values.

◆ Get() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT ElementType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Get ( FSetElementId  Id)
inline

Return a mapped pair by internal identifier. Element must be valid (see @IsValidId).

◆ Get() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT const ElementType & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Get ( FSetElementId  Id) const
inline

Return a mapped pair by internal identifier. Element must be valid (see @IsValidId).

◆ GetAllocatedSize()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT SIZE_T TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GetAllocatedSize ( ) const
inline

Helper function to return the amount of memory allocated by this container . Only returns the size of allocations made directly by the container, not the elements themselves.

Returns
Number of bytes allocated by this container.
See also
CountBytes

◆ GetKeys() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename Allocator >
int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GetKeys ( TArray< KeyType, Allocator > &  OutKeys) const
inline

Get the unique keys contained within this map.

Parameters
OutKeysUpon return, contains the set of unique keys in this map.
Returns
The number of unique keys in the map.

◆ GetKeys() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GetKeys ( TSet< KeyType, InSetKeyFuncs, InSetAllocator > &  OutKeys) const
inline

Get the unique keys contained within this map.

Parameters
OutKeysUpon return, contains the set of unique keys in this map.
Returns
The number of unique keys in the map.

◆ GetMaxIndex()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::GetMaxIndex ( ) const
inline
Returns
The non-inclusive maximum index of elements in the map.

◆ IsEmpty()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::IsEmpty ( ) const
inline

Returns true if the map is empty and contains no elements.

Returns
True if the map is empty.
See also
Num

◆ IsValidId()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::IsValidId ( FSetElementId  Id) const
inline

Checks whether an element id is valid.

Parameters
Id- The element id to check.
Returns
true if the element identifier refers to a valid element in this map.

◆ Max()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Max ( ) const
inline
Returns
The number of elements the map can hold before reallocation.

◆ Num()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Num ( ) const
inline
Returns
The number of elements in the map.

◆ operator=() [1/4]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::operator= ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  )
protecteddefault

◆ operator=() [2/4]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::operator= ( const TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &  Other)
inlineprotected

Assignment operator for copying elements from a TMAP with a different SetAllocator

◆ operator=() [3/4]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::operator= ( TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &&  )
protecteddefault

◆ operator=() [4/4]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
TMAPBASE & TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::operator= ( TMAPBASE< KeyType, ValueType, OtherSetAllocator, KeyFuncs > &&  Other)
inlineprotected

Assignment operator for moving elements from a TMAP with a different SetAllocator

◆ operator==()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::operator== ( FIntrusiveUnsetOptionalState  Tag) const
inlineprotected

◆ OrderIndependentCompareEqual()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::OrderIndependentCompareEqual ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  Other) const
inline

Compare this map with another for equality. Does not make any assumptions about Key order. NOTE: this might be a candidate for operator== but it was decided to make it an explicit function since it can potentially be quite slow.

Parameters
OtherThe other map to compare against
Returns
True if both this and Other contain the same keys with values that compare ==

◆ Remove() [1/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Remove ( FSetElementId  Id)
inline

Removes the element at the specified index. The caller has to ensure that the index is valid.

Parameters
IdThe index of the element to remove.

◆ Remove() [2/2]

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Remove ( KeyConstPointerType  InKey)
inline

Remove all value associations for a key.

Parameters
InKeyThe key to remove associated values for.
Returns
The number of values that were associated with the key.

◆ RemoveByHash()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
template<typename ComparableKey >
int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::RemoveByHash ( uint32  KeyHash,
const ComparableKey Key 
)
inline

See Remove() and class documentation section on ByHash() functions

◆ RemoveStable()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
int32 TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::RemoveStable ( KeyConstPointerType  InKey)
inline

◆ Reserve()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Reserve ( int32  Number)
inline

Preallocates enough memory to contain Number elements

◆ Reset()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Reset ( )
inline

Efficiently empties out the map but preserves all allocations and capacities

◆ Shrink()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
UE_FORCEINLINE_HINT void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Shrink ( )
inline

Shrinks the pair set to avoid slack.

◆ WriteMemoryImage()

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
void TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::WriteMemoryImage ( FMemoryImageWriter Writer) const
inline

Friends And Related Symbol Documentation

◆ GetTypeHash

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
uint32 GetTypeHash ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  Map)
friend

◆ operator!=

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
bool operator!= ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  ,
const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &   
)
friend

◆ operator==

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
bool operator== ( const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &  ,
const TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs > &   
)
friend

◆ TMAPBASE

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
friend class TMAPBASE
friend

◆ TMAPPRIVATEFRIEND

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
friend struct TMAPPRIVATEFRIEND
friend

Member Data Documentation

◆ bHasIntrusiveUnsetOptionalState

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
constexpr bool TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::bHasIntrusiveUnsetOptionalState = true
staticconstexprprotected

◆ Pairs

template<typename KeyType , typename ValueType , typename SetAllocator , typename KeyFuncs >
ElementSetType TMAPBASE< KeyType, ValueType, SetAllocator, KeyFuncs >::Pairs
protected

A set of the key-value pairs in the map.


The documentation for this class was generated from the following file: