public interface OnSaveAction extends Action
AbstractOnSaveAction
class since we may add more
callback methods to this interface in the future.
The onSave()
method is called first and then either onCommit()
or onRollback(Exception)
. Note that onRollback
is called for all exceptions, even if they happen before the onSave
method has been called.
Modifier and Type | Method and Description |
---|---|
void |
onCommit()
This event is fired after a successful commit.
|
void |
onRollback(Exception ex)
This event is fired after an error that caused the save action
to rollback.
|
void |
onSave()
This event is fired first to let the action do something with
the current item.
|
void onSave()
onRollback(Exception)
is called.void onCommit()
void onRollback(Exception ex)
ex
- The exception that caused the transaction to rollback