CoreDX DDS
C++ Reference Manual

DDS::QueryCondition Class Reference
[DDS Conditions]

A QueryCondition is a specialized ReadCondition which includes a filter. More...

Inheritance diagram for DDS::QueryCondition:
DDS::ReadCondition DDS::Condition

List of all members.

Public Member Functions

const char * get_query_expression (void)
 This routine returns the SQL query expression of this QueryCondition.
ReturnCode_t get_query_parameters (StringSeq &seq)
 This routine returns the parameters to the SQL query expression of this QueryCondition.
ReturnCode_t set_query_parameters (const StringSeq &seq)
 This routine sets the parameters to the SQL query expression of this QueryCondition.

Detailed Description

A QueryCondition is a specialized ReadCondition which includes a filter.

The trigger_value is driven by the data available, after applying the filter, in the associated DataReader.

Not Yet Supported:
CoreDX DDS does not yet implement QueryConditions as a trigger for a WaitSet.

Member Function Documentation

const char* DDS::QueryCondition::get_query_expression ( void   ) 

This routine returns the SQL query expression of this QueryCondition.

The query expression is an SQL syntax conditional expression that is provided when the QueryCondition is created.

ReturnCode_t DDS::QueryCondition::get_query_parameters ( StringSeq seq  ) 

This routine returns the parameters to the SQL query expression of this QueryCondition.

The query expression is an SQL syntax conditional expression that is provided when the QueryCondition is created. The query expression may contain references to positional parameters of the form '0', '1'. These parameters can be changed dynamically to affect the expression.

See also:
DataReader_create_querycondition()
QueryCondition_set_query_parameters()
ReturnCode_t DDS::QueryCondition::set_query_parameters ( const StringSeq seq  ) 

This routine sets the parameters to the SQL query expression of this QueryCondition.

The query_expression is an SQL like condition expression, and the parameters argument provides optional parameters that are referenced by the query_expression. The syntax for refering to paramters in a query_expression is the percent sign '' followed by a number. The number is the index of the paramter in the query_paramters sequence. Parameters are counted starting at zero. So, "%0" refers to the first parameter, and "%4" refers to the fifth paramter. Using this syntax, the expression "x<%0" would test the value of 'x' against the first parameter in the sequence.

This routine allows the parameters to be changed dynamically.

See also:
DataReader_create_querycondition()
 All Classes Files Functions Variables

© 2009-2013 Twin Oaks Computing, Inc
Castle Rock, CO 80108
All rights reserved.