Package org.hibernate.event.spi
Interface EventEngineContributions
public interface EventEngineContributions
Callback for
EventEngineContributor
-
Method Summary
Modifier and TypeMethodDescription<T> void
configureListeners
(EventType<T> eventType, Consumer<EventListenerGroup<T>> action) Perform an action against the listener group for the specified event-type<T> EventType<T>
contributeEventType
(String name, Class<T> listenerRole) Register a custom event type.<T> EventType<T>
contributeEventType
(String name, Class<T> listenerRole, T... defaultListener) Register a custom event type with a default listener.<T> EventType<T>
findEventType
(String name) Return the EventType by name, if one
-
Method Details
-
findEventType
Return the EventType by name, if one -
contributeEventType
Register a custom event type.- API Note:
- We except the "raw" state rather than an `EventType` instance to account for the `EventType#ordinal` property. All registered types must be contiguous, so we handle the ordinality behind the scenes
-
contributeEventType
Register a custom event type with a default listener. -
configureListeners
Perform an action against the listener group for the specified event-type
-