Set the type of an invocation.
BPS_API int navigator_invoke_invocation_set_type(navigator_invoke_invocation_t *invocation, const char *type)
A pointer to the navigator_invoke_invocation_t structure whose type member you want to set.
The MIME type of the data being sent to the invocation handler. The value must conform to the "Type Subtype" format (see description for further information).
The navigator_invoke_invocation_set_type() function sets the type member of a given navigator_invoke_invocation_t structure. The type member identifies the MIME type of the data the invoked handler is to perform an action on.
If you assign a type member to an invocation but don't assign a target (using the navigator_invoke_invocation_set_target() function), the brokering system uses the type value to filter for target handlers that support that MIME type. If an action member is also assigned (using the navigator_invoke_invocation_set_action() function), the brokering system uses that information to filter for handler(s) that support both the given type and action. If only an action member is assigned, the brokering system doesn't filter for any specific MIME type.
The format of a type member must conform to the following guidelines:
- MIME type: Type Subtype
- Type: [a-zA-Z0-9-_.]+
- Subtype: NUL | / Type Subtype
BPS_SUCCESS upon success, BPS_FAILURE with errno set otherwise.