Package org.hibernate.jpa.event.spi
Interface Callback
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
EmbeddableCallback
,EntityCallback
,ListenerCallback
Represents a JPA event callback (the method).
Generally there are 2 flavors of this; either an annotated method on the entity itself
or an annotated method on a separate "listener" class. This contract presents
a unified abstraction for both cases
-
Method Summary
Modifier and TypeMethodDescriptionThe type of callback (pre-update, pre-persist, etc) handledboolean
performCallback
(Object entity) Contract for performing the callback
-
Method Details
-
getCallbackType
CallbackType getCallbackType()The type of callback (pre-update, pre-persist, etc) handled -
performCallback
Contract for performing the callback- Parameters:
entity
- Reference to the entity for which the callback is triggered.- Returns:
- Did a callback actually happen?
-