rcl
master
C API providing common ROS client library functionality.
|
Go to the source code of this file.
Functions | |
rcl_ret_t | rcl_logging_external_initialize (const char *config_file, rcutils_allocator_t allocator) |
Initialize the external logging library. More... | |
rcl_ret_t | rcl_logging_external_shutdown () |
Free the resources allocated for the external logging system. More... | |
void | rcl_logging_external_log (int severity, const char *name, const char *msg) |
Log a message. More... | |
rcl_ret_t | rcl_logging_external_set_logger_level (const char *name, int level) |
Set the severity level for a logger. More... | |
rcl_ret_t rcl_logging_external_initialize | ( | const char * | config_file, |
rcutils_allocator_t | allocator | ||
) |
Initialize the external logging library.
[in] | config_file | The location of a config file that the external logging library should use to configure itself. If no config file is provided this will be set to an empty string. Must be a NULL terminated c string. |
[in] | allocator | The allocator to use for memory allocation. This is an rcutils_allocator_t rather than an rcl_allocator_t to ensure that the rcl_logging_* packages don't have a circular dependency back to rcl. |
rcl_ret_t rcl_logging_external_shutdown | ( | ) |
Free the resources allocated for the external logging system.
This puts the system into a state equivalent to being uninitialized.
void rcl_logging_external_log | ( | int | severity, |
const char * | name, | ||
const char * | msg | ||
) |
Log a message.
[in] | severity | The severity level of the message being logged. |
[in] | name | The name of the logger, must either be a null terminated c string or NULL. If NULL or empty the root logger will be used. |
[in] | msg | The message to be logged. Must be a null terminated c string. |
rcl_ret_t rcl_logging_external_set_logger_level | ( | const char * | name, |
int | level | ||
) |
Set the severity level for a logger.
This function sets the severity level for the specified logger. If the name provided is an empty string or NULL it will change the level of the root logger.
[in] | name | The name of the logger. Must be a NULL terminated c string or NULL. |
[in] | level | The severity level to be used for the specified logger. |