org.apache.camel.spring.spi
Class SpringTransactionPolicy

java.lang.Object
  extended by org.apache.camel.spring.spi.SpringTransactionPolicy
All Implemented Interfaces:
Policy, TransactedPolicy

public class SpringTransactionPolicy
extends Object
implements TransactedPolicy

Wraps the processor in a Spring transaction

Version:
$Revision: 16031 $

Constructor Summary
SpringTransactionPolicy()
          Default constructor for easy spring configuration.
SpringTransactionPolicy(PlatformTransactionManager transactionManager)
           
SpringTransactionPolicy(TransactionTemplate template)
           
 
Method Summary
protected  TransactionErrorHandler createTransactionErrorHandler(RouteContext routeContext, Processor processor, ErrorHandlerBuilder builder)
           
 String getPropagationBehaviorName()
           
 PlatformTransactionManager getTransactionManager()
           
 TransactionTemplate getTransactionTemplate()
           
 void setPropagationBehaviorName(String propagationBehaviorName)
           
 void setTransactionManager(PlatformTransactionManager transactionManager)
           
 void setTransactionTemplate(TransactionTemplate template)
           
 Processor wrap(RouteContext routeContext, Processor processor)
          Wraps any applicable interceptors around the given processor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpringTransactionPolicy

public SpringTransactionPolicy()
Default constructor for easy spring configuration.


SpringTransactionPolicy

public SpringTransactionPolicy(TransactionTemplate template)

SpringTransactionPolicy

public SpringTransactionPolicy(PlatformTransactionManager transactionManager)
Method Detail

wrap

public Processor wrap(RouteContext routeContext,
                      Processor processor)
Description copied from interface: Policy
Wraps any applicable interceptors around the given processor

Specified by:
wrap in interface Policy
Parameters:
routeContext - the route context
processor - the processor to be intercepted
Returns:
either the original processor or a processor wrapped in one or more interceptors

createTransactionErrorHandler

protected TransactionErrorHandler createTransactionErrorHandler(RouteContext routeContext,
                                                                Processor processor,
                                                                ErrorHandlerBuilder builder)

getTransactionTemplate

public TransactionTemplate getTransactionTemplate()

setTransactionTemplate

public void setTransactionTemplate(TransactionTemplate template)

setTransactionManager

public void setTransactionManager(PlatformTransactionManager transactionManager)

getTransactionManager

public PlatformTransactionManager getTransactionManager()

setPropagationBehaviorName

public void setPropagationBehaviorName(String propagationBehaviorName)

getPropagationBehaviorName

public String getPropagationBehaviorName()


Copyright © 2007-2010 IONA Open Source Community. All Rights Reserved.