org.springframework.integration.xml.router
Class AbstractXPathRouter

java.lang.Object
  extended by org.springframework.integration.handler.AbstractMessageHandler
      extended by org.springframework.integration.router.AbstractMessageRouter
          extended by org.springframework.integration.router.AbstractChannelNameResolvingMessageRouter
              extended by org.springframework.integration.xml.router.AbstractXPathRouter
All Implemented Interfaces:
org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.InitializingBean, org.springframework.core.Ordered, MessageHandler
Direct Known Subclasses:
XPathMultiChannelRouter, XPathSingleChannelRouter

public abstract class AbstractXPathRouter
extends AbstractChannelNameResolvingMessageRouter

Abstract base class for Message Routers that use XPathExpression evaluation to determine channel names.

Author:
Jonas Partner

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
AbstractXPathRouter(java.lang.String expression)
          Create a router that uses an XPath expression with no namespaces.
AbstractXPathRouter(java.lang.String expression, java.util.Map<java.lang.String,java.lang.String> namespaces)
          Create a router that uses an XPath expression.
AbstractXPathRouter(java.lang.String expression, java.lang.String prefix, java.lang.String namespace)
          Create a router uses an XPath expression with one namespace.
AbstractXPathRouter(org.springframework.xml.xpath.XPathExpression expression)
          Create a router that uses the provided XPath expression.
 
Method Summary
protected  XmlPayloadConverter getConverter()
           
protected  org.springframework.xml.xpath.XPathExpression getXPathExpression()
           
 void setConverter(XmlPayloadConverter converter)
          Converter used to convert payloads prior to XPath testing.
 
Methods inherited from class org.springframework.integration.router.AbstractChannelNameResolvingMessageRouter
addChannelFromString, addToCollection, afterPropertiesSet, determineTargetChannels, getChannelIndicatorList, resolveChannelForName, setBeanFactory, setChannelResolver, setIgnoreChannelNameResolutionFailures, setPrefix, setSuffix
 
Methods inherited from class org.springframework.integration.router.AbstractMessageRouter
handleMessageInternal, setDefaultOutputChannel, setResolutionRequired, setTimeout
 
Methods inherited from class org.springframework.integration.handler.AbstractMessageHandler
getOrder, handleMessage, resolveReplyChannel, setOrder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractXPathRouter

public AbstractXPathRouter(java.lang.String expression,
                           java.util.Map<java.lang.String,java.lang.String> namespaces)
Create a router that uses an XPath expression. The expression may contain zero or more namespace prefixes.

Parameters:
expression -
namespaces -

AbstractXPathRouter

public AbstractXPathRouter(java.lang.String expression,
                           java.lang.String prefix,
                           java.lang.String namespace)
Create a router uses an XPath expression with one namespace. For example, expression='/ns1:[email protected]' prefix='ns1' namespace='www.example.org'

Parameters:
expression -
prefix -
namespace -

AbstractXPathRouter

public AbstractXPathRouter(java.lang.String expression)
Create a router that uses an XPath expression with no namespaces. For example [email protected]'

Parameters:
expression -

AbstractXPathRouter

public AbstractXPathRouter(org.springframework.xml.xpath.XPathExpression expression)
Create a router that uses the provided XPath expression.

Parameters:
expression -
Method Detail

getConverter

protected XmlPayloadConverter getConverter()

setConverter

public void setConverter(XmlPayloadConverter converter)
Converter used to convert payloads prior to XPath testing.

Parameters:
converter -

getXPathExpression

protected org.springframework.xml.xpath.XPathExpression getXPathExpression()