Gray C++ Libraries  0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
Gray::cLogAppendConsole Class Reference

#include <cLogAppendConsole.h>

Inheritance diagram for Gray::cLogAppendConsole:
Gray::cLogAppender Gray::cSingletonSmart< cLogAppendConsole > IUnknown Gray::cLogProcessor Gray::cSingleton< TYPE > Gray::cRefBase Gray::ILogProcessor Gray::cStreamOutput Gray::cSingletonStatic< TYPE > Gray::cSingletonRegister IUnknown Gray::cStreamBase Gray::CObject Gray::cHeapObject Gray::IHeapObject

Public Member Functions

 cLogAppendConsole ()
 
virtual ~cLogAppendConsole ()
 
virtual HRESULT WriteString (const LOGCHAR_t *pszMsg) override
 
const void * get_HeapPtr () const noexcept override
 Get the top level (outermost, freeable) class pointer. I can delete get_HeapPtr(). More...
 
STDMETHOD() QueryInterface (const IID &riid, void __RPC_FAR *__RPC_FAR *ppvObject) override
 
 STDMETHOD_ (ULONG, AddRef)(void) override
 
 STDMETHOD_ (ULONG, Release)(void) override
 
- Public Member Functions inherited from Gray::cLogAppender
 cLogAppender ()
 
virtual ~cLogAppender ()
 
bool RemoveAppenderThis ()
 Remove myself from the list of valid appenders. More...
 
virtual HRESULT addEvent (cLogEvent *pEvent) override
 
- Public Member Functions inherited from Gray::cLogProcessor
virtual ~cLogProcessor ()
 
virtual const cLogNexusget_ThisLogNexus () const
 
virtual bool IsLogged (LOG_ATTR_MASK_t uAttrMask, LOGLEV_TYPE eLogLevel) const override
 
virtual HRESULT FlushLogs ()
 
HRESULT addEventS (LOG_ATTR_MASK_t uAttrMask, LOGLEV_TYPE eLogLevel, cStringL sMsg, cStringL sContext="")
 
HRESULT addEventV (LOG_ATTR_MASK_t uAttrMask, LOGLEV_TYPE eLogLevel, const LOGCHAR_t *pszFormat, va_list vargs)
 
HRESULT _cdecl addEventF (LOG_ATTR_MASK_t uAttrMask, LOGLEV_TYPE eLogLevel, const LOGCHAR_t *pszFormat,...)
 
HRESULT _cdecl addInfoF (const LOGCHAR_t *pszFormat,...)
 
HRESULT _cdecl addDebugErrorF (const LOGCHAR_t *pszFormat,...)
 
HRESULT _cdecl addDebugWarnF (const LOGCHAR_t *pszFormat,...)
 
HRESULT _cdecl addDebugInfoF (const LOGCHAR_t *pszFormat,...)
 
HRESULT _cdecl addDebugTraceF (const LOGCHAR_t *pszFormat,...)
 
- Public Member Functions inherited from Gray::cStreamOutput
 cStreamOutput () noexcept
 
virtual ~cStreamOutput ()
 
virtual HRESULT WriteX (const void *pData, size_t nDataSize)
 
HRESULT WriteT (const void *pVal, size_t nDataSize)
 
template<typename TYPE >
HRESULT WriteT (TYPE val)
 
HRESULT WriteSize (size_t nSize)
 
HRESULT WriteHashCode (HASHCODE_t nHashCode)
 
HRESULT WriteN (const void *pBuffer, size_t nSize)
 
template<typename _CH >
HRESULT WriteStringN (const _CH *pszStr)
 
template<typename _CH >
HRESULT WriteCharRepeat (_CH nChar, int nCount=1)
 
StrLen_t VPrintf (const char *pszFormat, va_list args)
 
StrLen_t VPrintf (const wchar_t *pszFormat, va_list args)
 
StrLen_t _cdecl Printf (const char *pszFormat,...)
 
StrLen_t _cdecl Printf (const wchar_t *pszFormat,...)
 
HRESULT WriteStream (cStreamInput &sInp, STREAM_POS_t nSizeMax=k_FILE_BLOCK_SIZE, IStreamProgressCallback *pProgress=nullptr, TIMESYSD_t nTimeout=0)
 Copy cStreamInput to this stream. More...
 
virtual HRESULT FlushX ()
 
- Public Member Functions inherited from Gray::cStreamBase
virtual ~cStreamBase ()
 
virtual STREAM_SEEKRET_t Seek (STREAM_OFFSET_t iOffset, SEEK_ORIGIN_TYPE eSeekOrigin=SEEK_Set)
 
void SeekToBegin ()
 
STREAM_POS_t SeekToEnd ()
 
virtual STREAM_POS_t GetPosition () const
 
virtual STREAM_POS_t GetLength () const
 
- Public Member Functions inherited from Gray::CObject
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)
 
- Public Member Functions inherited from Gray::cHeapObject
 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
 
- Public Member Functions inherited from Gray::cRefBase
 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 Public Member Functions

static HRESULT __stdcall AddAppenderCheck (cLogNexus *pLogger=nullptr, bool bAttachElseAlloc=false)
 
static bool __stdcall RemoveAppenderCheck (cLogNexus *pLogger, bool bOnlyIfParent)
 
static HRESULT __stdcall ShowMessageBox (cString sMsg, UINT uFlags=1)
 
static HRESULT __stdcall WaitForDebugger ()
 
- Static Public Member Functions inherited from Gray::cSingleton< TYPE >
static TYPE *__stdcall get_Single ()
 
template<class TYPE2 >
static TYPE2 *__stdcall get_SingleT ()
 
static TYPE &__stdcall I ()
 
- Static Public Member Functions inherited from Gray::cSingletonStatic< TYPE >
static bool isSingleCreated () noexcept
 
static TYPEget_SingleU () noexcept
 
static TYPEget_Single ()
 
template<class TYPE2 >
static TYPE2 *__stdcall get_SingleCast ()
 
static TYPEI () noexcept
 
- Static Public Member Functions inherited from Gray::cSingletonRegister
static void __stdcall ReleaseModule (HMODULE hMod)
 

Additional Inherited Members

- Static Public Attributes inherited from Gray::cStreamBase
static const BYTE k_SIZE_MASK = 0x80
 Used for WriteSize() More...
 
static const size_t k_FILE_BLOCK_SIZE = (32 * 1024)
 default arbitrary transfer block size. more than this is NOT more efficient. More...
 
- Static Public Attributes inherited from Gray::cSingletonRegister
static cThreadLockFast sm_LockSingle
 common lock for all cSingleton. More...
 
- Protected Member Functions inherited from Gray::cLogAppender
virtual HRESULT WriteString (const wchar_t *pszMsg) override
 
- Protected Member Functions inherited from Gray::cSingletonSmart< cLogAppendConsole >
 cSingletonSmart (cLogAppendConsole *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...
 
- Protected Member Functions inherited from Gray::cSingleton< TYPE >
 cSingleton (TYPE *pObject, const TYPEINFO_t &rAddrCode=typeid(TYPE)) noexcept
 
virtual ~cSingleton ()
 
- Protected Member Functions inherited from Gray::cSingletonStatic< TYPE >
 cSingletonStatic (TYPE *pObject) noexcept
 
virtual ~cSingletonStatic () noexcept
 
- Protected Member Functions inherited from Gray::cSingletonRegister
 cSingletonRegister (const TYPEINFO_t &rAddrCode) noexcept
 
virtual ~cSingletonRegister ()
 
void RegisterSingleton ()
 
- Protected Attributes inherited from Gray::cSingletonRegister
HMODULE m_hModuleLoaded
 What modules loaded this ? So singletons can be destroyed if DLL/SO unloads. More...
 
- Static Protected Attributes inherited from Gray::cSingletonStatic< TYPE >
static TYPEsm_pThe = nullptr
 pointer to the one and only object of this TYPE. ASSUME automatically init to = nullptr. More...
 

Detailed Description

Forward debug statements to the console (cAppConsole) (if i have one) No filter and take default formatted string

Constructor & Destructor Documentation

◆ cLogAppendConsole()

Gray::cLogAppendConsole::cLogAppendConsole ( )

◆ ~cLogAppendConsole()

virtual Gray::cLogAppendConsole::~cLogAppendConsole ( )
virtual

Member Function Documentation

◆ AddAppenderCheck()

static HRESULT __stdcall Gray::cLogAppendConsole::AddAppenderCheck ( cLogNexus pLogger = nullptr,
bool  bAttachElseAlloc = false 
)
static

◆ get_HeapPtr()

const void* Gray::cLogAppendConsole::get_HeapPtr ( ) const
inlineoverridevirtualnoexcept

Get the top level (outermost, freeable) class pointer. I can delete get_HeapPtr().

Reimplemented from Gray::cHeapObject.

◆ QueryInterface()

STDMETHOD() Gray::cLogAppendConsole::QueryInterface ( const IID riid,
void __RPC_FAR *__RPC_FAR *  ppvObject 
)
inlineoverride

◆ RemoveAppenderCheck()

static bool __stdcall Gray::cLogAppendConsole::RemoveAppenderCheck ( cLogNexus pLogger,
bool  bOnlyIfParent 
)
static

◆ ShowMessageBox()

static HRESULT __stdcall Gray::cLogAppendConsole::ShowMessageBox ( cString  sMsg,
UINT  uFlags = 1 
)
static

◆ STDMETHOD_() [1/2]

Gray::cLogAppendConsole::STDMETHOD_ ( ULONG  ,
AddRef   
)
inlineoverride

◆ STDMETHOD_() [2/2]

Gray::cLogAppendConsole::STDMETHOD_ ( ULONG  ,
Release   
)
inlineoverride

◆ WaitForDebugger()

static HRESULT __stdcall Gray::cLogAppendConsole::WaitForDebugger ( )
static

◆ WriteString()

virtual HRESULT Gray::cLogAppendConsole::WriteString ( const LOGCHAR_t pszMsg)
overridevirtual

Reimplemented from Gray::cLogAppender.


The documentation for this class was generated from the following file: