Method SearchCQ
SearchCQ(ContinuousQuery)
Performs search on the Cache based on the specified and registers the notifications.
Declaration
[Obsolete("use ExecuteReaderCQ instead")]
public virtual ICollection SearchCQ(ContinuousQuery query)
Parameters
Type |
Name |
Description |
ContinuousQuery |
query |
to perform the search and register notifications for.
|
Returns
Type |
Description |
System.Collections.ICollection |
|
Examples
string queryString = "SELECT MyApplication.Employee WHERE this.Salary > ?";
Hashtable values = new Hashtable();
values.Add("Salary", 50000);
ContinuousQuery query = new ContinuousQuery(queryString, values);
query.RegisterAddNotification(new ContinuousQueryItemAddedCallback(query_ItemAdded));
query.RegisterUpdateNotification(new ContinuousQueryItemUpdatedCallback(query_ItemUpdated));
query.RegisterRemoveNotification(new ContinuousQueryItemRemovedCallback(query_ItemRemoved));
ICollection results = cache.SearchCQ(query);