org.datanucleus.jta
Class JNDIBasedTransactionManagerLocator

java.lang.Object
  extended by org.datanucleus.jta.JNDIBasedTransactionManagerLocator
All Implemented Interfaces:
TransactionManagerLocator
Direct Known Subclasses:
CustomJNDITransactionManagerLocator, JBossTransactionManagerLocator, OC4JTransactionManagerLocator, OrionTransactionManagerLocator, ResinTransactionManagerLocator, SAPWebASTransactionManagerLocator, SunTransactionManagerLocator, WebLogicTransactionManagerLocator

public abstract class JNDIBasedTransactionManagerLocator
extends java.lang.Object
implements TransactionManagerLocator

Locator for a JTA TransactionManager using JNDI context namings. All extending classes must provide the method getJNDIName() returning a name that is then looked up via JNDI to return the manager object.


Field Summary
protected static Localiser LOCALISER
          Localisation utility for output messages
 
Constructor Summary
JNDIBasedTransactionManagerLocator()
           
 
Method Summary
abstract  java.lang.String getJNDIName()
          Accessor for the JNDI name to use.
 javax.transaction.TransactionManager getTransactionManager(ClassLoaderResolver clr)
          Method to return the TransactionManager looking it up using JNDI.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCALISER

protected static final Localiser LOCALISER
Localisation utility for output messages

Constructor Detail

JNDIBasedTransactionManagerLocator

public JNDIBasedTransactionManagerLocator()
Method Detail

getJNDIName

public abstract java.lang.String getJNDIName()
Accessor for the JNDI name to use.

Returns:
The JNDI name where the txn manager is stored.

getTransactionManager

public javax.transaction.TransactionManager getTransactionManager(ClassLoaderResolver clr)
Method to return the TransactionManager looking it up using JNDI.

Specified by:
getTransactionManager in interface TransactionManagerLocator
Parameters:
clr - ClassLoader Resolver
Returns:
The TransactionManager


Copyright © 2011. All Rights Reserved.