org.apache.ojb.otm.transaction
Class ManagedTransactionFactory

java.lang.Object
  extended byorg.apache.ojb.otm.transaction.ManagedTransactionFactory
All Implemented Interfaces:
TransactionFactory
Direct Known Subclasses:
JBossTransactionFactory, OrionTransactionFactory, WeblogicTransactionFactory, WebSphereTransactionFactory

public abstract class ManagedTransactionFactory
extends java.lang.Object
implements TransactionFactory

Factory for OTM Transactions within a managed environment (JTA).

Author:
Raghu Rajah

Constructor Summary
ManagedTransactionFactory()
          Constructor for ManagedTransactionFactory.
 
Method Summary
 OTMConnection acquireConnection(PBKey pbKey)
          Acquire new connection.
 javax.transaction.Transaction getJTATransaction()
           
abstract  javax.transaction.TransactionManager getJTATransactionManager()
           
 Transaction getTransactionForConnection(OTMConnection connection)
          Get the current Transaction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ManagedTransactionFactory

public ManagedTransactionFactory()
Constructor for ManagedTransactionFactory.

Method Detail

getTransactionForConnection

public Transaction getTransactionForConnection(OTMConnection connection)
Description copied from interface: TransactionFactory
Get the current Transaction.

Specified by:
getTransactionForConnection in interface TransactionFactory
Returns:
the current Transaction
See Also:
TransactionFactory.getTransactionForConnection(OTMConnection)

acquireConnection

public OTMConnection acquireConnection(PBKey pbKey)
Description copied from interface: TransactionFactory
Acquire new connection. Creates a new connection. Depending on the implementation of the factory the connection could be associated to an existing transaction, or not.

Specified by:
acquireConnection in interface TransactionFactory
Returns:
new connection
See Also:
org.apache.ojb.otm.transaction.TransactionFactory#acquireConnection(OTMKit, PBKey)

getJTATransaction

public javax.transaction.Transaction getJTATransaction()

getJTATransactionManager

public abstract javax.transaction.TransactionManager getJTATransactionManager()


Authors: Thomas Mahler and others. (C) 2000 - 2003 Apache Software Foundation
All rights reserved. Published under the Apache License.
http://db.apache.org/ojb
Version: 1.0.rc5, 2003-12-14