Function dds_get_matched_subscriptions¶
Defined in File dds.h
Function Documentation¶
-
dds_return_t dds_get_matched_subscriptions(dds_entity_t writer, dds_instance_handle_t *rds, size_t nrds)¶
Get instance handles of the data readers matching a writer.
This operation fills the provided array with the instance handles of the data readers that match the writer. On successful output, the number of entries of “rds” set is the minimum of the return value and the value of “nrds”.
- Parameters
writer – [in] The writer.
rds – [in] The array to be filled.
nrds – [in] The size of the rds array, at most the first nrds entries will be filled. rds = NULL and nrds = 0 is a valid way of determining the number of matched readers, but inefficient compared to relying on the matched publication status.
- Return values
>=0 – The number of matching readers.
DDS_RETCODE_BAD_PARAMETER – The entity parameter is not valid or rds = NULL and nrds > 0.
DDS_RETCODE_ILLEGAL_OPERATION – The operation is invoked on an inappropriate object.
- Returns
A dds_return_t indicating the number of matched readers or failure. The return value may be larger than nrds if there are more matching readers than the array can hold.