public abstract class FilterServiceBase extends Object implements FilterServiceSPI
Modifier | Constructor and Description |
---|---|
protected |
FilterServiceBase(FilterServiceGranularLockFactory lockFactory,
boolean allowIsolation) |
Modifier and Type | Method and Description |
---|---|
void |
addFilterServiceListener(FilterServiceListener filterServiceListener)
Add activity listener.void acquireWriteLock();
|
protected FilterServiceEntry |
addInternal(FilterValueSet filterValueSet,
FilterHandle filterCallback) |
protected void |
applyInternal(FilterSet filterSet) |
void |
destroy()
Destroy the service.
|
protected long |
evaluateInternal(EventBean theEvent,
Collection<FilterHandle> matches) |
protected long |
evaluateInternal(EventBean theEvent,
Collection<FilterHandle> matches,
int statementId) |
int |
getCountTypes() |
int |
getFilterCountApprox() |
long |
getFiltersVersion()
Returns filter version.
|
long |
getNumEventsEvaluated()
Return a count of the number of events evaluated by this service.
|
void |
init()
Initialization is optional and provides a chance to preload things after statements are available.
|
boolean |
isSupportsTakeApply() |
void |
removeFilterServiceListener(FilterServiceListener filterServiceListener)
Remove activity listener.
|
protected void |
removeInternal(FilterHandle filterCallback,
FilterServiceEntry filterServiceEntry) |
protected void |
removeTypeInternal(EventType type) |
void |
resetStats()
Reset the number of events evaluated
|
protected FilterSet |
takeInternal(Set<Integer> statementIds) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
acquireWriteLock, apply, releaseWriteLock, take
add, evaluate, evaluate, remove, removeType
protected FilterServiceBase(FilterServiceGranularLockFactory lockFactory, boolean allowIsolation)
public boolean isSupportsTakeApply()
isSupportsTakeApply
in interface FilterServiceSPI
public long getFiltersVersion()
FilterService
getFiltersVersion
in interface FilterService
public void destroy()
FilterService
destroy
in interface FilterService
protected FilterServiceEntry addInternal(FilterValueSet filterValueSet, FilterHandle filterCallback)
protected void removeInternal(FilterHandle filterCallback, FilterServiceEntry filterServiceEntry)
protected long evaluateInternal(EventBean theEvent, Collection<FilterHandle> matches)
protected long evaluateInternal(EventBean theEvent, Collection<FilterHandle> matches, int statementId)
public final long getNumEventsEvaluated()
FilterService
getNumEventsEvaluated
in interface FilterService
public void resetStats()
FilterService
resetStats
in interface FilterService
public void addFilterServiceListener(FilterServiceListener filterServiceListener)
FilterServiceSPI
addFilterServiceListener
in interface FilterServiceSPI
filterServiceListener
- to addpublic void removeFilterServiceListener(FilterServiceListener filterServiceListener)
FilterServiceSPI
removeFilterServiceListener
in interface FilterServiceSPI
filterServiceListener
- to removeprotected void applyInternal(FilterSet filterSet)
public int getFilterCountApprox()
getFilterCountApprox
in interface FilterServiceSPI
public int getCountTypes()
getCountTypes
in interface FilterServiceSPI
public void init()
FilterServiceSPI
init
in interface FilterServiceSPI
protected void removeTypeInternal(EventType type)