TLazyObjectPtr

[TLazyObjectPtr](API\Runtime\CoreUObject\UObject\TLazyObjectPtr) is templatized version of the generic [FLazyObjectPtr](API\Runtime\CoreUObject\UObject\FLazyObjectPtr)

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

CoreUObject

Header

/Engine/Source/Runtime/CoreUObject/Public/UObject/LazyObjectPtr.h

Include

#include "UObject/LazyObjectPtr.h"

Syntax

template<class T>
struct TLazyObjectPtr : private FLazyObjectPtr

Remarks

TLazyObjectPtr is templatized version of the generic FLazyObjectPtr

Constructors

Name Description

Public function

TLazyObjectPtr()

Public function

TLazyObjectPtr

(
    TLazyObjectPtr< T >&&
)

Public function

TLazyObjectPtr

(
    const TLazyObjectPtr< T >&
)

Public function

TLazyObjectPtr

(
    const TLazyObjectPtr< U >& Other
)

Construct from another lazy pointer with implicit upcasting allowed

Public function

TLazyObjectPtr

(
    T* Object
)

Construct from an object pointer

Functions

Name Description

Public function Const

T *

 

Get()

Dereference the lazy pointer.

Public function Const

const FUniqu...

 

GetUniqueID()

Gets the unique object identifier associated with this lazy pointer.

Public function Const

bool

 

IsNull()

Test if this can never point to a live UObject

Public function Const

bool

 

IsPending()

Test if this does not point to a live UObject, but may in the future

Public function Const

bool

 

IsStale()

Slightly different than !IsValid(), returns true if this used to point to a UObject, but doesn't any more and has not been assigned or reset in the mean time.

Public function Const

bool

 

IsValid()

Test if this points to a live UObject

Public function

void

 

Reset()

Reset the lazy pointer back to the null state

Operators

Name Description

Public function Const

 

operator bool()

Dereference lazy pointer to see if it points somewhere valid

Public function Const

T &

 

operator*()

Dereference the lazy pointer

Public function

void

 

operator=

(
    const FUniqueObjectGuid& InObjectI...
)

Copy from a unique object identifier WARNING: this doesn't check the type of the object is correct, because the object corresponding to this ID may not even be loaded!

Public function

TLazyObjectP...

 

operator=

(
    TLazyObjectPtr< T >&&
)

Public function

TLazyObjectP...

 

operator=

(
    const TLazyObjectPtr< T >&
)

Public function

TLazyObjectP...

 

operator=

(
    const TLazyObjectPtr< U >& Other
)

Assign from another lazy pointer with implicit upcasting allowed

Public function

void

 

operator=

(
    T* Object
)

Copy from an object pointer

Public function Const

T *

 

operator->()

Dereference the lazy pointer

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss