Public Member Functions | |
FileAppender (Formatter *formatter, const std::string &name) | |
Construct the file appender. | |
virtual void | append (Logger::Level level, std::string msg, std::string category, LOG4SENDPP_INT64 stamp, const LocationInformation *loginfo, const Logger::DiagnosticInformation *diaginfo) |
Formats a message. | |
virtual void | writeString (const std::string &data) |
Appends a raw string to the current file. | |
virtual bool | isWorking () const |
Tests if the appender is correctly working. |
Definition at line 43 of file file_appender.h.
l4snd::FileAppender::FileAppender | ( | Formatter * | formatter, | |
const std::string & | name | |||
) |
Construct the file appender.
formatter | pointer to foratter | |
name | filename |
Definition at line 43 of file file_appender.cpp.
void l4snd::FileAppender::append | ( | Logger::Level | level, | |
std::string | msg, | |||
std::string | category, | |||
LOG4SENDPP_INT64 | stamp, | |||
const LocationInformation * | loginfo, | |||
const Logger::DiagnosticInformation * | diaginfo | |||
) | [virtual] |
Formats a message.
level | severty level | |
msg | string to log | |
category | message category | |
stamp | timestamp in milliseconds since 1.1.1970 | |
loginfo | pointer to location info or 0 | |
diaginfo | pointer to diagnostic info or 0 |
Implements l4snd::Appender.
Definition at line 51 of file file_appender.cpp.
References l4snd::Formatter::format(), l4snd::Appender::getFormatter(), and writeString().
void l4snd::FileAppender::writeString | ( | const std::string & | data | ) | [virtual] |
Appends a raw string to the current file.
data | string with data |
Implements l4snd::Appender.
Definition at line 72 of file file_appender.cpp.
Referenced by append().
bool l4snd::FileAppender::isWorking | ( | ) | const [virtual] |
Tests if the appender is correctly working.
Implements l4snd::Appender.
Definition at line 79 of file file_appender.cpp.