Function rosidl_runtime_c_type_description_utils_create_individual_type_description

Function Documentation

rcutils_ret_t rosidl_runtime_c_type_description_utils_create_individual_type_description(const char *type_name, size_t type_name_length, rosidl_runtime_c__type_description__IndividualTypeDescription **individual_description)

Construct a new populated IndividualTypeDescription object, with fields sequence of size 0.

NOTE: The individual_description output arg must be passed in pointing to NULL.

Ownership:

  • The caller assumes ownership of the output IndividualTypeDescription and must free it and its members.

  • The char * members are copied.

Attribute

Adherence

Allocates Memory

Yes

Thread-Safe

No

Uses Atomics

No

Lock-Free

Yes

Parameters:
  • type_name[in] the name of the individual type description

  • type_name_length[in] the string length of type_name (not counting the null terminator)

  • individual_description[out] IndividualTypeDescription to be initialized. Must point to NULL, outputs pointing to NULL if error.

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.