presage 0.9.1
|
#include <logger.h>
Classes | |
class | LoggerState |
Public Types | |
enum | Level { EMERG = 0 , FATAL = 0 , ALERT = 100 , CRIT = 200 , ERROR = 300 , WARN = 400 , NOTICE = 500 , INFO = 600 , DEBUG = 700 , ALL = 800 } |
Public Member Functions | |
Logger (std::string logger_name, std::basic_ostream< _charT, _Traits > &ostr) | |
Logger (std::string logger_name, std::basic_ostream< _charT, _Traits > &ostr, const std::string &lvl) | |
void | init (const std::string &name, const std::string &lvl) |
~Logger () | |
void | setLevel (const std::string &lvl) const |
void | setLevel (Level lvl) const |
Level | getLevel () const |
void | setCurrentLevel (Level lvl) const |
Level | getCurrentLevel () const |
bool | shouldLog () const |
const Logger & | operator<< (_SetLevel __l) const |
void | endl () const |
Private Member Functions | |
void | set (Level &level, const std::string &lvl) const |
void | set_name (const std::string &logger_name) |
Private Attributes | |
std::string | name |
std::basic_ostream< _charT, _Traits > & | outstream |
LoggerState * | state |
Friends | |
template<typename T> | |
const Logger & | operator<< (const Logger &lgr, const T &msg) |
const Logger & | operator<< (const Logger &lgr, const Logger &(*fp)(const Logger &)) |
enum Logger::Level |
|
inline |
Definition at line 76 of file logger.h.
References init(), and outstream.
Referenced by operator<<(), operator<<, and operator<<.
|
inline |
|
inline |
|
inline |
Definition at line 184 of file logger.h.
References _SetLevel::_level, Logger(), and setLevel().
|
inlineprivate |
|
inline |
Definition at line 114 of file logger.h.
Referenced by operator<<().
|
inline |
Definition at line 149 of file logger.h.
References state.
Referenced by endl(), and operator<<.
|
friend |
Definition at line 157 of file logger.h.
References Logger< _charT, _Traits >::LoggerState::line_beginning, Logger(), name, outstream, shouldLog(), and state.
|
private |
Definition at line 239 of file logger.h.
Referenced by init(), operator<<, and set_name().
|
private |
|
private |
Definition at line 250 of file logger.h.
Referenced by endl(), getCurrentLevel(), getLevel(), init(), operator<<, setCurrentLevel(), setLevel(), setLevel(), shouldLog(), and ~Logger().