1 #ifndef ORG_EEROS_LOGGER_LOGGER_HPP_
2 #define ORG_EEROS_LOGGER_LOGGER_HPP_
9 template <
typename TWriter >
12 Logger(
unsigned category = 0) : w(defaultWriter), category(category) { }
14 void set(TWriter* writer) { w = writer; }
15 void set(TWriter& writer) { w = &writer; }
16 TWriter*
get() {
return w; }
32 static TWriter* defaultWriter;
35 template <
typename TWriter >
36 TWriter* Logger<TWriter>::defaultWriter =
nullptr;
Definition: Logger.hpp:10
Logger(unsigned category=0)
Definition: Logger.hpp:12
LogEntry< TWriter > error()
Definition: Logger.hpp:19
LogEntry< TWriter > trace()
Definition: Logger.hpp:22
Definition: LogEntry.hpp:7
static void setDefaultWriter(TWriter *writer)
Definition: Logger.hpp:27
LogEntry< TWriter > operator<<(unsigned level)
Definition: Logger.hpp:24
LogEntry< TWriter > warn()
Definition: Logger.hpp:20
void set(TWriter *writer)
Definition: Logger.hpp:14
LogEntry< TWriter > info()
Definition: Logger.hpp:21
void set(TWriter &writer)
Definition: Logger.hpp:15
LogEntry< TWriter > fatal()
Definition: Logger.hpp:18