TSharedFromThis::AsShared

Provides access to a shared reference to this object.

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Templates/SharedPointer.h

Include

#include "Templates/SharedPointer.h"

Syntax

TSharedRef< ObjectType, Mode > AsShared()

Remarks

Provides access to a shared reference to this object. Note that is only valid to call this after a shared reference (or shared pointer) to the object has already been created. Also note that it is illegal to call this in the object's destructor.

Returns

Returns this object as a shared 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