public class CombiningEventFilter extends java.lang.Object implements EventFilter
Modifier and Type | Field and Description |
---|---|
private boolean |
allMustPass |
private java.util.Collection<EventFilter> |
filters |
Constructor and Description |
---|
CombiningEventFilter(java.util.Collection<EventFilter> filters,
boolean allMustPass)
Create a new combining event filter.
|
Modifier and Type | Method and Description |
---|---|
boolean |
shouldSend(EventType event,
ExtensionPoint<?> extensionPoint,
Extension<?> extension)
Determine if the event should be sent to the event handler or not.
|
private final java.util.Collection<EventFilter> filters
private final boolean allMustPass
public CombiningEventFilter(java.util.Collection<EventFilter> filters, boolean allMustPass)
filters
- A collection of event filtersallMustPass
- TRUE if the event must pass all filters to
pass this filter, FALSE if the event must pass at least one
filter to pass this filterpublic boolean shouldSend(EventType event, ExtensionPoint<?> extensionPoint, Extension<?> extension)
EventFilter
shouldSend
in interface EventFilter
event
- The event that happendextensionPoint
- The extension point that the extension
extends, or that the event happened toextension
- The extension the event happend to, or null if the
event happended to the extension point