rcl
master
C API providing common ROS client library functionality.
|
Go to the documentation of this file.
17 #ifndef RCL__ARGUMENTS_H_
18 #define RCL__ARGUMENTS_H_
22 #include "rcl/macros.h"
24 #include "rcl/visibility_control.h"
25 #include "rcl_yaml_param_parser/types.h"
32 struct rcl_arguments_impl_t;
38 struct rcl_arguments_impl_t *
impl;
42 #define RCL_ROS_ARGS_FLAG "--ros-args"
45 #define RCL_ROS_ARGS_EXPLICIT_END_TOKEN "--"
48 #define RCL_PARAM_FLAG "--param"
51 #define RCL_SHORT_PARAM_FLAG "-p"
54 #define RCL_PARAM_FILE_FLAG "--params-file"
57 #define RCL_REMAP_FLAG "--remap"
60 #define RCL_SHORT_REMAP_FLAG "-r"
63 #define RCL_ENCLAVE_FLAG "--enclave"
66 #define RCL_SHORT_ENCLAVE_FLAG "-e"
69 #define RCL_LOG_LEVEL_FLAG "--log-level"
72 #define RCL_EXTERNAL_LOG_CONFIG_FLAG "--log-config-file"
76 #define RCL_LOG_STDOUT_FLAG_SUFFIX "stdout-logs"
80 #define RCL_LOG_ROSOUT_FLAG_SUFFIX "rosout-logs"
84 #define RCL_LOG_EXT_LIB_FLAG_SUFFIX "external-lib-logs"
154 const char *
const argv[],
209 int ** output_unparsed_indices);
261 int ** output_unparsed_ros_indices);
310 char *** parameter_files);
339 rcl_params_t ** parameter_overrides);
372 char const *
const argv[],
376 const char ** nonros_argv[]);
454 #endif // RCL__ARGUMENTS_H_
rcl_ret_t rcl_arguments_get_param_files(const rcl_arguments_t *arguments, rcl_allocator_t allocator, char ***parameter_files)
Return a list of yaml parameter file paths specified on the command line.
Definition: arguments.c:77
rcl_ret_t rcl_arguments_get_param_overrides(const rcl_arguments_t *arguments, rcl_params_t **parameter_overrides)
Return all parameter overrides parsed from the command line.
Definition: arguments.c:117
rmw_ret_t rcl_ret_t
The type that holds an rcl return code.
Definition: types.h:23
rcl_ret_t rcl_arguments_get_unparsed_ros(const rcl_arguments_t *args, rcl_allocator_t allocator, int **output_unparsed_ros_indices)
Return a list of indices to unknown ROS specific arguments that were left unparsed.
Definition: arguments.c:727
rcl_ret_t rcl_arguments_get_unparsed(const rcl_arguments_t *args, rcl_allocator_t allocator, int **output_unparsed_indices)
Return a list of indices to non ROS specific arguments.
Definition: arguments.c:692
int rcl_arguments_get_param_files_count(const rcl_arguments_t *args)
Return the number of parameter yaml files given in the arguments.
Definition: arguments.c:107
rcl_ret_t rcl_arguments_get_log_levels(const rcl_arguments_t *arguments, rcl_log_levels_t *log_levels)
Return log levels parsed from the command line.
Definition: arguments.c:140
struct rcl_arguments_impl_t * impl
Private implementation pointer.
Definition: arguments.h:38
int rcl_arguments_get_count_unparsed_ros(const rcl_arguments_t *args)
Return the number of ROS specific arguments that were not successfully parsed.
Definition: arguments.c:717
rcl_ret_t rcl_remove_ros_arguments(char const *const argv[], const rcl_arguments_t *args, rcl_allocator_t allocator, int *nonros_argc, const char **nonros_argv[])
Return a list of arguments with ROS-specific arguments removed.
Definition: arguments.c:761
Hold output of parsing command line arguments.
Definition: arguments.h:35
rcl_ret_t rcl_arguments_copy(const rcl_arguments_t *args, rcl_arguments_t *args_out)
Copy one arguments structure into another.
Definition: arguments.c:812
struct rcl_arguments_t rcl_arguments_t
Hold output of parsing command line arguments.
Hold default logger level and other logger setting.
Definition: log_level.h:43
int rcl_arguments_get_count_unparsed(const rcl_arguments_t *args)
Return the number of arguments that were not ROS specific arguments.
Definition: arguments.c:682
rcl_ret_t rcl_parse_arguments(int argc, const char *const argv[], rcl_allocator_t allocator, rcl_arguments_t *args_output)
Parse command line arguments into a structure usable by code.
Definition: arguments.c:248
rcl_ret_t rcl_arguments_fini(rcl_arguments_t *args)
Reclaim resources held inside rcl_arguments_t structure.
Definition: arguments.c:932
rcl_arguments_t rcl_get_zero_initialized_arguments(void)
Return a rcl_arguments_t struct with members initialized to NULL.
Definition: arguments.c:752