Class JsonLogger#

Class Documentation#

class JsonLogger#

Base class for json loggers. Json log information will come in on the log functions, and derived classes can do whatever they want with it.

Public Functions

JsonLogger(std::string_view name)#

Contstructor.

Parameters:

name – The name of the logger.

virtual ~JsonLogger()#

Destructor.

virtual void log(const nlohmann::ordered_json &json, MsgLogger::LogLevel verbosity) = 0#

Log information from an ordered_json object.

Parameters:
  • json – The ordered_json log information.

  • verbosity – The verbosity of the log message.

virtual void log(const nlohmann::json &json, MsgLogger::LogLevel verbosity) = 0#

Log information from a json object.

Parameters:
  • json – The json log information.

  • verbosity – The verbosity of the log message.

Public Members

MsgLogger::LogLevel verbosity#

Verbosity of the logger.