RTI Cloud Discovery Service Version 7.3.0
rti::cds::Logger Class Reference

The singleton type used to configure RTI Cloud Discovery Service verbosity. More...

#include <Logger.hpp>

Public Member Functions

void service_verbosity (rti::config::Verbosity verbosity)
 Sets the verbosity for the log messages generated at the RTI Cloud Discovery Service level. More...
 
rti::config::Verbosity service_verbosity ()
 Getter for the same attribute. More...
 
void error (const std::string &msg)
 Logs a message with EXCEPTION level. More...
 
void error (const char *msg)
 Overload of error(const std::string& msg) More...
 
void warn (const std::string &msg)
 Logs as message with WARNING level. More...
 
void warn (const char *msg)
 Overload of warn(const std::string& msg) More...
 
void local (const std::string &msg)
 Logs as message with WARNING level. More...
 
void local (const char *msg)
 Overload of local(const std::string& msg) More...
 
void remote (const std::string &msg)
 Logs a message with WARNING level. More...
 
void remote (const char *msg)
 Overload of remote(const std::string& msg) More...
 
void debug (const std::string &msg)
 Logs as message with WARNING level. More...
 
void debug (const char *msg)
 Overload of debug(const std::string& msg) More...
 

Detailed Description

The singleton type used to configure RTI Cloud Discovery Service verbosity.

For configuring other aspects such as output file, print format or RTI Connext specific logging, use rti::config::Logger.

Member Function Documentation

◆ service_verbosity() [1/2]

void rti::cds::Logger::service_verbosity ( rti::config::Verbosity  verbosity)
inline

Sets the verbosity for the log messages generated at the RTI Cloud Discovery Service level.

Parameters
verbosity<<in>> The verbosity of the service logs

◆ service_verbosity() [2/2]

rti::config::Verbosity rti::cds::Logger::service_verbosity ( )
inline

Getter for the same attribute.

See also
service_verbosity(rti::config::Verbosity)

◆ error() [1/2]

void rti::cds::Logger::error ( const std::string &  msg)
inline

Logs a message with EXCEPTION level.

The generated log will be part of logging stream of the running service if the service verbosity contains EXCEPTION messages. The result log message may include additional information according to the Connext logging configuration, such as Advlog Context, thread ID, line number, etc. Additionally, the result log message will contain a newline character at the end, so the format does not need to contain it.

Parameters
[in]msgMessage to be logged

References error().

Referenced by error().

◆ error() [2/2]

void rti::cds::Logger::error ( const char *  msg)
inline

◆ warn() [1/2]

void rti::cds::Logger::warn ( const std::string &  msg)
inline

Logs as message with WARNING level.

This operation behaves similar to error() except the log level is WARNING.

Parameters
[in]msgMessage to be logged
See also
rti::cds::Logger::error

References warn().

Referenced by rti::cds::Service::finalize_globals(), and warn().

◆ warn() [2/2]

void rti::cds::Logger::warn ( const char *  msg)
inline

◆ local() [1/2]

void rti::cds::Logger::local ( const std::string &  msg)
inline

Logs as message with WARNING level.

This operation behaves similar to error() except the log level is STATUS_LOCAL.

Parameters
[in]msgMessage to be logged
See also
rti::cds::Logger::error

References local().

Referenced by local().

◆ local() [2/2]

void rti::cds::Logger::local ( const char *  msg)
inline

◆ remote() [1/2]

void rti::cds::Logger::remote ( const std::string &  msg)
inline

Logs a message with WARNING level.

This operation behaves similar to error() except the log level is STATUS_REMOTE.

Parameters
[in]msgMessage to be logged
See also
rti::cds::Logger::error

References remote().

Referenced by remote().

◆ remote() [2/2]

void rti::cds::Logger::remote ( const char *  msg)
inline

◆ debug() [1/2]

void rti::cds::Logger::debug ( const std::string &  msg)
inline

Logs as message with WARNING level.

This operation behaves similar to error() except the log level is STATUS_DEBUG.

Parameters
[in]msgMessage to be logged
See also
rti::cds::Logger::error

References debug().

Referenced by debug().

◆ debug() [2/2]

void rti::cds::Logger::debug ( const char *  msg)
inline