public abstract class AbstractSelectiveRouter extends AbstractAnnotatedObject implements SelectiveRouter, RouterStatisticsRecorder, Lifecycle, FlowConstructAware, MuleContextAware, MessageProcessorContainer
PHASE_NAME
PHASE_NAME
PHASE_NAME
PHASE_NAME
PROPERTY_NAME
Constructor and Description |
---|
AbstractSelectiveRouter() |
Modifier and Type | Method and Description |
---|---|
void |
addMessageProcessorPathElements(MessageProcessorPathElement pathElement)
Add the child nodes to the path element tree.
|
void |
addRoute(MessageProcessor processor,
Filter filter) |
void |
dispose()
A lifecycle method where implementor should free up any resources.
|
List<MessageProcessorFilterPair> |
getConditionalMessageProcessors() |
RouterStatistics |
getRouterStatistics() |
void |
initialise()
Method used to perform any initialisation work.
|
MuleEvent |
process(MuleEvent event)
Invokes the MessageProcessor.
|
void |
removeRoute(MessageProcessor processor) |
protected abstract Collection<MessageProcessor> |
selectProcessors(MuleEvent event) |
void |
setDefaultRoute(MessageProcessor processor) |
void |
setFlowConstruct(FlowConstruct flowConstruct) |
void |
setMuleContext(MuleContext context) |
void |
setRouterStatistics(RouterStatistics routerStatistics) |
void |
start() |
void |
stop() |
String |
toString() |
void |
updateRoute(MessageProcessor processor,
Filter filter) |
getAnnotation, getAnnotations, setAnnotations
public void setFlowConstruct(FlowConstruct flowConstruct)
setFlowConstruct
in interface FlowConstructAware
public void setMuleContext(MuleContext context)
setMuleContext
in interface MuleContextAware
public void initialise() throws InitialisationException
Initialisable
InitialisationException
should be thrown,
causing the Mule instance to shutdown. If the error is recoverable, say by
retrying to connect, a RecoverableException
should be thrown.
There is no guarantee that by throwing a Recoverable exception that the Mule
instance will not shut down.initialise
in interface Initialisable
InitialisationException
- if a fatal error occurs causing the Mule instance to shutdownRecoverableException
- if an error occurs that can be recovered frompublic void start() throws MuleException
start
in interface Startable
MuleException
public void stop() throws MuleException
stop
in interface Stoppable
MuleException
public void dispose()
Disposable
dispose
in interface Disposable
public void addRoute(MessageProcessor processor, Filter filter)
addRoute
in interface SelectiveRouter
public void removeRoute(MessageProcessor processor)
removeRoute
in interface SelectiveRouter
public void updateRoute(MessageProcessor processor, Filter filter)
updateRoute
in interface SelectiveRouter
public void setDefaultRoute(MessageProcessor processor)
setDefaultRoute
in interface SelectiveRouter
public MuleEvent process(MuleEvent event) throws MuleException
MessageProcessor
process
in interface MessageProcessor
event
- MuleEvent to be processedMuleException
protected abstract Collection<MessageProcessor> selectProcessors(MuleEvent event)
public List<MessageProcessorFilterPair> getConditionalMessageProcessors()
public RouterStatistics getRouterStatistics()
public void setRouterStatistics(RouterStatistics routerStatistics)
setRouterStatistics
in interface RouterStatisticsRecorder
public void addMessageProcessorPathElements(MessageProcessorPathElement pathElement)
MessageProcessorContainer
addMessageProcessorPathElements
in interface MessageProcessorContainer
Copyright © 2003–2018 MuleSoft, Inc.. All rights reserved.