![]() |
GridGain C++
|
Continuous query client. More...
#include <continuous_query_client.h>
Public Types | |
enum | { DEFAULT_BUFFER_SIZE = 1 } |
Default value for the buffer size. | |
enum | { DEFAULT_TIME_INTERVAL = 0 } |
Default value for the time interval. | |
Public Member Functions | |
~ContinuousQueryClient () | |
Destructor. | |
ContinuousQueryClient (Reference< event::CacheEntryEventListener< K, V > > lsnr) | |
Constructor. More... | |
void | SetBufferSize (int32_t val) |
Set buffer size. More... | |
int32_t | GetBufferSize () const |
Get buffer size. More... | |
void | SetTimeInterval (int64_t val) |
Set time interval. More... | |
int64_t | GetTimeInterval () const |
Get time interval. More... | |
void | SetIncludeExpired (bool val) |
Sets a value indicating whether to notify about Expired events. More... | |
bool | GetIncludeExpired () const |
Gets a value indicating whether to notify about Expired events. More... | |
void | SetListener (Reference< event::CacheEntryEventListener< K, V > > lsnr) |
Set cache entry event listener. More... | |
const event::CacheEntryEventListener< K, V > & | GetListener () const |
Get cache entry event listener. More... | |
event::CacheEntryEventListener< K, V > & | GetListener () |
Get cache entry event listener. More... | |
void | SetJavaFilter (const event::JavaCacheEntryEventFilter &fltr) |
Set Java event filter to be used on server to determine what events should be transferred to local event listener. More... | |
event::JavaCacheEntryEventFilter & | GetJavaFilter () |
Get remote Java filter reference. More... | |
const event::JavaCacheEntryEventFilter & | GetJavaFilter () const |
Get remote Java filter reference. More... | |
Continuous query client.
Continuous query client allow to register a listener for cache update events. On any update to the related cache an event is sent to the client that has executed the query and listener is notified on that client.
Continuous query can either be executed on the whole topology or only on local node.
To execute the query over the cache use method ignite::thin::cache::CacheClient::QueryContinuous().
|
inlineexplicit |
Constructor.
lsnr | Event listener. Invoked on the node where continuous query execution has been started. |
|
inline |
Get buffer size.
When a cache update happens, entry is first put into a buffer. Entries from buffer will be sent to the master node only if the buffer is full or time provided via SetTimeInterval is exceeded.
|
inline |
Gets a value indicating whether to notify about Expired events.
If true
, then the listener will get notifications about expired cache entries. Otherwise, only Created, Updated, and Removed events will be passed to the listener.
Defaults to false
.
|
inline |
Get remote Java filter reference.
|
inline |
Get remote Java filter reference.
|
inline |
Get cache entry event listener.
|
inline |
Get cache entry event listener.
|
inline |
Get time interval.
When a cache update happens, entry is first put into a buffer. Entries from buffer are sent to the master node only if the buffer is full (its size can be changed via SetBufferSize) or time provided via this method is exceeded.
Default value is DEFAULT_TIME_INTERVAL, i.e. 0, which means that time check is disabled and entries will be sent only when buffer is full.
|
inline |
Set buffer size.
When a cache update happens, entry is first put into a buffer. Entries from buffer will be sent to the master node only if the buffer is full or time provided via SetTimeInterval is exceeded.
val | Buffer size. |
|
inline |
Sets a value indicating whether to notify about Expired events.
If true
, then the listener will get notifications about expired cache entries. Otherwise, only Created, Updated, and Removed events will be passed to the listener.
Defaults to false
.
val | Flag value. |
|
inline |
Set Java event filter to be used on server to determine what events should be transferred to local event listener.
fltr | Java remote filter. |
|
inline |
Set cache entry event listener.
lsnr | Cache entry event listener. Invoked on the node where continuous query execution has been started. |
|
inline |
Set time interval.
When a cache update happens, entry is first put into a buffer. Entries from buffer are sent to the master node only if the buffer is full (its size can be changed via SetBufferSize) or time provided via this method is exceeded.
Default value is DEFAULT_TIME_INTERVAL, i.e. 0, which means that time check is disabled and entries will be sent only when buffer is full.
val | Time interval in miliseconds. |