DDraceNetwork Docs
CLoggerCollection Class Reference
Inheritance diagram for CLoggerCollection:
[legend]
Collaboration diagram for CLoggerCollection:
[legend]

Public Member Functions

 CLoggerCollection (std::vector< std::shared_ptr< ILogger > > &&vpLoggers)
 
void Log (const CLogMessage *pMessage) override
 
void GlobalFinish () override
 
- Public Member Functions inherited from ILogger
virtual ~ILogger ()
 
void SetFilter (const CLogFilter &Filter)
 
virtual void Log (const CLogMessage *pMessage)=0
 
virtual void GlobalFinish ()
 
virtual void OnFilterChange ()
 

Private Attributes

std::vector< std::shared_ptr< ILogger > > m_vpLoggers
 

Additional Inherited Members

- Protected Attributes inherited from ILogger
CLogFilter m_Filter
 

Constructor & Destructor Documentation

◆ CLoggerCollection()

CLoggerCollection::CLoggerCollection ( std::vector< std::shared_ptr< ILogger > > &&  vpLoggers)
inline

Member Function Documentation

◆ GlobalFinish()

void CLoggerCollection::GlobalFinish ( )
inlineoverridevirtual

Flushes output buffers and shuts down. Global loggers cannot be destroyed because they might be accessed from multiple threads concurrently.

This function is called on the global logger by log_global_logger_finish when the program is about to shut down and loggers are supposed to finish writing the log messages they have received so far.

The destructor of this ILogger instance will not be called if this function is called.

See also
log_global_logger_finish

Reimplemented from ILogger.

◆ Log()

void CLoggerCollection::Log ( const CLogMessage pMessage)
inlineoverridevirtual

Send the specified message to the logging backend.

Parameters
pMessageStruct describing the log message.

Implements ILogger.

Member Data Documentation

◆ m_vpLoggers

std::vector<std::shared_ptr<ILogger> > CLoggerCollection::m_vpLoggers
private

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