org.apache.camel.impl
Class DefaultRouteContext

java.lang.Object
  extended by org.apache.camel.impl.DefaultRouteContext
All Implemented Interfaces:
RouteContext

public class DefaultRouteContext
extends Object
implements RouteContext

The context used to activate new routing rules

Version:
$Revision: 42218 $

Constructor Summary
DefaultRouteContext(CamelContext camelContext)
          Only used for lazy construction from inside ExpressionType
DefaultRouteContext(RouteType route, FromType from, Collection<Route> routes)
           
 
Method Summary
 void addEventDrivenProcessor(Processor processor)
           
 void addInterceptStrategy(InterceptStrategy interceptStrategy)
           
 void commit()
          Lets complete the route creation, creating a single event driven route for the current from endpoint with any processors required
 Processor createProceedProcessor()
           
 Processor createProcessor(ProcessorType node)
           
 CamelContext getCamelContext()
          Gets the CamelContext
 Endpoint<? extends Exchange> getEndpoint()
           
 FromType getFrom()
           
 List<InterceptStrategy> getInterceptStrategies()
          This method retrieves the InterceptStrategy instances this route context.
 RouteType getRoute()
           
 void intercept(Intercept interceptor)
           
<T> T
lookup(String name, Class<T> type)
          lookup an object by name and type
 Endpoint<? extends Exchange> resolveEndpoint(String uri)
          Resolves an endpoint from the URI
 Endpoint<? extends Exchange> resolveEndpoint(String uri, String ref)
          Resolves an endpoint from either a URI or a named reference
 void setInterceptStrategies(List<InterceptStrategy> interceptStrategies)
          This method sets the InterceptStrategy instances on this route context.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultRouteContext

public DefaultRouteContext(RouteType route,
                           FromType from,
                           Collection<Route> routes)

DefaultRouteContext

public DefaultRouteContext(CamelContext camelContext)
Only used for lazy construction from inside ExpressionType

Method Detail

getEndpoint

public Endpoint<? extends Exchange> getEndpoint()
Specified by:
getEndpoint in interface RouteContext

getFrom

public FromType getFrom()
Specified by:
getFrom in interface RouteContext

getRoute

public RouteType getRoute()
Specified by:
getRoute in interface RouteContext

getCamelContext

public CamelContext getCamelContext()
Description copied from interface: RouteContext
Gets the CamelContext

Specified by:
getCamelContext in interface RouteContext

createProcessor

public Processor createProcessor(ProcessorType node)
                          throws Exception
Specified by:
createProcessor in interface RouteContext
Throws:
Exception

resolveEndpoint

public Endpoint<? extends Exchange> resolveEndpoint(String uri)
Description copied from interface: RouteContext
Resolves an endpoint from the URI

Specified by:
resolveEndpoint in interface RouteContext

resolveEndpoint

public Endpoint<? extends Exchange> resolveEndpoint(String uri,
                                                    String ref)
Description copied from interface: RouteContext
Resolves an endpoint from either a URI or a named reference

Specified by:
resolveEndpoint in interface RouteContext

lookup

public <T> T lookup(String name,
                    Class<T> type)
Description copied from interface: RouteContext
lookup an object by name and type

Specified by:
lookup in interface RouteContext

commit

public void commit()
Description copied from interface: RouteContext
Lets complete the route creation, creating a single event driven route for the current from endpoint with any processors required

Specified by:
commit in interface RouteContext

addEventDrivenProcessor

public void addEventDrivenProcessor(Processor processor)
Specified by:
addEventDrivenProcessor in interface RouteContext

intercept

public void intercept(Intercept interceptor)
Specified by:
intercept in interface RouteContext

createProceedProcessor

public Processor createProceedProcessor()
Specified by:
createProceedProcessor in interface RouteContext

getInterceptStrategies

public List<InterceptStrategy> getInterceptStrategies()
Description copied from interface: RouteContext
This method retrieves the InterceptStrategy instances this route context.

Specified by:
getInterceptStrategies in interface RouteContext
Returns:
InterceptStrategy

setInterceptStrategies

public void setInterceptStrategies(List<InterceptStrategy> interceptStrategies)
Description copied from interface: RouteContext
This method sets the InterceptStrategy instances on this route context.

Specified by:
setInterceptStrategies in interface RouteContext

addInterceptStrategy

public void addInterceptStrategy(InterceptStrategy interceptStrategy)
Specified by:
addInterceptStrategy in interface RouteContext


Copyright © 2008 IONA Open Source Community. All Rights Reserved.