public interface EntityFilter extends Filter
To use this you must set the
filter type value
as
TYPE_ENTITYFILTER and the
Entity Class ID
used by
subscription. The filter returned by
makeFilter
can be safely casted to EntityFilter.
After that, it may be used in a subcription
setting an empty EntityKey
whill will be used
to set filter key values. Please note, you must create and set up different filters for
different subscriptions; a filter is not allowed to be used for many subscription simultaneously.
To change filter value you may call:
set method
doesn't perform any action for this class.
You should call flush after many filter operations to force any buffered action to be sent to the server.
Filter
,
FilterParam
,
FilterListener
Modifier and Type | Field and Description |
---|---|
static int |
TYPE_ENTITYFILTER
The filter type value.
|
STATUS_CREATED, STATUS_CREATING, STATUS_DESTROYED, STATUS_DESTROYING
RESULT_INVALID_CONNECTION_STATUS
RESULT_GENERIC_ERROR, RESULT_INVALID_STATUS, RESULT_OK, STATUS_INIT, STATUS_RELEASED
Modifier and Type | Method and Description |
---|---|
int |
add(EntityKey entityKey)
Add the EntityKey to the filter.
|
int |
del(EntityKey entityKey)
Remove the EntityKey from the filter.
|
int |
flush()
Send to the server any buffered filter action.
|
int |
reset()
Remove all the key values from the filter.
|
getConnection
getContext, getListener, getParam
enumChilds, getStatus, release
static final int TYPE_ENTITYFILTER
int add(EntityKey entityKey)
entityKey
- the partial or full EntityKey.RESULT_OK
if the operation completed
successfully,
RESULT_INVALID_STATUS
if the
current status is not Filter.STATUS_CREATED
,
RESULT_INVALID_CONNECTION_STATUS
if the associated Connection
current status is not
Connection.STATUS_CONNECTED
,
RESULT_GENERIC_ERROR
otherwise.
int del(EntityKey entityKey)
entityKey
- the partial or full EntityKey.RESULT_OK
if the operation completed
successfully,
RESULT_INVALID_STATUS
if the
current status is not Filter.STATUS_CREATED
,
RESULT_INVALID_CONNECTION_STATUS
if the associated Connection
current status is not
Connection.STATUS_CONNECTED
,
RESULT_GENERIC_ERROR
otherwise.
int reset()
RESULT_OK
if the operation completed
successfully,
RESULT_INVALID_STATUS
if the
current status is not Filter.STATUS_CREATED
,
RESULT_INVALID_CONNECTION_STATUS
if the associated Connection
current status is not
Connection.STATUS_CONNECTED
,
RESULT_GENERIC_ERROR
otherwise.
int flush()
RESULT_OK
if the operation completed
successfully,
RESULT_INVALID_STATUS
if the
current status is not Filter.STATUS_CREATED
,
RESULT_INVALID_CONNECTION_STATUS
if the associated Connection
current status is not
Connection.STATUS_CONNECTED
,
RESULT_GENERIC_ERROR
otherwise.
Submit a bug or feature to FT\API Programming Support