|
μHAL (v2.7.9)
Part of the IPbus software repository
|
Go to the documentation of this file.
4 #include <boost/thread/mutex.hpp>
19 char * lEnvVar = getenv ( aEnvVar );
22 log(
Warning() ,
"No environment variable " ,
Quote( aEnvVar ) ,
" set. Using level " ,
Quote(
"Info" ) ,
" instead." );
56 log (
Warning() ,
"Environment varible has invalid value " ,
Quote( lEnvVar ) ,
". Using level " ,
Quote (
"Info" ) ,
" instead." );
90 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
102 #ifndef LOGGING_EXCLUDE_FATAL
110 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
112 #ifndef LOGGING_EXCLUDE_ERROR // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
124 #ifndef LOGGING_EXCLUDE_FATAL
125 #ifndef LOGGING_EXCLUDE_ERROR
134 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
136 #ifndef LOGGING_EXCLUDE_ERROR // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
138 #ifndef LOGGING_EXCLUDE_WARNING // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
150 #ifndef LOGGING_EXCLUDE_FATAL
151 #ifndef LOGGING_EXCLUDE_ERROR
152 #ifndef LOGGING_EXCLUDE_WARNING
162 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
164 #ifndef LOGGING_EXCLUDE_ERROR // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
166 #ifndef LOGGING_EXCLUDE_WARNING // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
168 #ifndef LOGGING_EXCLUDE_NOTICE // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
180 #ifndef LOGGING_EXCLUDE_FATAL
181 #ifndef LOGGING_EXCLUDE_ERROR
182 #ifndef LOGGING_EXCLUDE_WARNING
183 #ifndef LOGGING_EXCLUDE_NOTICE
194 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
196 #ifndef LOGGING_EXCLUDE_ERROR // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
198 #ifndef LOGGING_EXCLUDE_WARNING // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
200 #ifndef LOGGING_EXCLUDE_NOTICE // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
202 #ifndef LOGGING_EXCLUDE_INFO // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
214 #ifndef LOGGING_EXCLUDE_FATAL
215 #ifndef LOGGING_EXCLUDE_ERROR
216 #ifndef LOGGING_EXCLUDE_WARNING
217 #ifndef LOGGING_EXCLUDE_NOTICE
218 #ifndef LOGGING_EXCLUDE_INFO
230 #ifndef LOGGING_EXCLUDE_FATAL // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
232 #ifndef LOGGING_EXCLUDE_ERROR // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
234 #ifndef LOGGING_EXCLUDE_WARNING // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
236 #ifndef LOGGING_EXCLUDE_NOTICE // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
238 #ifndef LOGGING_EXCLUDE_INFO // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
240 #ifndef LOGGING_EXCLUDE_DEBUG // A waste of time to change any level below this if it is going to disabled by compile-time checking anyway...
252 #ifndef LOGGING_EXCLUDE_FATAL
253 #ifndef LOGGING_EXCLUDE_ERROR
254 #ifndef LOGGING_EXCLUDE_WARNING
255 #ifndef LOGGING_EXCLUDE_NOTICE
256 #ifndef LOGGING_EXCLUDE_INFO
257 #ifndef LOGGING_EXCLUDE_DEBUG
Helper struct representing the Notice log level to allow us to specialize functions according to thei...
static bool mLoggingIncludesWarning
static bool storing whether the Warning level is to be included in the log output
static const bool mFalse
Define a static const member variable to have a value of false so that we can safely return a const r...
Helper struct representing the Fatal log level to allow us to specialize functions according to their...
static bool mLoggingIncludesNotice
static bool storing whether the Notice level is to be included in the log output
void setLogLevelTo(const FatalLevel &)
Function to specify, at runtime, that only messages with a severity level above Fatal should be logge...
static boost::mutex mMutex
Define a static Mutex lock for thread safe logging.
static bool mLoggingIncludesError
static bool storing whether the Error level is to be included in the log output
void log(FatalLevel &aFatal, const T0 &aArg0)
Function to add a log entry at Fatal level.
const bool & LoggingIncludes(const FatalLevel &)
Function to check at runtime whether the level Fatal is to be included in the log output.
void disableLogging()
Function to disable all logging levels.
_Quote< T > Quote(const T &aT)
static bool mLoggingIncludesInfo
static bool storing whether the Info level is to be included in the log output
Helper struct representing the Warning log level to allow us to specialize functions according to the...
Helper struct representing the Info log level to allow us to specialize functions according to their ...
boost::mutex & GetLoggingMutex()
Function to retrieve the mutex lock used by the logger.
static bool mLoggingIncludesDebug
static bool storing whether the Debug level is to be included in the log output
static bool mLoggingIncludesFatal
static bool storing whether the Fatal level is to be included in the log output
Helper struct representing the Debug log level to allow us to specialize functions according to their...
static const bool mTrue
Define a static const member variable to have a value of true so that we can safely return a const re...
void setLogLevelFromEnvironment(const char *aEnvVar)
Function to specify that the logging level should be retrieved from an environment variable.
Helper struct representing the Error log level to allow us to specialize functions according to their...