|
FORCEINLINE | TSharedPtr (SharedPointerInternals::FNullTag *=nullptr) |
|
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE | TSharedPtr (OtherType *InObject) |
|
template<typename OtherType , typename DeleterType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE | TSharedPtr (OtherType *InObject, DeleterType &&InDeleter) |
|
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE | TSharedPtr (SharedPointerInternals::FRawPtrProxy< OtherType > const &InRawPtrProxy) |
|
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE | TSharedPtr (TSharedPtr< OtherType, Mode > const &InSharedPtr) |
|
FORCEINLINE | TSharedPtr (TSharedPtr const &InSharedPtr) |
|
FORCEINLINE | TSharedPtr (TSharedPtr &&InSharedPtr) |
|
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE | TSharedPtr (TSharedRef< OtherType, Mode > const &InSharedRef) |
|
template<typename OtherType > |
FORCEINLINE | TSharedPtr (TSharedPtr< OtherType, Mode > const &InSharedPtr, SharedPointerInternals::FStaticCastTag) |
|
template<typename OtherType > |
FORCEINLINE | TSharedPtr (TSharedPtr< OtherType, Mode > const &InSharedPtr, SharedPointerInternals::FConstCastTag) |
|
template<typename OtherType > |
FORCEINLINE | TSharedPtr (TSharedPtr< OtherType, Mode > const &OtherSharedPtr, ObjectType *InObject) |
|
template<typename OtherType > |
FORCEINLINE | TSharedPtr (TSharedPtr< OtherType, Mode > &&OtherSharedPtr, ObjectType *InObject) |
|
template<typename OtherType > |
FORCEINLINE | TSharedPtr (TSharedRef< OtherType, Mode > const &OtherSharedRef, ObjectType *InObject) |
|
FORCEINLINE TSharedPtr & | operator= (SharedPointerInternals::FNullTag *) |
|
FORCEINLINE TSharedPtr & | operator= (TSharedPtr const &InSharedPtr) |
|
FORCEINLINE TSharedPtr & | operator= (TSharedPtr &&InSharedPtr) |
|
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type> |
FORCEINLINE TSharedPtr & | operator= (SharedPointerInternals::FRawPtrProxy< OtherType > const &InRawPtrProxy) |
|
FORCEINLINE TSharedRef< ObjectType, Mode > | ToSharedRef () const |
|
FORCEINLINE ObjectType * | Get () const |
|
FORCEINLINE const bool | IsValid () const |
|
FORCEINLINE FMakeReferenceTo< ObjectType >::Type | operator* () const |
|
FORCEINLINE ObjectType * | operator-> () const |
|
FORCEINLINE void | Reset () |
|
FORCEINLINE const int32 | GetSharedReferenceCount () const |
|
FORCEINLINE const bool | IsUnique () const |
|
template<class ObjectType, int Mode>
class TSharedPtr< ObjectType, Mode >
TSharedPtr is a non-intrusive reference-counted authoritative object pointer. This shared pointer will be conditionally thread-safe when the optional Mode template argument is set to ThreadSafe.
Definition at line 522 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Constructs a shared pointer that owns the specified object. Note that passing nullptr here will still create a tracked reference to a nullptr pointer. (Consistent with std::shared_ptr)
- Parameters
-
InObject | Object this shared pointer to retain a reference to |
Definition at line 545 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename DeleterType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Constructs a shared pointer that owns the specified object. Note that passing nullptr here will still create a tracked reference to a nullptr pointer. (Consistent with std::shared_ptr)
- Parameters
-
InObject | Object this shared pointer to retain a reference to |
InDeleter | Deleter object used to destroy the object when it is no longer referenced. |
Definition at line 566 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Constructs a shared pointer using a proxy reference to a raw pointer. (See MakeShareable())
- Parameters
-
InRawPtrProxy | Proxy raw pointer that contains the object that the new shared pointer will reference |
Definition at line 585 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Constructs a shared pointer as a shared reference to an existing shared pointer's object. This constructor is needed so that we can implicitly upcast to base classes.
- Parameters
-
InSharedPtr | The shared pointer whose object we should create an additional reference to |
Definition at line 604 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Implicitly converts a shared reference to a shared pointer, adding a reference to the object. NOTE: We allow an implicit conversion from TSharedRef to TSharedPtr because it's always a safe conversion.
- Parameters
-
InSharedRef | The shared reference that will be converted to a shared pointer |
Definition at line 632 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType >
Special constructor used internally to statically cast one shared pointer type to another. You should never call this constructor directly. Instead, use the StaticCastSharedPtr() function. This constructor creates a shared pointer as a shared reference to an existing shared pointer after statically casting that pointer's object. This constructor is needed for static casts.
- Parameters
-
InSharedPtr | The shared pointer whose object we should create an additional reference to |
Definition at line 649 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType >
Special constructor used internally to cast a 'const' shared pointer a 'mutable' pointer. You should never call this constructor directly. Instead, use the ConstCastSharedPtr() function. This constructor creates a shared pointer as a shared reference to an existing shared pointer after const casting that pointer's object. This constructor is needed for const casts.
- Parameters
-
InSharedPtr | The shared pointer whose object we should create an additional reference to |
Definition at line 663 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType >
Aliasing constructor used to create a shared pointer which shares its reference count with another shared object, but pointing to a different object, typically a subobject.
- Parameters
-
OtherSharedPtr | The shared pointer whose reference count should be shared. |
InObject | The object pointer to use (instead of the incoming shared pointer's object) |
Definition at line 676 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType >
Aliasing constructor used to create a shared pointer which shares its reference count with another shared object, but pointing to a different object, typically a subobject.
- Parameters
-
OtherSharedPtr | The shared pointer whose reference count should be shared. |
InObject | The object pointer to use (instead of the incoming shared pointer's object) |
Definition at line 689 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType >
Aliasing constructor used to create a shared pointer which shares its reference count with another shared object, but pointing to a different object, typically a subobject.
- Parameters
-
OtherSharedRef | The shared reference whose reference count should be shared. |
InObject | The object pointer to use (instead of the incoming shared pointer's object) |
Definition at line 704 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Constructs a shared pointer from a weak pointer, allowing you to access the object (if it hasn't expired yet.) Remember, if there are no more shared references to the object, the shared pointer will not be valid. You should always check to make sure this shared pointer is valid before trying to dereference the shared pointer!
NOTE: This constructor is private to force users to be explicit when converting a weak pointer to a shared pointer. Use the weak pointer's Pin() method instead!
Definition at line 866 of file SharedPointer.h.
template<class ObjectType , int Mode>
template<typename OtherType , typename = typename TEnableIf<TPointerIsConvertibleFromTo<OtherType, ObjectType>::Value>::Type>
Assignment operator replaces this shared pointer with the specified shared pointer. The object currently referenced by this shared pointer will no longer be referenced and will be deleted if there are no other referencers.
- Parameters
-
InRawPtrProxy | Proxy object used to assign the object (see MakeShareable helper function) |
Definition at line 757 of file SharedPointer.h.