org.mule.processor.chain
Class InterceptingChainLifecycleWrapper

java.lang.Object
  extended by org.mule.processor.AbstractInterceptingMessageProcessorBase
      extended by org.mule.processor.AbstractInterceptingMessageProcessor
          extended by org.mule.processor.chain.AbstractMessageProcessorChain
              extended by org.mule.processor.chain.InterceptingChainLifecycleWrapper
All Implemented Interfaces:
AnnotatedObject, FlowConstructAware, MuleContextAware, Disposable, Initialisable, Lifecycle, Startable, Stoppable, NamedObject, InterceptingMessageProcessor, MessageProcessor, MessageProcessorChain, MessageSource, EndpointAware

public class InterceptingChainLifecycleWrapper
extends AbstractMessageProcessorChain

Builder needs to return a composite rather than the first MessageProcessor in the chain. This is so that if this chain is nested in another chain the next MessageProcessor in the parent chain is not injected into the first in the nested chain.


Field Summary
 
Fields inherited from class org.mule.processor.chain.AbstractMessageProcessorChain
log, name, processors
 
Fields inherited from class org.mule.processor.AbstractInterceptingMessageProcessorBase
logger, muleContext, next, notificationHandler
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Startable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Stoppable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Disposable
PHASE_NAME
 
Fields inherited from interface org.mule.api.AnnotatedObject
PROPERTY_NAME
 
Constructor Summary
InterceptingChainLifecycleWrapper(MessageProcessorChain chain, List<MessageProcessor> processors, String name)
           
 
Method Summary
protected  MuleEvent doProcess(MuleEvent event)
           
 List<MessageProcessor> getMessageProcessors()
           
 String getName()
          Gets the name of the object
 MuleEvent process(MuleEvent event)
          Invokes the MessageProcessor.
 void setMuleContext(MuleContext context)
           
 
Methods inherited from class org.mule.processor.chain.AbstractMessageProcessorChain
dispose, initialise, setEndpoint, setFlowConstruct, start, stop, toString
 
Methods inherited from class org.mule.processor.AbstractInterceptingMessageProcessorBase
getAnnotation, getAnnotations, getListener, getMuleContext, isEventValid, processNext, setAnnotations, setListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mule.api.source.MessageSource
setListener
 

Constructor Detail

InterceptingChainLifecycleWrapper

public InterceptingChainLifecycleWrapper(MessageProcessorChain chain,
                                         List<MessageProcessor> processors,
                                         String name)
Method Detail

getMessageProcessors

public List<MessageProcessor> getMessageProcessors()
Specified by:
getMessageProcessors in interface MessageProcessorChain
Overrides:
getMessageProcessors in class AbstractMessageProcessorChain

getName

public String getName()
Description copied from interface: NamedObject
Gets the name of the object

Specified by:
getName in interface NamedObject
Overrides:
getName in class AbstractMessageProcessorChain
Returns:
the name of the object

doProcess

protected MuleEvent doProcess(MuleEvent event)
                       throws MuleException
Specified by:
doProcess in class AbstractMessageProcessorChain
Throws:
MuleException

setMuleContext

public void setMuleContext(MuleContext context)
Specified by:
setMuleContext in interface MuleContextAware
Overrides:
setMuleContext in class AbstractInterceptingMessageProcessorBase

process

public MuleEvent process(MuleEvent event)
                  throws MuleException
Description copied from interface: MessageProcessor
Invokes the MessageProcessor.

Specified by:
process in interface MessageProcessor
Overrides:
process in class AbstractMessageProcessorChain
Parameters:
event - MuleEvent to be processed
Returns:
optional response MuleEvent
Throws:
MuleException


Copyright © 2003-2012 MuleSoft, Inc.. All Rights Reserved.