public abstract class AbstractMessageSequenceSplitter extends AbstractInterceptingMessageProcessor implements MuleContextAware
MuleMessage
splitter, that converts its payload
in a MessageSequence
, and process each element of it.
Implementations must implement splitMessageIntoSequence(MuleEvent)
and determine how
the message is split.
EIP Reference: http://www .eaipatterns.com/Sequencer.html
AbstractSplitter
Modifier and Type | Field and Description |
---|---|
protected int |
batchSize |
protected String |
counterVariableName |
protected CorrelationMode |
enableCorrelation |
protected MessageInfoMapping |
messageInfoMapping |
protected MuleContext |
muleContext |
protected RouterResultsHandler |
resultsHandler |
logger, next, notificationHandler
PROPERTY_NAME
Constructor and Description |
---|
AbstractMessageSequenceSplitter() |
Modifier and Type | Method and Description |
---|---|
protected boolean |
isSplitRequired(MuleEvent event) |
MuleEvent |
process(MuleEvent event)
Invokes the MessageProcessor.
|
protected List<MuleEvent> |
processParts(MessageSequence<?> seq,
MuleEvent originalEvent) |
void |
setBatchSize(int batchSize)
Split the elements in groups of the specified size
|
void |
setCounterVariableName(String counterVariableName) |
void |
setEnableCorrelation(CorrelationMode enableCorrelation) |
void |
setMessageInfoMapping(MessageInfoMapping messageInfoMapping) |
void |
setMuleContext(MuleContext context) |
protected abstract MessageSequence<?> |
splitMessageIntoSequence(MuleEvent event)
Converts the event into a
MessageSequence that will retrieve each of
the event elements |
addMessageProcessorPathElements, getAnnotation, getAnnotations, getListener, getMuleContext, isEventValid, processNext, setAnnotations, setListener, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
setListener
protected MuleContext muleContext
protected RouterResultsHandler resultsHandler
protected CorrelationMode enableCorrelation
protected MessageInfoMapping messageInfoMapping
protected int batchSize
protected String counterVariableName
public final MuleEvent process(MuleEvent event) throws MuleException
MessageProcessor
process
in interface MessageProcessor
event
- MuleEvent to be processedMuleException
protected boolean isSplitRequired(MuleEvent event)
protected abstract MessageSequence<?> splitMessageIntoSequence(MuleEvent event) throws MuleException
MessageSequence
that will retrieve each of
the event elementsevent
- the event to splitMuleException
protected List<MuleEvent> processParts(MessageSequence<?> seq, MuleEvent originalEvent) throws MuleException
MuleException
public void setEnableCorrelation(CorrelationMode enableCorrelation)
public void setMuleContext(MuleContext context)
setMuleContext
in interface MuleContextAware
setMuleContext
in class AbstractInterceptingMessageProcessorBase
public void setMessageInfoMapping(MessageInfoMapping messageInfoMapping)
public void setBatchSize(int batchSize)
public void setCounterVariableName(String counterVariableName)
Copyright © 2003–2015 MuleSoft, Inc.. All rights reserved.