org.springframework.integration.router
Class AbstractChannelNameResolvingMessageRouter
java.lang.Object
org.springframework.integration.handler.AbstractMessageHandler
org.springframework.integration.router.AbstractMessageRouter
org.springframework.integration.router.AbstractChannelNameResolvingMessageRouter
- All Implemented Interfaces:
- org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.InitializingBean, org.springframework.core.Ordered, MessageHandler
- Direct Known Subclasses:
- AbstractSingleChannelNameRouter, AbstractXPathRouter, HeaderValueRouter, MethodInvokingRouter
public abstract class AbstractChannelNameResolvingMessageRouter
- extends AbstractMessageRouter
- implements org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.InitializingBean
A base class for router implementations that return only the channel name(s)
rather than MessageChannel
instances.
- Author:
- Mark Fisher, Jonas Partner
Fields inherited from interface org.springframework.core.Ordered |
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractChannelNameResolvingMessageRouter
public AbstractChannelNameResolvingMessageRouter()
setChannelResolver
public void setChannelResolver(ChannelResolver channelResolver)
setPrefix
public void setPrefix(java.lang.String prefix)
setSuffix
public void setSuffix(java.lang.String suffix)
setBeanFactory
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
- Specified by:
setBeanFactory
in interface org.springframework.beans.factory.BeanFactoryAware
setIgnoreChannelNameResolutionFailures
public void setIgnoreChannelNameResolutionFailures(boolean ignoreChannelNameResolutionFailures)
afterPropertiesSet
public void afterPropertiesSet()
- Specified by:
afterPropertiesSet
in interface org.springframework.beans.factory.InitializingBean
resolveChannelForName
protected MessageChannel resolveChannelForName(java.lang.String channelName,
Message<?> message)
determineTargetChannels
protected java.util.Collection<MessageChannel> determineTargetChannels(Message<?> message)
- Description copied from class:
AbstractMessageRouter
- Subclasses must implement this method to return the target channels for
a given Message.
- Specified by:
determineTargetChannels
in class AbstractMessageRouter
addToCollection
protected void addToCollection(java.util.Collection<MessageChannel> channels,
java.util.Collection<?> channelIndicators,
Message<?> message)
addChannelFromString
protected void addChannelFromString(java.util.Collection<MessageChannel> channels,
java.lang.String channelName,
Message<?> message)
getChannelIndicatorList
protected abstract java.util.List<java.lang.Object> getChannelIndicatorList(Message<?> message)
- Subclasses must implement this method to return the channel indicators.