@ComponentProfile(summary="MessageAggregator that appends all payloads to the original", since="3.9.1") public class AppendingMessageAggregator extends MessageAggregatorImpl
MessageAggregator
that just appends payloads.
This simply iterates over each of the messages; and appends their payloads to the original message. No checking is done of the payloads; it is a raw append using a stream copy.
In the adapter configuration file this class is aliased as appending-message-aggregator which is the preferred alternative to the fully qualified classname when building your configuration.
log
Constructor and Description |
---|
AppendingMessageAggregator() |
Modifier and Type | Method and Description |
---|---|
void |
aggregate(AdaptrisMessage orig,
java.lang.Iterable<AdaptrisMessage> msgs)
Joins multiple
AdaptrisMessage s into a single AdaptrisMessage
objects. |
void |
joinMessage(AdaptrisMessage orig,
java.util.Collection<AdaptrisMessage> toAggregate)
Joins multiple
AdaptrisMessage s into a single AdaptrisMessage
objects. |
filter, filter, getFilterCondition, getOverwriteMetadata, getRetainFilterExceptionsMessages, overwriteMetadata, overwriteMetadata, setFilterCondition, setOverwriteMetadata, setRetainFilterExceptionsMessages, withOverwriteMetadata
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
collect
public void joinMessage(AdaptrisMessage orig, java.util.Collection<AdaptrisMessage> toAggregate) throws CoreException
MessageAggregator
Joins multiple AdaptrisMessage
s into a single AdaptrisMessage
objects. Preservation of metadata is down to the implementation.
orig
- the msg to insert all the messages intotoAggregate
- the list of messages to join.CoreException
- wrapping any other exceptionpublic void aggregate(AdaptrisMessage orig, java.lang.Iterable<AdaptrisMessage> msgs) throws CoreException
MessageAggregator
Joins multiple AdaptrisMessage
s into a single AdaptrisMessage
objects. Preservation of metadata is down to the implementation.
orig
- the original messagemsgs
- the list of messages to join.CoreException