org.jboss.tm
Class TransactionLocalDelegateImpl

java.lang.Object
  extended byorg.jboss.tm.TransactionLocalDelegateImpl
All Implemented Interfaces:
TransactionLocalDelegate (src)

public class TransactionLocalDelegateImpl
extends java.lang.Object
implements TransactionLocalDelegate (src)

An implementation of the transaction local implementation using Transaction synchronizations. There is one of these per transaction local


Nested Class Summary
protected static class TransactionLocalDelegateImpl.TransactionLocalSynchronization (src)
           
 
Field Summary
protected  TransactionManager (src) manager
          The transaction manager
protected static ConcurrentHashMap synchronizationsByTransaction
          The synchronizations for each transaction
 
Constructor Summary
TransactionLocalDelegateImpl(TransactionManager (src)  manager)
          Construct a new delegate for the given transaction manager
 
Method Summary
 boolean containsValue(TransactionLocal (src)  unused, Transaction (src)  tx)
          does Transaction contain object?
protected static TransactionLocalDelegateImpl.TransactionLocalSynchronization (src) getSynchronization(Transaction (src)  tx, boolean create)
          Retrieve a synchronization for the transaction
 java.lang.Object getValue(TransactionLocal (src)  unused, Transaction (src)  tx)
          get the transaction local value.
protected static void removeSynchronization(Transaction (src)  tx)
          Remove a synchronization
 void storeValue(TransactionLocal (src)  unused, Transaction (src)  tx, java.lang.Object value)
          put the value in the transaction local
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

manager

protected TransactionManager (src)  manager
The transaction manager


synchronizationsByTransaction

protected static ConcurrentHashMap synchronizationsByTransaction
The synchronizations for each transaction

Constructor Detail

TransactionLocalDelegateImpl

public TransactionLocalDelegateImpl(TransactionManager (src)  manager)
Construct a new delegate for the given transaction manager

Parameters:
manager - the transaction manager
Method Detail

getSynchronization

protected static TransactionLocalDelegateImpl.TransactionLocalSynchronization (src)  getSynchronization(Transaction (src)  tx,
                                                                                                 boolean create)
Retrieve a synchronization for the transaction

Parameters:
tx - the transaction
create - whether to create a synchronization if one doesn't exist

removeSynchronization

protected static void removeSynchronization(Transaction (src)  tx)
Remove a synchronization

Parameters:
tx - the transaction to remove

getValue

public java.lang.Object getValue(TransactionLocal (src)  unused,
                                 Transaction (src)  tx)
Description copied from interface: TransactionLocalDelegate (src)
get the transaction local value.

Specified by:
getValue in interface TransactionLocalDelegate (src)

storeValue

public void storeValue(TransactionLocal (src)  unused,
                       Transaction (src)  tx,
                       java.lang.Object value)
Description copied from interface: TransactionLocalDelegate (src)
put the value in the transaction local

Specified by:
storeValue in interface TransactionLocalDelegate (src)

containsValue

public boolean containsValue(TransactionLocal (src)  unused,
                             Transaction (src)  tx)
Description copied from interface: TransactionLocalDelegate (src)
does Transaction contain object?

Specified by:
containsValue in interface TransactionLocalDelegate (src)