Cyrus Mod Loader
Loading...
Searching...
No Matches
SharedObjectDeleter< T > Class Template Referenceabstract

Manages shared and weak references to an object and provides deletion management. More...

#include <PropertyClass.h>

Public Member Functions

virtual size_t isSame (void *other)=0
 Compares the typeID of other to the compile-time type ID of this.
 
int getSharedRefCount ()
 Gets the shared reference count.
 
int getWeakRefCount ()
 Gets the weak reference count.
 
T * getObject ()
 Gets the managed object.
 
size_t getTypeID ()
 Gets the type identifier of the managed object.
 

Detailed Description

template<class T>
class SharedObjectDeleter< T >

Manages shared and weak references to an object and provides deletion management.

Template Parameters
TThe type of the object being managed.

Member Function Documentation

◆ getObject()

template<class T >
T * SharedObjectDeleter< T >::getObject ( )
inline

Gets the managed object.

Returns
Pointer to the managed object.

◆ getSharedRefCount()

template<class T >
int SharedObjectDeleter< T >::getSharedRefCount ( )
inline

Gets the shared reference count.

Returns
The number of shared references.

◆ getTypeID()

template<class T >
size_t SharedObjectDeleter< T >::getTypeID ( )
inline

Gets the type identifier of the managed object.

Returns
The type identifier.

◆ getWeakRefCount()

template<class T >
int SharedObjectDeleter< T >::getWeakRefCount ( )
inline

Gets the weak reference count.

Returns
The number of weak references.

◆ isSame()

template<class T >
virtual size_t SharedObjectDeleter< T >::isSame ( void * other)
pure virtual

Compares the typeID of other to the compile-time type ID of this.

Parameters
otherPointer to another object to compare.
Returns
The typeID if the types are the same, 0 otherwise.