Function dds_set_topic_filter_and_arg¶
Defined in File dds.h
Function Documentation¶
-
dds_return_t dds_set_topic_filter_and_arg(dds_entity_t topic, dds_topic_filter_arg_fn filter, void *arg)¶
Sets a filter and filter argument on a topic. To be replaced by proper filtering on readers, no guarantee that this will be maintained for backwards compatibility.
Not thread-safe with respect to data being read/written using readers/writers using this topic. Be sure to create a topic entity specific to the reader you want to filter, then set the filter function, and only then create the reader. And don’t change it unless you know there are no concurrent writes.
- Parameters
topic – [in] The topic on which the content filter is set.
filter – [in] The filter function used to filter topic samples.
arg – [in] Argument for the filter function.
- Return values
DDS_RETCODE_OK – Filter set successfully
DDS_RETCODE_BAD_PARAMETER – The topic handle is invalid
- Returns
A dds_return_t indicating success or failure.