|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.openjpa.ee.AbstractManagedRuntime
org.apache.openjpa.kernel.LocalManagedRuntime
class LocalManagedRuntime
Uses a local implementation of the TransactionManager interface.
This manager is valid only for a single Broker.
It duplicates non-managed transaction control.
| Constructor Summary | |
|---|---|
LocalManagedRuntime(Broker broker)
Constructor. |
|
| Method Summary | |
|---|---|
void |
begin()
|
void |
commit()
|
boolean |
delistResource(XAResource xaRes,
int flag)
|
boolean |
enlistResource(XAResource xaRes)
|
Throwable |
getRollbackCause()
Returns the Throwable that caused the current transaction to be marked for rollback, provided that any exists. |
int |
getStatus()
|
Transaction |
getTransaction()
|
TransactionManager |
getTransactionManager()
Return the TransactionManager for the managed runtime. |
void |
registerSynchronization(Synchronization sync)
|
void |
resume(Transaction tobj)
|
void |
rollback()
|
void |
setRollbackOnly()
|
void |
setRollbackOnly(Throwable cause)
Sets the rollback only flag on the current transaction. |
void |
setTransactionTimeout(int sec)
|
Transaction |
suspend()
|
| Methods inherited from class org.apache.openjpa.ee.AbstractManagedRuntime |
|---|
doNonTransactionalWork, getTransactionKey |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.openjpa.ee.ManagedRuntime |
|---|
doNonTransactionalWork, getTransactionKey |
| Constructor Detail |
|---|
public LocalManagedRuntime(Broker broker)
| Method Detail |
|---|
public TransactionManager getTransactionManager()
ManagedRuntime
getTransactionManager in interface ManagedRuntimepublic void begin()
begin in interface TransactionManagerpublic void commit()
commit in interface Transactioncommit in interface TransactionManagerpublic void rollback()
rollback in interface Transactionrollback in interface TransactionManagerpublic void setRollbackOnly()
setRollbackOnly in interface TransactionsetRollbackOnly in interface TransactionManagerpublic void setRollbackOnly(Throwable cause)
ManagedRuntime
setRollbackOnly in interface ManagedRuntimecause - the Throwable that caused the transaction to be
marked for rollback, or null of none is knownpublic Throwable getRollbackCause()
ManagedRuntime
getRollbackCause in interface ManagedRuntimepublic int getStatus()
getStatus in interface TransactiongetStatus in interface TransactionManagerpublic Transaction getTransaction()
getTransaction in interface TransactionManager
public void resume(Transaction tobj)
throws SystemException
resume in interface TransactionManagerSystemException
public void setTransactionTimeout(int sec)
throws SystemException
setTransactionTimeout in interface TransactionManagerSystemException
public Transaction suspend()
throws SystemException
suspend in interface TransactionManagerSystemException
public boolean delistResource(XAResource xaRes,
int flag)
throws SystemException
delistResource in interface TransactionSystemException
public boolean enlistResource(XAResource xaRes)
throws SystemException
enlistResource in interface TransactionSystemExceptionpublic void registerSynchronization(Synchronization sync)
registerSynchronization in interface Transaction
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||