![]() |
OpenSplice C# API
v6.x
OpenSplice C# Data Distribution Service Data-Centric Publish-Subscribe API
|
IQueryCondition objects are specialized IReadCondition objects that allow the application to specify a filter on the locally available data. More...
Public Member Functions | |
string | GetQueryExpression () |
This operation returns the query expression associated with the IQueryCondition. More... | |
ReturnCode | GetQueryParameters (ref string[] queryParameters) |
This operation obtains the query parameters associated with the IQueryCondition More... | |
ReturnCode | SetQueryParameters (params string[] queryParameters) |
This operation changes the query parameters associated with the IQueryCondition. More... | |
![]() | |
IDataReader | GetDataReader () |
This operation returns the IDataReader associated with the IReadCondition. More... | |
InstanceStateKind | GetInstanceStateMask () |
This operation returns the set of InstanceStates that are taken into account to determine the TriggerValue of the IReadCondition. More... | |
SampleStateKind | GetSampleStateMask () |
This operation returns the set of SampleStates that are taken into account to determine the TriggerValue of the IReadCondition. More... | |
ViewStateKind | GetViewStateMask () |
This operation returns the set of ViewStates that are taken into account to determine the TriggerValue of the IReadCondition. More... | |
![]() | |
bool | GetTriggerValue () |
Each ICondition has a TriggerValue that can be true or false and is set by the DDS depending on the evaluation of the ICondition. More... | |
IQueryCondition objects are specialized IReadCondition objects that allow the application to specify a filter on the locally available data.
The IDataReader objects accept a set of IQueryCondition objects for the IDataReader and provide support (in conjunction with IWaitSet objects) for an alternative communication style between the Data Distribution Service and the application (i.e., state-based rather than event-based).
Query Function
IQueryCondition objects allow an application to specify the data samples it is interested in (by specifying the desired sample-states, view-states, instance-states and query expression); see the parameter definitions for IDataReader's Read/Take operations. This allows the Data Distribution Service to trigger the condition only when suitable information is available. IQueryCondition objects are to be used in conjunction with an IWaitSet. More than one IQueryCondition may be attached to the same IDataReader.
The query (queryExpression) is similar to an SQL WHERE clause and can be parameterized by arguments that are dynamically changeable with the IQueryCondition.SetQueryParameters operation.
Definition at line 562 of file DdsDcpsInterfaces.cs.
string DDS.IQueryCondition.GetQueryExpression | ( | ) |
This operation returns the query expression associated with the IQueryCondition.
That is, the expression specified when the IQueryCondition was created. The operation will return null when there was an internal error or when the IQueryCondition was already deleted.
ReturnCode DDS.IQueryCondition.GetQueryParameters | ( | ref string [] | queryParameters | ) |
This operation obtains the query parameters associated with the IQueryCondition
That is, the parameters specified on the last successful call to IQueryCondition.SetQueryArguments or, if SetQueryArguments was never called, the arguments specified when the IQueryCondition were created.
The queryParameters parameter will contain a sequence of strings with the parameters used in the SQL expression (i.e., the n tokens in the expression). The number of parameters in the result sequence will exactly match the number of n tokens in the query expression associated with the IQueryCondition.
queryParameters | A reference to a sequence of strings that will be used to store the parameters used in the SQL expression |
ReturnCode DDS.IQueryCondition.SetQueryParameters | ( | params string [] | queryParameters | ) |
This operation changes the query parameters associated with the IQueryCondition.
This operation changes the query parameters associated with the IQueryCondition. The parameter queryParameters is a sequence of strings which are the parameter values used in the SQL query string (i.e., the n tokens in the expression). The number of values in queryParameters must be equal or greater than the highest referenced n token in the queryExpression (e.g. if %1 and %8 are used as parameter in the queryExpression, the queryParameters should at least contain n+1 = 9 values).
queryParameters | A sequence of strings which are the parameters used in the SQL query string (i.e., the n tokens in the expression). |