|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for callbacks after transaction completion. Supported by AbstractPlatformTransactionManager.
TransactionSynchronizationManager
,
AbstractPlatformTransactionManager
Field Summary | |
static int |
STATUS_COMMITTED
Completion status in case of proper commit |
static int |
STATUS_ROLLED_BACK
Completion status in case of proper rollback |
static int |
STATUS_UNKNOWN
Status in case of heuristic mixed completion or system errors |
Method Summary | |
void |
afterCompletion(int status)
Invoked after transaction commit/rollback. |
void |
beforeCommit(boolean readOnly)
Invoked before transaction commit (before "beforeCompletion"). |
void |
beforeCompletion()
Invoked before transaction commit/rollback (after "beforeCommit"). |
void |
resume()
Resume this synchronization. |
void |
suspend()
Suspend this synchronization. |
Field Detail |
public static final int STATUS_COMMITTED
public static final int STATUS_ROLLED_BACK
public static final int STATUS_UNKNOWN
Method Detail |
public void suspend()
public void resume()
public void beforeCommit(boolean readOnly)
Note that exceptions will get propagated to the commit caller and cause a rollback of the transaction.
readOnly
- if the transaction is defined as read-only transaction
java.lang.RuntimeException
- in case of errorspublic void beforeCompletion()
Note that exceptions will get propagated to the commit caller and cause a rollback of the transaction.
java.lang.RuntimeException
- in case of errorspublic void afterCompletion(int status)
Note that exceptions will get propagated to the commit or rollback caller, although they will not influence the outcome of the transaction.
status
- completion status according to the STATUS_ constants
java.lang.RuntimeException
- in case of errorsSTATUS_COMMITTED
,
STATUS_ROLLED_BACK
,
STATUS_UNKNOWN
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |