EventWhiteList

public final class EventWhiteList implements EventFilter

An EventFilter which allows only events of given types.

All other events are discarded by this filter by default.

Caution: Make sure you are aware of consequences of discarding system events posted by a repository when using this filter.

See also

Functions

Link copied to clipboard
public static EventWhiteList allowEvents(Array<Class<? extends EventMessage>> eventClasses)
Creates a new instance of EventWhiteList allowing events of the given types.
Link copied to clipboard
public Optional<? extends EventMessage> filter(EventMessage event)
Applies this filter to the given event.

Inherited functions

Link copied to clipboard
public static EventFilter allowAll()
Obtains an EventFilter which always returns the input event without any change.
Link copied to clipboard
public ImmutableCollection<Event> filter(Collection<Event> events)
Applies this filter to the given Events in bulk.