LoggerBase Class Reference

Base class for the various logging mechanisms. More...

#include <logging.h>

Inheritance diagram for LoggerBase:
DatabaseLogger FileLogger SyslogLogger

List of all members.

Public Member Functions

 LoggerBase (char *string, int number)
 LoggerBase Constructor.
virtual ~LoggerBase ()
 LoggerBase Deconstructor.
virtual bool logmsg (LoggingItem *item)=0
 Process a log message for the logger instance.
virtual void reopen (void)=0
 Reopen the log file to facilitate log rolling.
virtual void stopDatabaseAccess (void)
 Stop logging to the database.

Protected Attributes

LoggerHandle_t m_handle
 semi-opaque handle for identifying instance
bool m_string
 true if m_handle.string valid, false otherwise

Detailed Description

Base class for the various logging mechanisms.

Definition at line 34 of file libmythbase/logging.h.


Constructor & Destructor Documentation

LoggerBase::LoggerBase ( char *  string,
int  number 
)

LoggerBase Constructor.

LoggerBase class constructor.

Adds the new logger instance to the loggerList.

Parameters:
string a C-string of the handle for this instance (NULL if unused)
number an integer for the handle for this instance

Definition at line 177 of file logging.cpp.

LoggerBase::~LoggerBase (  )  [virtual]

LoggerBase Deconstructor.

LoggerBase deconstructor.

Removes the logger instance from the loggerList.

Definition at line 195 of file logging.cpp.


Member Function Documentation

virtual bool LoggerBase::logmsg ( LoggingItem item  )  [pure virtual]

Process a log message for the logger instance.

Parameters:
item LoggingItem containing the log message to process

Implemented in FileLogger, SyslogLogger, and DatabaseLogger.

virtual void LoggerBase::reopen ( void   )  [pure virtual]

Reopen the log file to facilitate log rolling.

Implemented in FileLogger, SyslogLogger, and DatabaseLogger.

virtual void LoggerBase::stopDatabaseAccess ( void   )  [inline, virtual]

Stop logging to the database.

Reimplemented in DatabaseLogger.

Definition at line 48 of file libmythbase/logging.h.


Member Data Documentation

true if m_handle.string valid, false otherwise

Definition at line 51 of file libmythbase/logging.h.

Referenced by LoggerBase(), and ~LoggerBase().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends
Generated on Mon May 28 06:42:08 2012 for MythTV by  doxygen 1.6.3