use of org.hibernate.event.spi.PreCollectionRemoveEventListener in project hibernate-orm by hibernate.
the class CollectionRemoveAction method preRemove.
private void preRemove() {
final EventListenerGroup<PreCollectionRemoveEventListener> listenerGroup = listenerGroup(EventType.PRE_COLLECTION_REMOVE);
if (listenerGroup.isEmpty()) {
return;
}
final PreCollectionRemoveEvent event = new PreCollectionRemoveEvent(getPersister(), getCollection(), eventSource(), affectedOwner);
for (PreCollectionRemoveEventListener listener : listenerGroup.listeners()) {
listener.onPreRemoveCollection(event);
}
}
use of org.hibernate.event.spi.PreCollectionRemoveEventListener in project hibernate-reactive by hibernate.
the class ReactiveCollectionRemoveAction method preRemove.
private void preRemove() {
final EventListenerGroup<PreCollectionRemoveEventListener> listenerGroup = listenerGroup(EventType.PRE_COLLECTION_REMOVE);
if (listenerGroup.isEmpty()) {
return;
}
final PreCollectionRemoveEvent event = new PreCollectionRemoveEvent(getPersister(), getCollection(), eventSource(), affectedOwner);
for (PreCollectionRemoveEventListener listener : listenerGroup.listeners()) {
listener.onPreRemoveCollection(event);
}
}
Aggregations