fawkes::CacheLogger Class Reference
Logging Cache. More...
#include <utils/logging/cache.h>

Classes | |
| struct | CacheEntry |
| Cache entry struct. More... | |
Public Member Functions | |
| CacheLogger (unsigned int num_entries=20, LogLevel log_level=LL_DEBUG) | |
| Constructor. | |
| virtual | ~CacheLogger () |
| Destructor. | |
| virtual void | log_debug (const char *component, const char *format,...) |
| Log debug message. | |
| virtual void | log_info (const char *component, const char *format,...) |
| Log informational message. | |
| virtual void | log_warn (const char *component, const char *format,...) |
| Log warning message. | |
| virtual void | log_error (const char *component, const char *format,...) |
| Log error message. | |
| virtual void | vlog_debug (const char *component, const char *format, va_list va) |
| Log debug message. | |
| virtual void | vlog_info (const char *component, const char *format, va_list va) |
| Log informational message. | |
| virtual void | vlog_warn (const char *component, const char *format, va_list va) |
| Log warning message. | |
| virtual void | vlog_error (const char *component, const char *format, va_list va) |
| Log error message. | |
| virtual void | log_debug (const char *component, Exception &e) |
| Log debug exception. | |
| virtual void | log_info (const char *component, Exception &e) |
| Log informational exception. | |
| virtual void | log_warn (const char *component, Exception &e) |
| Log warning exception. | |
| virtual void | log_error (const char *component, Exception &e) |
| Log error exception. | |
| virtual void | tlog_debug (struct timeval *t, const char *component, const char *format,...) |
| Log debug message for specific time. | |
| virtual void | tlog_info (struct timeval *t, const char *component, const char *format,...) |
| Log informational message for specific time. | |
| virtual void | tlog_warn (struct timeval *t, const char *component, const char *format,...) |
| Log warning message for specific time. | |
| virtual void | tlog_error (struct timeval *t, const char *component, const char *format,...) |
| Log error message for specific time. | |
| virtual void | tlog_debug (struct timeval *t, const char *component, Exception &e) |
| Log debug exception for specific time. | |
| virtual void | tlog_info (struct timeval *t, const char *component, Exception &e) |
| Log informational exception for specific time. | |
| virtual void | tlog_warn (struct timeval *t, const char *component, Exception &e) |
| Log warning exception for specific time. | |
| virtual void | tlog_error (struct timeval *t, const char *component, Exception &e) |
| Log error exception for specific time. | |
| virtual void | vtlog_debug (struct timeval *t, const char *component, const char *format, va_list va) |
| Log debug message for specific time. | |
| virtual void | vtlog_info (struct timeval *t, const char *component, const char *format, va_list va) |
| Log informational message for specific time. | |
| virtual void | vtlog_warn (struct timeval *t, const char *component, const char *format, va_list va) |
| Log warning message for specific time. | |
| virtual void | vtlog_error (struct timeval *t, const char *component, const char *format, va_list va) |
| Log error message for specific time. | |
| std::list< CacheEntry > & | get_messages () |
| Get messages. | |
| void | clear () |
| Clear messages. | |
Detailed Description
Logging Cache.The CacheLogger will cache the log messages. By default these are 20 messages.
Definition at line 40 of file cache.h.
Constructor & Destructor Documentation
| fawkes::CacheLogger::CacheLogger | ( | unsigned int | num_entries = 20, |
|
| LogLevel | log_level = LL_DEBUG | |||
| ) |
| fawkes::CacheLogger::~CacheLogger | ( | ) | [virtual] |
Member Function Documentation
| void fawkes::CacheLogger::clear | ( | void | ) |
Clear messages.
Definition at line 76 of file cache.cpp.
References fawkes::Mutex::lock(), and fawkes::Mutex::unlock().
Referenced by WebviewThread::init().
| std::list< CacheLogger::CacheEntry > & fawkes::CacheLogger::get_messages | ( | ) |
Get messages.
- Returns:
- reference to message list
Definition at line 70 of file cache.cpp.
Referenced by WebStartPageRequestProcessor::process_request().
| void fawkes::CacheLogger::log_debug | ( | const char * | component, | |
| Exception & | e | |||
| ) | [virtual] |
Log debug exception.
- Parameters:
-
component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 207 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::log_debug | ( | const char * | component, | |
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log debug message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 171 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::log_error | ( | const char * | component, | |
| Exception & | e | |||
| ) | [virtual] |
Log error exception.
- Parameters:
-
component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 225 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::log_error | ( | const char * | component, | |
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log error message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 198 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::log_info | ( | const char * | component, | |
| Exception & | e | |||
| ) | [virtual] |
Log informational exception.
- Parameters:
-
component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 213 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::log_info | ( | const char * | component, | |
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log informational message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 180 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::log_warn | ( | const char * | component, | |
| Exception & | e | |||
| ) | [virtual] |
Log warning exception.
- Parameters:
-
component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 219 of file cache.cpp.
References fawkes::Logger::LL_WARN.
| void fawkes::CacheLogger::log_warn | ( | const char * | component, | |
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log warning message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 189 of file cache.cpp.
References fawkes::Logger::LL_WARN.
| void fawkes::CacheLogger::tlog_debug | ( | struct timeval * | t, | |
| const char * | component, | |||
| Exception & | e | |||
| ) | [virtual] |
Log debug exception for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 326 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::tlog_debug | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log debug message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 290 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::tlog_error | ( | struct timeval * | t, | |
| const char * | component, | |||
| Exception & | e | |||
| ) | [virtual] |
Log error exception for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 344 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::tlog_error | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log error message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 317 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::tlog_info | ( | struct timeval * | t, | |
| const char * | component, | |||
| Exception & | e | |||
| ) | [virtual] |
Log informational exception for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 332 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::tlog_info | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log informational message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 299 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::tlog_warn | ( | struct timeval * | t, | |
| const char * | component, | |||
| Exception & | e | |||
| ) | [virtual] |
Log warning exception for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages e exception to log, exception messages will be logged
Implements fawkes::Logger.
Definition at line 338 of file cache.cpp.
References fawkes::Logger::LL_WARN.
| void fawkes::CacheLogger::tlog_warn | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| ... | ||||
| ) | [virtual] |
Log warning message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens.
Implements fawkes::Logger.
Definition at line 308 of file cache.cpp.
References fawkes::Logger::LL_WARN.
| void fawkes::CacheLogger::vlog_debug | ( | const char * | component, | |
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log debug message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 147 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::vlog_error | ( | const char * | component, | |
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log error message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 165 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::vlog_info | ( | const char * | component, | |
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log informational message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 153 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::vlog_warn | ( | const char * | component, | |
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log warning message.
- Parameters:
-
component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 159 of file cache.cpp.
References fawkes::Logger::LL_WARN.
| void fawkes::CacheLogger::vtlog_debug | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log debug message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 350 of file cache.cpp.
References fawkes::Logger::LL_DEBUG.
| void fawkes::CacheLogger::vtlog_error | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log error message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 368 of file cache.cpp.
References fawkes::Logger::LL_ERROR.
| void fawkes::CacheLogger::vtlog_info | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log informational message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 356 of file cache.cpp.
References fawkes::Logger::LL_INFO.
| void fawkes::CacheLogger::vtlog_warn | ( | struct timeval * | t, | |
| const char * | component, | |||
| const char * | format, | |||
| va_list | va | |||
| ) | [virtual] |
Log warning message for specific time.
- Parameters:
-
t time for this message to log component component, used to distuinguish logged messages format format of the message, see man page of sprintf for available tokens. va variable argument list
Implements fawkes::Logger.
Definition at line 362 of file cache.cpp.
References fawkes::Logger::LL_WARN.
The documentation for this class was generated from the following files:

