FWeakObjectPtr::IsValid

Test if this points to a live [UObject](API\Runtime\CoreUObject\UObject\UObject)

Windows
MacOS
Linux

References

Module

CoreUObject

Header

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

Include

#include "UObject/WeakObjectPtr.h"

Source

/Engine/Source/Runtime/CoreUObject/Private/UObject/WeakObjectPtr.cpp

Syntax

bool IsValid
(
    bool bEvenIfPendingKill,
    bool bThreadsafeTest
) const

Remarks

Test if this points to a live UObject

Returns

true if Get() would return a valid non-null pointer

Parameters

Parameter

Description

bEvenIfPendingKill

if this is true, pendingkill are not considered invalid

bThreadsafeTest

if true then function will just give you information whether referenced UObject is gone forever (return false) or if it is still there (return true, no object flags checked).

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