org.springframework.integration.router
Class AbstractSingleChannelRouter

java.lang.Object
  extended by org.springframework.integration.handler.AbstractMessageHandler
      extended by org.springframework.integration.router.AbstractMessageRouter
          extended by org.springframework.integration.router.AbstractSingleChannelRouter
All Implemented Interfaces:
org.springframework.core.Ordered, MessageHandler
Direct Known Subclasses:
ErrorMessageExceptionTypeRouter, PayloadTypeRouter

public abstract class AbstractSingleChannelRouter
extends AbstractMessageRouter

Extends AbstractMessageRouter to support router implementations that always return a single MessageChannel instance (or null).

Author:
Mark Fisher

Field Summary
 
Fields inherited from class org.springframework.integration.handler.AbstractMessageHandler
logger
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
AbstractSingleChannelRouter()
           
 
Method Summary
protected abstract  MessageChannel determineTargetChannel(Message<?> message)
          Subclasses must implement this method to return the target channel.
protected  java.util.Collection<MessageChannel> determineTargetChannels(Message<?> message)
          Subclasses must implement this method to return the target channels for a given Message.
 
Methods inherited from class org.springframework.integration.router.AbstractMessageRouter
handleMessageInternal, setDefaultOutputChannel, setResolutionRequired, setTimeout
 
Methods inherited from class org.springframework.integration.handler.AbstractMessageHandler
getOrder, handleMessage, setOrder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractSingleChannelRouter

public AbstractSingleChannelRouter()
Method Detail

determineTargetChannels

protected final 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

determineTargetChannel

protected abstract MessageChannel determineTargetChannel(Message<?> message)
Subclasses must implement this method to return the target channel.