Top Description Methods
org.hibernate.event.spi

public Interface EventEngineContributions

Imports
java.util.function.Consumer, org.hibernate.event.service.spi.EventListenerGroup

Callback for EventEngineContributor
Author
Steve Ebersole

Method Summary

Modifier and TypeMethod and Description
public <T> void
configureListeners(EventType<T> eventType, Consumer<EventListenerGroup<T>> action)

Perform an action against the listener group for the specified event-type

public <T> EventType<T>
contributeEventType(String name, Class<T> listenerRole)

Register a custom event type.

public <T> EventType<T>
contributeEventType(String name, Class<T> listenerRole, T... defaultListener)

Register a custom event type with a default listener.

public <T> EventType<T>
findEventType(String name)

Return the EventType by name, if one

Method Detail

configureListenersback to summary
public <T> void configureListeners(EventType<T> eventType, Consumer<EventListenerGroup<T>> action)

Perform an action against the listener group for the specified event-type

contributeEventTypeback to summary
public <T> EventType<T> contributeEventType(String name, Class<T> listenerRole)

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

contributeEventTypeback to summary
public <T> EventType<T> contributeEventType(String name, Class<T> listenerRole, T... defaultListener)

Register a custom event type with a default listener.

findEventTypeback to summary
public <T> EventType<T> findEventType(String name)

Return the EventType by name, if one