ROS 2 rclcpp + rcl - kilted
kilted
ROS 2 C++ Client Library with ROS Client Library
|
Encapsulation of options for initializing rclcpp. More...
#include <rclcpp/init_options.hpp>
Public Member Functions | |
RCLCPP_PUBLIC | InitOptions (rcl_allocator_t allocator=rcl_get_default_allocator()) |
Constructor. More... | |
RCLCPP_PUBLIC | InitOptions (const rcl_init_options_t &init_options) |
Constructor which is initialized by an existing init_options. More... | |
RCLCPP_PUBLIC | InitOptions (const InitOptions &other) |
Copy constructor. | |
RCLCPP_PUBLIC bool | auto_initialize_logging () const |
Return true if logging should be initialized when rclcpp::Context::init is called. | |
RCLCPP_PUBLIC InitOptions & | auto_initialize_logging (bool initialize_logging) |
Set flag indicating if logging should be initialized or not. | |
RCLCPP_PUBLIC InitOptions & | operator= (const InitOptions &other) |
Assignment operator. | |
RCLCPP_PUBLIC const rcl_init_options_t * | get_rcl_init_options () const |
Return the rcl init options. More... | |
RCLCPP_PUBLIC void | use_default_domain_id () |
Retrieve default domain id and set. | |
RCLCPP_PUBLIC void | set_domain_id (size_t domain_id) |
Set the domain id. | |
RCLCPP_PUBLIC size_t | get_domain_id () const |
Return domain id. | |
Public Attributes | |
bool | shutdown_on_signal = true |
If true, the context will be shutdown on SIGINT by the signal handler (if it was installed). | |
Protected Member Functions | |
void | finalize_init_options () |
Encapsulation of options for initializing rclcpp.
Definition at line 28 of file init_options.hpp.
|
explicit |
Constructor.
It allows you to specify the allocator used within the init options.
[in] | allocator | used allocate memory within the init options |
anything | rclcpp::exceptions::throw_from_rcl_error can throw. |
Definition at line 23 of file init_options.cpp.
References rcl_get_zero_initialized_init_options(), rcl_init_options_init(), and RCL_RET_OK.
|
explicit |
Constructor which is initialized by an existing init_options.
Initialized by an existing init_options.
[in] | init_options | rcl_init_options_t to initialized |
anything | rclcpp::exceptions::throw_from_rcl_error can throw. |
Definition at line 33 of file init_options.cpp.
References rcl_get_zero_initialized_init_options(), rcl_init_options_copy(), and RCL_RET_OK.
const rcl_init_options_t * rclcpp::InitOptions::get_rcl_init_options | ( | ) | const |
Return the rcl init options.
anything | rclcpp::exceptions::throw_from_rcl_error can throw. |
Definition at line 107 of file init_options.cpp.
Referenced by rclcpp::Context::init(), and operator=().