Function rosidl_runtime_c_type_description_utils_append_referenced_individual_type_description

Function Documentation

rcutils_ret_t rosidl_runtime_c_type_description_utils_append_referenced_individual_type_description(rosidl_runtime_c__type_description__TypeDescription *type_description, rosidl_runtime_c__type_description__IndividualTypeDescription *referenced_type_description, bool sort)

Append a referenced IndividualTypeDescription to a TypeDescription, extending it.

Ownership:

  • A deep-copy of the referenced_type_description is appended to type_description on success, the type_description is then responsible for freeing the copied referenced_type_description.

  • The ownership of the input referenced_type_description is not transferred, it must still be freed.

Attribute

Adherence

Allocates Memory

Yes

Thread-Safe

No

Uses Atomics

No

Lock-Free

Yes

Parameters:
  • type_description[inout] the type description to append to, noop on failure

  • individual_type_description[inout] the individual type description to append

  • sort[in] sorts the referenced type descriptions if true, best effort

Returns:

#RCUTILS_RET_OK if successful, or

Returns:

#RCUTILS_RET_BAD_ALLOC if memory allocation fails, or

Returns:

#RCUTILS_RET_INVALID_ARGUMENT for invalid arguments, or

Returns:

#RCUTILS_RET_ERROR if an unknown error occurs.