![]() |
Gray C++ Libraries
0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
|
#include <cSingletonPtr.h>
Protected Member Functions | |
cSingletonSmart (TYPE *pObject, const TYPEINFO_t &rAddrCode, int iRefCountStart=0) | |
const void * | get_HeapPtr () const noexcept override |
Get the top level (outermost, freeable) class pointer. I can delete get_HeapPtr(). More... | |
![]() | |
cSingleton (TYPE *pObject, const TYPEINFO_t &rAddrCode=typeid(TYPE)) noexcept | |
virtual | ~cSingleton () |
![]() | |
cSingletonStatic (TYPE *pObject) noexcept | |
virtual | ~cSingletonStatic () noexcept |
![]() | |
cSingletonRegister (const TYPEINFO_t &rAddrCode) noexcept | |
virtual | ~cSingletonRegister () |
void | RegisterSingleton () |
Additional Inherited Members | |
![]() | |
virtual | ~CObject () |
virtual bool | isValidCheck () const noexcept |
< memory allocation and structure definitions are valid. More... | |
virtual void | AssertValid () const |
< memory allocation and structure definitions are valid. More... | |
virtual void | Serialize (cArchive &a) |
![]() | |
cHeapObject () | |
virtual | ~cHeapObject () |
bool | IsValidInsideN (INT_PTR index) const |
bool | IsValidInsidePtr (void const *pTest) const |
virtual size_t | GetHeapStatsThis (OUT ITERATE_t &iAllocCount) const |
virtual bool | isValidCheck () const noexcept |
![]() | |
cRefBase (int iRefCount=0) noexcept | |
virtual | ~cRefBase () |
int | get_RefCount () const noexcept |
HASHCODE_t | get_HashCode () const noexcept |
STDMETHOD_ (HASHCODE_t, get_HashCodeX)() const noexcept | |
virtual void | onFinalRelease () |
bool | isValidObj () const noexcept |
STDMETHOD_ (ULONG, AddRef)(void) override | |
STDMETHOD_ (ULONG, Release)(void) override | |
STDMETHOD() | QueryInterface (const IID &riid, void __RPC_FAR *__RPC_FAR *ppvObject) override |
void | IncRefCount () |
void | DecRefCount () |
bool | isStaticConstruct () const noexcept |
void | StaticConstruct () |
void | StaticDestruct () |
bool | isDestructing () noexcept |
void | SetDestructing () |
![]() | |
static TYPE *__stdcall | get_Single () |
template<class TYPE2 > | |
static TYPE2 *__stdcall | get_SingleT () |
static TYPE &__stdcall | I () |
![]() | |
static bool | isSingleCreated () noexcept |
static TYPE * | get_SingleU () noexcept |
static TYPE * | get_Single () |
template<class TYPE2 > | |
static TYPE2 *__stdcall | get_SingleCast () |
static TYPE & | I () noexcept |
![]() | |
static void __stdcall | ReleaseModule (HMODULE hMod) |
![]() | |
static cThreadLockFast | sm_LockSingle |
common lock for all cSingleton. More... | |
![]() | |
HMODULE | m_hModuleLoaded |
What modules loaded this ? So singletons can be destroyed if DLL/SO unloads. More... | |
![]() | |
static TYPE * | sm_pThe = nullptr |
pointer to the one and only object of this TYPE. ASSUME automatically init to = nullptr. More... | |
Base class for a cSingleton that is reference counted and lazy loaded. This will be destroyed when the last reference is released. recreated on demand. e.g. a public service (shared by all) that is loaded on demand and released when no one needs it.
|
inlineprotected |
typically this == pObject
|
inlineoverrideprotectedvirtualnoexcept |
Get the top level (outermost, freeable) class pointer. I can delete get_HeapPtr().
Reimplemented from Gray::cHeapObject.