Class MemoryLoggingInterface
Defined in File memory.h
Inheritance Relationships
Base Type
public rclcpp::node_interfaces::NodeLoggingInterface
Class Documentation
-
class MemoryLoggingInterface : public rclcpp::node_interfaces::NodeLoggingInterface
Log helper redirecting storing logged messages in memory.
Public Functions
-
explicit MemoryLoggingInterface(const std::string &name = "log", RCUTILS_LOG_SEVERITY severity = RCUTILS_LOG_SEVERITY_DEBUG)
-
~MemoryLoggingInterface() override
-
rclcpp::Logger get_logger() const override
-
const char *get_logger_name() const override
-
virtual void addLogMessage(const rcl_interfaces::msg::Log &msg)
-
virtual const ::std::list<::rcl_interfaces::msg::Log> &getMessages() const
Return all messages logged so far.
- Returns:
The messages.
-
void clear()
Delete all messages logged so far.
Protected Attributes
-
::std::list<::rcl_interfaces::msg::Log> messages
The list of logged messages.
-
::std::string name
-
::RCUTILS_LOG_SEVERITY prevLogLevel = {RCUTILS_LOG_SEVERITY_UNSET}
-
::rcutils_logging_output_handler_t prevHandler = {nullptr}
-
::cras::MemoryLoggingInterface *prevLoggingInterface = {nullptr}
-
explicit MemoryLoggingInterface(const std::string &name = "log", RCUTILS_LOG_SEVERITY severity = RCUTILS_LOG_SEVERITY_DEBUG)