24 #ifndef __UTILS_LOGGING_CACHE_H_ 25 #define __UTILS_LOGGING_CACHE_H_ 27 #include <logging/logger.h> 46 virtual void log_debug(
const char *component,
const char *format, ...);
47 virtual void log_info(
const char *component,
const char *format, ...);
48 virtual void log_warn(
const char *component,
const char *format, ...);
49 virtual void log_error(
const char *component,
const char *format, ...);
51 virtual void vlog_debug(
const char *component,
const char *format, va_list va);
52 virtual void vlog_info(
const char *component,
const char *format, va_list va);
53 virtual void vlog_warn(
const char *component,
const char *format, va_list va);
54 virtual void vlog_error(
const char *component,
const char *format, va_list va);
56 virtual void log_debug(
const char *component,
Exception &e);
57 virtual void log_info(
const char *component,
Exception &e);
58 virtual void log_warn(
const char *component,
Exception &e);
59 virtual void log_error(
const char *component,
Exception &e);
61 virtual void tlog_debug(
struct timeval *t,
const char *component,
const char *format, ...);
62 virtual void tlog_info(
struct timeval *t,
const char *component,
const char *format, ...);
63 virtual void tlog_warn(
struct timeval *t,
const char *component,
const char *format, ...);
64 virtual void tlog_error(
struct timeval *t,
const char *component,
const char *format, ...);
66 virtual void tlog_debug(
struct timeval *t,
const char *component,
Exception &e);
67 virtual void tlog_info(
struct timeval *t,
const char *component,
Exception &e);
68 virtual void tlog_warn(
struct timeval *t,
const char *component,
Exception &e);
69 virtual void tlog_error(
struct timeval *t,
const char *component,
Exception &e);
71 virtual void vtlog_debug(
struct timeval *t,
const char *component,
72 const char *format, va_list va);
73 virtual void vtlog_info(
struct timeval *t,
const char *component,
74 const char *format, va_list va);
75 virtual void vtlog_warn(
struct timeval *t,
const char *component,
76 const char *format, va_list va);
77 virtual void vtlog_error(
struct timeval *t,
const char *component,
78 const char *format, va_list va);
92 std::list<CacheEntry> & get_messages();
97 unsigned int size()
const;
98 void set_size(
unsigned int new_size);
104 void push_message(
LogLevel ll,
const char *component,
const char *format,
107 void tlog_push_message(
LogLevel ll,
struct timeval *t,
const char *component,
108 const char *format, va_list va);
109 void tlog_push_message(
LogLevel ll,
struct timeval *t,
const char *component,
117 std::list<CacheEntry> __messages;
118 unsigned int __num_entries;
119 unsigned int __max_num_entries;
Fawkes library namespace.
std::string timestr
Time encoded as string.
LogLevel log_level
log level
Base class for exceptions in Fawkes.
std::string message
Message.
std::string component
component
Mutex mutual exclusion lock.