RTI Connext Traditional C++ API Version 7.2.0
DDSQueryCondition Class Referenceabstract

<<interface>> These are specialised DDSReadCondition objects that allow the application to also specify a filter on the locally available data. More...

Inheritance diagram for DDSQueryCondition:
DDSReadCondition DDSCondition

Public Member Functions

virtual const char * get_query_expression ()=0
 Retrieves the query expression. More...
 
virtual DDS_ReturnCode_t get_query_parameters (DDS_StringSeq &query_parameters)=0
 Retrieves the query parameters. More...
 
virtual DDS_ReturnCode_t set_query_parameters (const DDS_StringSeq &query_parameters)=0
 Sets the query parameters. More...
 
- Public Member Functions inherited from DDSReadCondition
virtual DDS_SampleStateMask get_sample_state_mask ()=0
 Retrieves the set of sample_states for the condition. More...
 
virtual DDS_ViewStateMask get_view_state_mask ()=0
 Retrieves the set of view_states for the condition. More...
 
virtual DDS_InstanceStateMask get_instance_state_mask ()=0
 Retrieves the set of instance_states for the condition. More...
 
virtual DDS_StreamKindMask get_stream_kind_mask ()=0
 Retrieves the set of instance_states for the condition. More...
 
virtual DDSDataReaderget_datareader ()=0
 Returns the DDSDataReader associated with the DDSReadCondition. More...
 
- Public Member Functions inherited from DDSCondition
virtual DDS_Boolean get_trigger_value ()=0
 Retrieve the trigger_value. More...
 
virtual DDS_ReturnCode_t set_handler (DDSConditionHandler *handler)
 <<extension>> Registers a DDSConditionHandler in this DDSCondition. More...
 
virtual DDSConditionHandlerget_handler ()
 <<extension>> Returns the registered DDSConditionHandler. More...
 
virtual void dispatch ()
 <<extension>> Calls DDSConditionHandler::on_condition_triggered of the registered DDSConditionHandler. More...
 

Detailed Description

<<interface>> These are specialised DDSReadCondition objects that allow the application to also specify a filter on the locally available data.

Each query condition filter is composed of a DDSReadCondition state filter and a content filter expressed as a query_expression and query_parameters.

The query (query_expression) is similar to an SQL WHERE clause and can be parameterised by arguments that are dynamically changeable by the set_query_parameters() operation.

Two query conditions that have the same query_expression will require unique query condition content filters if their query_paramters differ. Query conditions that differ only in their state masks will share the same query condition content filter.

Queries and Filters Syntax describes the syntax of query_expression and query_parameters.

Member Function Documentation

◆ get_query_expression()

virtual const char * DDSQueryCondition::get_query_expression ( )
pure virtual

Retrieves the query expression.

◆ get_query_parameters()

virtual DDS_ReturnCode_t DDSQueryCondition::get_query_parameters ( DDS_StringSeq query_parameters)
pure virtual

Retrieves the query parameters.

Parameters
query_parameters<<inout>> the query parameters are returned here. The memory for the strings in this sequence is managed according to the conventions described in String Conventions. In particular, be careful to avoid a situation in which RTI Connext allocates a string on your behalf and you then reuse that string in such a way that RTI Connext believes it to have more memory allocated to it than it actually does.

◆ set_query_parameters()

virtual DDS_ReturnCode_t DDSQueryCondition::set_query_parameters ( const DDS_StringSeq query_parameters)
pure virtual

Sets the query parameters.

Parameters
query_parameters<<in>> the new query parameters