public class ExtensionPointEventFilter extends Object implements EventFilter
Constructor and Description |
---|
ExtensionPointEventFilter(ExtensionPoint<?> extensionPoint)
Create a new extension point event filter.
|
ExtensionPointEventFilter(String id)
Create a new extension point 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 String id
public ExtensionPointEventFilter(ExtensionPoint<?> extensionPoint)
extensionPoint
- The extension point to pass events forpublic ExtensionPointEventFilter(String id)
id
- The ID of the extension pointpublic 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