Viam C++ SDK current
|
Classes | |
class | viam::sdk::LogManager |
Manages the logging infrastructure in the SDDK. More... | |
Macros | |
#define | VIAM_SDK_LOG(level) VIAM_SDK_LOG_IMPL(::viam::sdk::LogManager::get().global_logger(), level) |
Log macro for general SDK logs. | |
#define | VIAM_RESOURCE_LOG(level) VIAM_SDK_LOG_IMPL(this->logger_, level) |
Log macro for resource-level logs. | |
Typedefs | |
using | viam::sdk::LogSource = boost::log::sources::severity_channel_logger_mt<log_level> |
Type alias for the log source in the C++ SDK. | |
Enumerations | |
enum class | viam::sdk::log_level : std::int8_t { trace = -2 , debug = -1 , info = 0 , warn = 1 , error = 2 , fatal = 3 } |
Severity levels for the logger. More... | |
Functions | |
const char * | viam::sdk::global_resource_name () |
Returns the "channel name" of general log messages not originating from resources. | |
#define VIAM_RESOURCE_LOG | ( | level | ) | VIAM_SDK_LOG_IMPL(this->logger_, level) |
Log macro for resource-level logs.
This macro can only be called from the definition of a member function of a class inheriting Resource. It will log messages to the log source of that specific resource, allowing resource-level log filtering.
#define VIAM_SDK_LOG | ( | level | ) | VIAM_SDK_LOG_IMPL(::viam::sdk::LogManager::get().global_logger(), level) |
Log macro for general SDK logs.
Use this macro to generate log messages pertaining to the SDK at large.
using viam::sdk::LogSource = boost::log::sources::severity_channel_logger_mt<log_level> |
Type alias for the log source in the C++ SDK.
In the paradigm of Boost.Log the C++ SDK has precisely one logging source, namely the source of messages generated by the user invoking one of the logging macros.
|
strong |
Severity levels for the logger.
VIAM_SDK_LOG(info)
instead of VIAM_SDK_LOG(k_info)
.