Class log_interface

Inheritance Relationships

Derived Type

Class Documentation

class stream_client::log_interface

Logger interface used by the library.

Subclassed by stream_client::base_logger

Public Functions

virtual ~log_interface() = default

Destructor.

virtual void set_level(log_level level) noexcept = 0

Set logger level.

Parameters

[in] level – Level to setup.

virtual log_level get_level() const noexcept = 0

Get logger level.

Returns

Actual logger level.

virtual void message(log_level level, const std::string &location, const std::string &message) const = 0

Log message produced from location with level.

Note

Thread-safe.

Parameters
  • [in] level – Level of the message.

  • [in] location – Location of the message. Used to filter messages from different parts of the library.

  • [in] message – The body of the message.