MachineIntelligenceCore:Toolchain
|
Abstract interface for different logger outputs. More...
#include <LoggerOutput.hpp>
Public Member Functions | |
LoggerOutput (Severity_t sev=LINFO) | |
virtual | ~LoggerOutput () |
virtual void | print (const std::string &msg_, Severity_t severity_, const std::string &file_, int line_) const =0 |
Logs given message. Depending on actual implementation, it can be printed on terminal, ncurses window, file etc. More... | |
void | setLvl (Severity_t sev) |
void | incrementLvl () |
void | decrementLvl () |
Severity_t | getLvl () const |
Protected Attributes | |
Severity_t | lvl |
Abstract interface for different logger outputs.
Definition at line 36 of file LoggerOutput.hpp.
|
inline |
Constructor. Sets default severity level (LINFO as default).
sev | Default output severity level. |
Definition at line 42 of file LoggerOutput.hpp.
|
inlinevirtual |
Virtual destructor. Empty.
Definition at line 50 of file LoggerOutput.hpp.
|
inline |
Decrements severity level.
Definition at line 83 of file LoggerOutput.hpp.
Referenced by mic::logger::Logger::decrementSeverityLevel().
|
inline |
Returns severity level.
Definition at line 93 of file LoggerOutput.hpp.
References lvl.
Referenced by mic::logger::Logger::log().
|
inline |
Increments severity level.
Definition at line 75 of file LoggerOutput.hpp.
Referenced by mic::logger::Logger::incrementSeverityLevel().
|
pure virtual |
Logs given message. Depending on actual implementation, it can be printed on terminal, ncurses window, file etc.
msg_ | Message to log |
severity_ | Severity of message |
file_ | Name of file, from which log was called |
line_ | Number of line, from which log was called |
Implemented in mic::logger::ConsoleOutput.
Referenced by mic::logger::Logger::log().
|
inline |
Sets severity level.
sev | Severity level. |
Definition at line 68 of file LoggerOutput.hpp.
References lvl.
Referenced by main(), and mic::logger::Logger::setSeverityLevel().
|
protected |
Logger severity - messages below this level will not be printed.
Definition at line 101 of file LoggerOutput.hpp.
Referenced by decrementLvl(), getLvl(), incrementLvl(), and setLvl().