Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ extern "C"

typedef struct rosidl_action_type_support_t rosidl_action_type_support_t;

/// Contains rosidl action type support data. Actions are build based on services
/// (goal, result and cancel) and message (feedback and status).
struct rosidl_action_type_support_t
{
const rosidl_service_type_support_t * goal_service_type_support;
Expand All @@ -36,6 +38,12 @@ struct rosidl_action_type_support_t
const rosidl_message_type_support_t * status_message_type_support;
};

/// Macro to get the action type support.
/*
* \param PkgName name of the package that contains the action
* \param Name action name
* \return a rosidl_action_type_support_t struct if founded, otherwise NULL.
*/
#define ROSIDL_GET_ACTION_TYPE_SUPPORT(PkgName, Name) \
ROSIDL_TYPESUPPORT_INTERFACE__ACTION_SYMBOL_NAME( \
rosidl_typesupport_c, PkgName, action, Name)()
Expand Down
29 changes: 29 additions & 0 deletions rosidl_runtime_c/include/rosidl_runtime_c/message_bounds_struct.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,50 @@ typedef struct rosidl_message_bounds_t rosidl_message_bounds_t;
typedef const rosidl_message_bounds_t * (* rosidl_message_bounds_handle_function)(
const rosidl_message_bounds_t *, const char *);

/// Contains rosidl message bounds data
struct rosidl_message_bounds_t
{
/// String identifier for the type_support.
const char * typesupport_identifier;
/// pointer to type support handle function
const void * data;
/// pointer to type support handle function.
rosidl_message_bounds_handle_function func;
};

/// Get the message bounds handle specific to this identifier.
/**
* If the identifier is the same as this handle's identifier, then the handle is
* simply returned, otherwise it returns zero.
*
* \param handle Handle to service type support
* \param identifier The identifier to get the handle for
* \return The associated message bounds handle if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_message_bounds_t * get_message_bounds_handle(
const rosidl_message_bounds_t * handle, const char * identifier);

/// Get the message bounds handle function specific to this identifier.
/**
* If the identifier is the same as this handle funtion's identifier, then the handle is
* simply returned, otherwise it returns zero.
*
* \param handle Handle to service type support
* \param identifier The identifier to get the handle function for
* \return The associated message bounds handle function if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_message_bounds_t * get_message_bounds_handle_function(
const rosidl_message_bounds_t * handle, const char * identifier);

/// Macro to get the message bounds.
/*
* \param PkgName Name of the package that contains the message
* \param MsgSubfolder name of the subfolder (foe example: msg)
* \param MsgName message name
* \return a rosidl_message_bounds_t struct if founded, otherwise NULL.
*/
#define ROSIDL_GET_MSG_BOUNDS(PkgName, MsgSubfolder, MsgName) \
ROSIDL_BOUNDS_INTERFACE__MESSAGE_SYMBOL_NAME( \
rosidl_typesupport_c, PkgName, MsgSubfolder, MsgName)()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,50 @@ typedef struct rosidl_message_type_support_t rosidl_message_type_support_t;
typedef const rosidl_message_type_support_t * (* rosidl_message_typesupport_handle_function)(
const rosidl_message_type_support_t *, const char *);

/// Contains rosidl message type support data
struct rosidl_message_type_support_t
{
/// String identifier for the type_support.
const char * typesupport_identifier;
/// pointer to type support handle function
const void * data;
/// pointer to type support handle function
rosidl_message_typesupport_handle_function func;
};

/// Get the message type support handle specific to this identifier.
/**
* If the identifier is the same as this handle's typesupport_identifier, then the handle is
* simply returned, otherwise it returns zero.
*
* \param handle Handle to message type support
* \param identifier The typesupport identifier to get the handle function for
* \return The associated message typesupport handle if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_message_type_support_t * get_message_typesupport_handle(
const rosidl_message_type_support_t * handle, const char * identifier);

// Get the message type support handle function specific to this identifier.
/**
* If the identifier is the same as this handle's typesupport_identifier, then the handle is
* simply returned, otherwise it returns NULL.
*
* \param handle Handle to message type support
* \param identifier The typesupport identifier to get the handle function for
* \return The associated message typesupport handle if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_message_type_support_t * get_message_typesupport_handle_function(
const rosidl_message_type_support_t * handle, const char * identifier);

/// Macro to get the message typesupport
/*
* \param PkgName Name of the package that contains the message
* \param MsgSubfolder name of the subfolder (foe example: msg)
* \param MsgName message name
* \return a rosidl_message_type_support_t struct if founded, otherwise NULL.
*/
#define ROSIDL_GET_MSG_TYPE_SUPPORT(PkgName, MsgSubfolder, MsgName) \
ROSIDL_TYPESUPPORT_INTERFACE__MESSAGE_SYMBOL_NAME( \
rosidl_typesupport_c, PkgName, MsgSubfolder, MsgName)()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,50 @@ typedef struct rosidl_service_type_support_t rosidl_service_type_support_t;
typedef const rosidl_service_type_support_t * (* rosidl_service_typesupport_handle_function)(
const rosidl_service_type_support_t *, const char *);

/// Contains rosidl service type support data
struct rosidl_service_type_support_t
{
/// String identifier for the type_support.
const char * typesupport_identifier;
/// pointer to type support handle function
const void * data;
/// pointer to type support handle function
rosidl_service_typesupport_handle_function func;
};

/// Get the service type support handle specific to this identifier.
/**
* If the identifier is the same as this handle's typesupport_identifier, then the handle is
* simply returned, otherwise it returns zero.
*
* \param handle Handle to service type support
* \param identifier The typesupport identifier to get the handle function for
* \return The associated message typesupport handle if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_service_type_support_t * get_service_typesupport_handle(
const rosidl_service_type_support_t * handle, const char * identifier);

/// Get the service type support handle function specific to this identifier.
/**
* If the identifier is the same as this handle's typesupport_identifier, then the handle is
* simply returned, otherwise it returns zero.
*
* \param handle Handle to service type support
* \param identifier The typesupport identifier to get the handle function for
* \return The associated message typesupport handle if found, otherwise NULL
*/
ROSIDL_GENERATOR_C_PUBLIC
const rosidl_service_type_support_t * get_service_typesupport_handle_function(
const rosidl_service_type_support_t * handle, const char * identifier);

/// Macro to get the service typesupport
/*
* \param PkgName Name of the package that contains the service
* \param SrvSubfolder name of the subfolder (for example: srv)
* \param SrvName service name
* \return a rosidl_service_type_support_t struct if founded, otherwise NULL.
*/
#define ROSIDL_GET_SRV_TYPE_SUPPORT(PkgName, SrvSubfolder, SrvName) \
ROSIDL_TYPESUPPORT_INTERFACE__SERVICE_SYMBOL_NAME( \
rosidl_typesupport_c, PkgName, SrvSubfolder, SrvName)()
Expand Down