Interface of the log destinations; derive from ASink to write a new sink.
Definition ISink.hpp:14
virtual void setLevel(LogLevel level) noexcept=0
Minimum level accepted by this sink.
virtual void write(const LogMessage &message)=0
Receives a message from a logger.
virtual LogLevel getLevel() const noexcept=0
virtual bool shouldLog(LogLevel level) const noexcept=0
virtual void setPattern(std::string_view pattern)=0
Formats the messages with pattern; see Formatter.
virtual void setFormatter(std::shared_ptr< Formatter > formatter)=0
Shares a Formatter between sinks.
Thread-safe logging: loggers, sinks, patterns and macros.
Definition Terminal.hpp:8
LogLevel
Severity of a message, from Trace to Fatal; Off disables logging.
Definition LogLevel.hpp:11
A log record as passed to the sinks.
Definition LogMessage.hpp:18