org.mule.transaction
Class AbstractTransaction

java.lang.Object
  extended byorg.mule.transaction.AbstractTransaction
All Implemented Interfaces:
UMOTransaction
Direct Known Subclasses:
AbstractSingleResourceTransaction, XaTransaction

public abstract class AbstractTransaction
extends java.lang.Object
implements UMOTransaction

This base class provides low level features for transactions

Version:
$Revision: 1.1 $
Author:
Guillaume Nodet

Field Summary
protected  Log logger
           
 
Fields inherited from interface org.mule.umo.UMOTransaction
STATUS_ACTIVE, STATUS_COMMITTED, STATUS_COMMITTING, STATUS_MARKED_ROLLBACK, STATUS_NO_TRANSACTION, STATUS_PREPARED, STATUS_PREPARING, STATUS_ROLLEDBACK, STATUS_ROLLING_BACK, STATUS_UNKNOWN
 
Constructor Summary
AbstractTransaction()
           
 
Method Summary
 void begin()
          Begin the transaction.
 void commit()
          Commit the transaction
protected abstract  void doBegin()
          Really begin the transaction.
protected abstract  void doCommit()
          Commit the transaction on the underlying resource
protected abstract  void doRollback()
          Rollback the transaction on the underlying resource
 boolean isBegun()
           
 boolean isCommitted()
           
 boolean isRollbackOnly()
           
 boolean isRolledBack()
           
 void rollback()
          Rollback the transaction
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mule.umo.UMOTransaction
bindResource, getResource, getStatus, hasResource, setRollbackOnly
 

Field Detail

logger

protected final transient Log logger
Constructor Detail

AbstractTransaction

public AbstractTransaction()
Method Detail

isRollbackOnly

public boolean isRollbackOnly()
                       throws UMOTransactionException
Specified by:
isRollbackOnly in interface UMOTransaction
Throws:
UMOTransactionException

isBegun

public boolean isBegun()
                throws UMOTransactionException
Specified by:
isBegun in interface UMOTransaction
Throws:
UMOTransactionException

isRolledBack

public boolean isRolledBack()
                     throws UMOTransactionException
Specified by:
isRolledBack in interface UMOTransaction
Throws:
UMOTransactionException

isCommitted

public boolean isCommitted()
                    throws UMOTransactionException
Specified by:
isCommitted in interface UMOTransaction
Throws:
UMOTransactionException

begin

public void begin()
           throws UMOTransactionException
Description copied from interface: UMOTransaction
Begin the transaction.

Specified by:
begin in interface UMOTransaction
Throws:
UMOTransactionException

commit

public void commit()
            throws UMOTransactionException
Description copied from interface: UMOTransaction
Commit the transaction

Specified by:
commit in interface UMOTransaction
Throws:
UMOTransactionException

rollback

public void rollback()
              throws UMOTransactionException
Description copied from interface: UMOTransaction
Rollback the transaction

Specified by:
rollback in interface UMOTransaction
Throws:
UMOTransactionException

doBegin

protected abstract void doBegin()
                         throws UMOTransactionException
Really begin the transaction. Note that resources are enlisted yet.

Throws:
UMOTransactionException

doCommit

protected abstract void doCommit()
                          throws UMOTransactionException
Commit the transaction on the underlying resource

Throws:
UMOTransactionException

doRollback

protected abstract void doRollback()
                            throws UMOTransactionException
Rollback the transaction on the underlying resource

Throws:
UMOTransactionException


Copyright © 2003-2005 SymphonySoft Limited. All Rights Reserved.