blocxx
Public Member Functions | List of all members
BLOCXX_NAMESPACE::NullLogger Class Reference

This logger just discards all log messages. More...

#include <NullLogger.hpp>

Inheritance diagram for BLOCXX_NAMESPACE::NullLogger:
BLOCXX_NAMESPACE::Logger BLOCXX_NAMESPACE::IntrusiveCountableBase

Public Member Functions

 NullLogger ()
 
- Public Member Functions inherited from BLOCXX_NAMESPACE::Logger
 Logger (const String &defaultComponent=STR_DEFAULT_COMPONENT, const LogAppenderRef &appender=LogAppenderRef())
 
 Logger (const String &defaultComponent, const ELogLevel logLevel)
 
 Logger (const Logger &)
 
Loggeroperator= (const Logger &)
 
void swap (Logger &x)
 
virtual ~Logger ()
 
virtual LoggerRef clone () const BLOCXX_DEPRECATED
 
void logFatalError (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 Log message with a fatal error category and the default component. More...
 
void logError (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_ERROR_LEVEL, Log message with an error category and the default component. More...
 
void logWarning (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_WARNING_LEVEL, Log info. More...
 
void logInfo (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_INFO_LEVEL, Log info. More...
 
void logDebug (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_DEBUG_LEVEL, Log debug info. More...
 
void logDebug2 (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_DEBUG2_LEVEL, Log debug info. More...
 
void logDebug3 (const String &message, const char *filename=0, int fileline=-1, const char *methodname=0) const
 If getLogLevel() >= E_DEBUG3_LEVEL, Log debug info. More...
 
void logMessage (const String &component, const String &category, const String &message) const
 Log a message using the specified component and category The current log level is ignored. More...
 
void logMessage (const String &component, const String &category, const String &message, const char *filename, int fileline, const char *methodname) const
 Log a message using the specified component and category The current log level is ignored. More...
 
void logMessage (const String &category, const String &message) const
 Log a message using the default component and specified category. More...
 
void logMessage (const String &category, const String &message, const char *filename, int fileline, const char *methodname) const
 Log a message using the default component and specified category. More...
 
void logMessage (const LogMessage &message) const
 Log a message. More...
 
void setDefaultComponent (const String &component)
 Sets the default component. More...
 
String getDefaultComponent () const
 Gets the default component. More...
 
ELogLevel getLogLevel () const
 
void setLogLevel (ELogLevel logLevel)
 Set the log level. More...
 
void setLogLevel (const String &logLevel)
 Set the log level. More...
 
bool categoryIsEnabled (const String &category) const
 Determine if the log category is enabled. More...
 
bool levelIsEnabled (const ELogLevel level) const
 Check if the logger is enabled for given level. More...
 
bool componentAndCategoryAreEnabled (const String &component, const String &category) const
 Determine if the component and category are both enabled. More...
 

Additional Inherited Members

- Public Types inherited from BLOCXX_NAMESPACE::Logger
enum  ELoggerErrorCodes { E_UNKNOWN_LOG_APPENDER_TYPE, E_INVALID_MAX_FILE_SIZE, E_INVALID_MAX_BACKUP_INDEX }
 
- Static Public Member Functions inherited from BLOCXX_NAMESPACE::Logger
static ELogLevel stringToLogLevel (const String &logLevel)
 Convert a log level string to an enum value. More...
 
static String logLevelToString (ELogLevel logLevel)
 Convert a log level enum to a string. More...
 
static const LoggerasLogger (const Logger &lgr)
 Utility functions for backward compatibility with LoggerRef and the BLOCXX_LOG macros. More...
 
static const LoggerasLogger (const LoggerRef &lgr)
 
- Static Public Attributes inherited from BLOCXX_NAMESPACE::Logger
static const GlobalString STR_NONE_CATEGORY = { "NONE" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_FATAL_CATEGORY = { "FATAL" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_ERROR_CATEGORY = { "ERROR" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_WARNING_CATEGORY = { "WARNING" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_INFO_CATEGORY = { "INFO" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_DEBUG_CATEGORY = { "DEBUG" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_DEBUG2_CATEGORY = { "DEBUG2" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_DEBUG3_CATEGORY = { "DEBUG3" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_ALL_CATEGORY = { "ALL" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
static const GlobalString STR_DEFAULT_COMPONENT = { "none" , 0, {0, PTHREAD_MUTEX_INITIALIZER} }
 
- Protected Member Functions inherited from BLOCXX_NAMESPACE::IntrusiveCountableBase
 IntrusiveCountableBase ()
 
 IntrusiveCountableBase (const IntrusiveCountableBase &)
 
IntrusiveCountableBaseoperator= (const IntrusiveCountableBase &)
 
virtual ~IntrusiveCountableBase ()
 
- Protected Attributes inherited from BLOCXX_NAMESPACE::Logger
String m_defaultComponent
 
LogAppenderRef m_appender
 
ELogLevel m_logLevel
 

Detailed Description

This logger just discards all log messages.

Definition at line 49 of file NullLogger.hpp.

Constructor & Destructor Documentation

◆ NullLogger()

BLOCXX_NAMESPACE::NullLogger::NullLogger ( )

Definition at line 48 of file NullLogger.cpp.


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