![]() |
KENSv3
KAIST Educational Network System
|
Log provides log-related utilities. We recommend you to inherit this class privately, and it will enable Log::print_log in your namespace. More...
#include <E_Log.hpp>
Public Types | |
enum | LOG_LEVEL { ERR , WARN , LOG , INFO , DEBUG , LEVEL_COUNT } |
Enumerations for log levels. | |
Public Member Functions | |
Log () | |
Constructs a Log instance. | |
Log (int level) | |
Constructs a Log instance with log level. More... | |
~Log () | |
Destructs a Log instance. | |
Static Public Attributes | |
static int | defaultLevel = Log::LOG_LEVEL |
Default log level. | |
Protected Member Functions | |
void | print_log (int level, const char *format,...) |
Prints log with specified log level and format. Log::print_log prints all logs that has lower log level than the specified log level. For example, when log level is set to LOG, it prints ERR, WARN, and LOG logs. More... | |
Log provides log-related utilities. We recommend you to inherit this class privately, and it will enable Log::print_log in your namespace.
|
protected |
Prints log with specified log level and format. Log::print_log prints all logs that has lower log level than the specified log level. For example, when log level is set to LOG, it prints ERR, WARN, and LOG logs.
level | Log level |
format | Format string |
... | Print arguments for format string |