|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.emf.transaction.impl.FilterManager
An object that manages the filtering of notifications. This class can implement optimizations to reduce the effort of filtering notification lists for listeners that have similar filters.
Method Summary | |
---|---|
static FilterManager |
getInstance()
Obtains the singleton instance of this class. |
java.util.List |
select(java.util.List notifications,
NotificationFilter filter)
Selects the notifications in the given list that match the specified filter. |
java.util.List |
select(java.util.List notifications,
NotificationFilter filter,
java.util.ArrayList cache)
Selects the notifications in the given list that match the specified filter. |
java.util.List |
selectUnbatched(java.util.List notification,
NotificationFilter filter)
Selects the notifications in the given singleton list of an unbatched notification that match the specified filter. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static FilterManager getInstance()
public java.util.List select(java.util.List notifications, NotificationFilter filter, java.util.ArrayList cache)
For unbatched notifications, it is better to use the
FilterManager.selectUnbatched(List, NotificationFilter)
method.
notifications
- a list of notifications to select fromfilter
- a notification filtercache
- A cache list that is precisely the same size as the notifications
list but is used and reused as a scratch pad. Its purpose is to cut down the
number of objects created and garbage collected while propagating filtered
events to a group of listeners. Note that it will be repeatedly cleared and
populated each time it is given to this method.
FilterManager.selectUnbatched(List, NotificationFilter)
public java.util.List select(java.util.List notifications, NotificationFilter filter)
For unbatched notifications, it is better to use the
FilterManager.selectUnbatched(List, NotificationFilter)
method.
notifications
- a list of notifications to select fromfilter
- a notification filter
FilterManager.selectUnbatched(List, NotificationFilter)
public java.util.List selectUnbatched(java.util.List notification, NotificationFilter filter)
This method is more efficient for processing unbatched notifications than
is the FilterManager.select(List, NotificationFilter)
method.
notification
- a singleton list containing the unbatched
notificationfilter
- a notification filter
FilterManager.select(List, NotificationFilter)
|
Copyright 2002, 2006 IBM Corporation and others. All Rights Reserved. |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |