#include <wvlogbuffer.h>
Inheritance diagram for WvLogBuffer:
It only keeps up to max_lines log entries for every source/debug level, s.t. debug level <= max_level
Public Member Functions | |
| DeclareWvList (Msg) | |
| DeclareWvDict (MsgCounter, WvString, src_lvl) | |
| WvLogBuffer (int _max_lines, WvLog::LogLevel _max_level=WvLog::NUM_LOGLEVELS) | |
| MsgList & | messages () |
| void | dump (WvStream &s) |
| void | end_line () |
| WvLog::LogLevel | level () const |
| void | level (WvLog::LogLevel lvl) |
| bool | set_custom_levels (WvString descr) |
Static Public Attributes | |
| static char * | loglevels [WvLog::NUM_LOGLEVELS] |
Protected Member Functions | |
| void | handle_msg (Msg *lastmsg) |
| virtual void | _begin_line () |
| Start a new log line (print prefix). | |
| virtual void | _mid_line (const char *str, size_t len) |
| add text to the current log line. | |
| virtual void | _end_line () |
| End this (Guaranteed NonEmpty) log line. | |
| DeclareWvScatterDict (Src_Lvl, WvString, src) | |
| virtual void | log (const WvLog *source, int loglevel, const char *_buf, size_t len) |
| virtual void | _make_prefix () |
| Set the Prefix and Prefix Length (size_t prelen). | |
Protected Attributes | |
| MsgList | msgs |
| MsgCounterDict | counters |
| WvDynBuf | current |
| int | max_lines |
| const WvLog * | last_source |
| WvLog::LogLevel | max_level |
| WvLog::LogLevel | last_level |
| bool | at_newline |
| WvString | prefix |
| size_t | prelen |
| Src_LvlDict | custom_levels |
Classes | |
| class | Msg |
| class | MsgCounter |
|
||||||||||||
|
add text to the current log line.
'str' may contain only one ' Implements WvLogRcv. |
|
|
Initial value: {
"Crit",
"Err",
"Warn",
"Notice",
"Info",
"*1",
"*2",
"*3",
"*4",
"*5",
}
|
1.4.2