org.slim3.transaction.jta
Class TransactionManagerImpl

java.lang.Object
  extended by org.slim3.transaction.jta.TransactionManagerImpl
All Implemented Interfaces:
TransactionManager

public class TransactionManagerImpl
extends Object
implements TransactionManager

An implementation class for TransactionManager.

Since:
3.0
Author:
higa

Field Summary
protected  ThreadLocal<TransactionImpl> threadAttachedTx
          The transaction attached to thread.
 
Constructor Summary
TransactionManagerImpl()
          Constructor.
 
Method Summary
 void begin()
           
 void commit()
           
 int getStatus()
           
 Transaction getTransaction()
           
 void resume(Transaction resumeTx)
           
 void rollback()
           
 void setRollbackOnly()
           
 void setTransactionTimeout(int timeout)
           
 Transaction suspend()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

threadAttachedTx

protected ThreadLocal<TransactionImpl> threadAttachedTx
The transaction attached to thread.

Constructor Detail

TransactionManagerImpl

public TransactionManagerImpl()
Constructor.

Method Detail

begin

public void begin()
           throws NotSupportedException,
                  SystemException
Specified by:
begin in interface TransactionManager
Throws:
NotSupportedException
SystemException

commit

public void commit()
            throws RollbackException,
                   HeuristicMixedException,
                   HeuristicRollbackException,
                   SecurityException,
                   IllegalStateException,
                   SystemException
Specified by:
commit in interface TransactionManager
Throws:
RollbackException
HeuristicMixedException
HeuristicRollbackException
SecurityException
IllegalStateException
SystemException

suspend

public Transaction suspend()
                    throws SystemException
Specified by:
suspend in interface TransactionManager
Throws:
SystemException

resume

public void resume(Transaction resumeTx)
            throws InvalidTransactionException,
                   IllegalStateException,
                   SystemException
Specified by:
resume in interface TransactionManager
Throws:
InvalidTransactionException
IllegalStateException
SystemException

rollback

public void rollback()
              throws IllegalStateException,
                     SecurityException,
                     SystemException
Specified by:
rollback in interface TransactionManager
Throws:
IllegalStateException
SecurityException
SystemException

setRollbackOnly

public void setRollbackOnly()
                     throws IllegalStateException,
                            SystemException
Specified by:
setRollbackOnly in interface TransactionManager
Throws:
IllegalStateException
SystemException

setTransactionTimeout

public void setTransactionTimeout(int timeout)
                           throws SystemException
Specified by:
setTransactionTimeout in interface TransactionManager
Throws:
SystemException

getStatus

public int getStatus()
Specified by:
getStatus in interface TransactionManager

getTransaction

public Transaction getTransaction()
Specified by:
getTransaction in interface TransactionManager


Copyright © 2008-2009 The Slim3 project. All Rights Reserved.