UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
TObjectKey< InElementType > Class Template Reference

#include <ObjectKey.h>

Public Types

typedef InElementType ElementType
 

Public Member Functions

UE_FORCEINLINE_HINT TObjectKey ()=default
 
template<typename U >
UE_FORCEINLINE_HINT TObjectKey (U Object)
 
UE_FORCEINLINE_HINT bool operator== (const TObjectKey &Other) const
 
UE_FORCEINLINE_HINT bool operator!= (const TObjectKey &Other) const
 
UE_FORCEINLINE_HINT bool operator< (const TObjectKey &Other) const
 
UE_FORCEINLINE_HINT bool operator<= (const TObjectKey &Other) const
 
UE_FORCEINLINE_HINT bool operator> (const TObjectKey &Other) const
 
UE_FORCEINLINE_HINT bool operator>= (const TObjectKey &Other) const
 
InElementTypeResolveObjectPtr () const
 
InElementTypeResolveObjectPtrEvenIfGarbage () const
 
InElementTypeResolveObjectPtrEvenIfPendingKill () const
 

Friends

uint32 GetTypeHash (const TObjectKey &Key)
 

Detailed Description

template<typename InElementType>
class TObjectKey< InElementType >

TObjectKey is a strongly typed, immutable, copyable key which can be used to uniquely identify an object for the lifetime of the application

Member Typedef Documentation

◆ ElementType

Constructor & Destructor Documentation

◆ TObjectKey() [1/2]

Default constructor

◆ TObjectKey() [2/2]

Construct from an object pointer

Member Function Documentation

◆ operator!=()

Compare this key with another

◆ operator<()

template<typename InElementType >
UE_FORCEINLINE_HINT bool TObjectKey< InElementType >::operator< ( const TObjectKey< InElementType > &  Other) const
inline

Compare this key with another

◆ operator<=()

template<typename InElementType >
UE_FORCEINLINE_HINT bool TObjectKey< InElementType >::operator<= ( const TObjectKey< InElementType > &  Other) const
inline

Compare this key with another

◆ operator==()

template<typename InElementType >
UE_FORCEINLINE_HINT bool TObjectKey< InElementType >::operator== ( const TObjectKey< InElementType > &  Other) const
inline

Compare this key with another

◆ operator>()

template<typename InElementType >
UE_FORCEINLINE_HINT bool TObjectKey< InElementType >::operator> ( const TObjectKey< InElementType > &  Other) const
inline

Compare this key with another

◆ operator>=()

template<typename InElementType >
UE_FORCEINLINE_HINT bool TObjectKey< InElementType >::operator>= ( const TObjectKey< InElementType > &  Other) const
inline

Compare this key with another

◆ ResolveObjectPtr()

template<typename InElementType >
InElementType * TObjectKey< InElementType >::ResolveObjectPtr ( ) const
inline

Attempt to access the object from which this key was constructed.

Returns
The object used to construct this key, or nullptr if it is no longer valid

◆ ResolveObjectPtrEvenIfGarbage()

template<typename InElementType >
InElementType * TObjectKey< InElementType >::ResolveObjectPtrEvenIfGarbage ( ) const
inline

Attempt to access the object from which this key was constructed, even if it is marked as Garbage.

Returns
The object used to construct this key, or nullptr if it is no longer valid

◆ ResolveObjectPtrEvenIfPendingKill()

template<typename InElementType >
InElementType * TObjectKey< InElementType >::ResolveObjectPtrEvenIfPendingKill ( ) const
inline

Friends And Related Symbol Documentation

◆ GetTypeHash

template<typename InElementType >
uint32 GetTypeHash ( const TObjectKey< InElementType > &  Key)
friend

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