org.objectweb.easybeans.transaction.interceptors
Class CMTMandatoryTransactionInterceptor

java.lang.Object
  extended by org.objectweb.easybeans.transaction.interceptors.AbsTransactionInterceptor
      extended by org.objectweb.easybeans.transaction.interceptors.CMTMandatoryTransactionInterceptor
All Implemented Interfaces:
EasyBeansInterceptor

public class CMTMandatoryTransactionInterceptor
extends AbsTransactionInterceptor

Defines an interceptor for method using the MANDATORY attribute.

Author:
Florent Benoit

Field Summary
private  JLog logger
          Logger.
 
Constructor Summary
CMTMandatoryTransactionInterceptor()
          Constructor.
Acquire the transaction manager.
 
Method Summary
 java.lang.Object intercept(EasyBeansInvocationContext invocationContext)
          Execute transaction as specified with the MANDATORY attribute.
 
Methods inherited from class org.objectweb.easybeans.transaction.interceptors.AbsTransactionInterceptor
commit, discard, getApplicationException, getTransactionManager, handleBeanManagedException, handleContextClientTransaction, handleContextContainerTransaction, handleUnspecifiedTransactionContext, isMarkedRollbackOnly, markTransactionRollback, rollback
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

private JLog logger
Logger.

Constructor Detail

CMTMandatoryTransactionInterceptor

public CMTMandatoryTransactionInterceptor()
Constructor.
Acquire the transaction manager.

Method Detail

intercept

public java.lang.Object intercept(EasyBeansInvocationContext invocationContext)
                           throws java.lang.Exception
Execute transaction as specified with the MANDATORY attribute.

Specified by:
intercept in interface EasyBeansInterceptor
Specified by:
intercept in class AbsTransactionInterceptor
Parameters:
invocationContext - context with useful attributes on the current invocation
Returns:
result of the next invocation (to chain interceptors)
Throws:
java.lang.Exception - if interceptor fails
See Also:
EJB 3.0 specification ?12.6.2.5