Base class for all log sinks. More...
#include <log_sink.hpp>
Inherited by matador::basic_file_sink, and matador::rotating_file_sink.
Public Member Functions | |
virtual | ~log_sink ()=default |
virtual void | write (const char *message, std::size_t size)=0 |
virtual void | close ()=0 |
Base class for all log sinks.
This class must be the base class for all log sinks and provides their interface
The main interface is the write(...) interface defining how the log message is written.
The close() interface defines a way to close the concrete log sink
|
virtualdefault |
Destroys the log sink
|
pure virtual |
Closes the log sink if necessary.
Implemented in matador::basic_file_sink, matador::stdout_sink, matador::stderr_sink, and matador::rotating_file_sink.
|
pure virtual |
Writes the given log message with the given size to the concrete sink
message | The message to log |
size | The size of the message |