org.apache.webbeans.spi
Interface TransactionService


public interface TransactionService

Transaction related service.

Version:
$Rev$ $Date$

Method Summary
 Transaction getTransaction()
          Get the transaction context of the calling thread
 TransactionManager getTransactionManager()
          Get TransactionManager instance from container.
 UserTransaction getUserTransaction()
          Gets user transaction instance.
 void registerTransactionSynchronization(TransactionPhase phase, ObserverMethod<? super Object> observer, Object event)
          Register transaction synch.
 

Method Detail

getTransactionManager

TransactionManager getTransactionManager()
Get TransactionManager instance from container.

Returns:
the TransactionManager or null if none is registered.

getTransaction

Transaction getTransaction()
Get the transaction context of the calling thread

Returns:
the Transaction or null if no TransactionManager is used.

getUserTransaction

UserTransaction getUserTransaction()
Gets user transaction instance.

Returns:
user transaction object

registerTransactionSynchronization

void registerTransactionSynchronization(TransactionPhase phase,
                                        ObserverMethod<? super Object> observer,
                                        Object event)
                                        throws Exception
Register transaction synch.

Parameters:
phase - transaction phase
observer - observer
event - event
Throws:
Exception


Copyright © 2008-2010 The Apache Software Foundation. All Rights Reserved.