|
EclipseLink 2.0.0, build 'v20091127-r5931' API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EntityTransaction
Interface used to control transactions on resource-local entity
managers. The EntityManager.getTransaction()
method returns the
EntityTransaction
interface.
Method Summary | |
---|---|
void |
begin()
Start a resource transaction. |
void |
commit()
Commit the current resource transaction, writing any unflushed changes to the database. |
boolean |
getRollbackOnly()
Determine whether the current resource transaction has been marked for rollback. |
boolean |
isActive()
Indicate whether a resource transaction is in progress. |
void |
rollback()
Roll back the current resource transaction. |
void |
setRollbackOnly()
Mark the current resource transaction so that the only possible outcome of the transaction is for the transaction to be rolled back. |
Method Detail |
---|
void begin()
java.lang.IllegalStateException
- if isActive()
is truevoid commit()
java.lang.IllegalStateException
- if isActive()
is false
RollbackException
- if the commit failsvoid rollback()
java.lang.IllegalStateException
- if isActive()
is false
PersistenceException
- if an unexpected error
condition is encounteredvoid setRollbackOnly()
java.lang.IllegalStateException
- if isActive()
is falseboolean getRollbackOnly()
java.lang.IllegalStateException
- if isActive()
is falseboolean isActive()
PersistenceException
- if an unexpected error
condition is encountered
|
EclipseLink 2.0.0, build 'v20091127-r5931' API Reference | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |