Class BooleanTestXPathMessageSelector
java.lang.Object
org.springframework.integration.xml.selector.AbstractXPathMessageSelector
org.springframework.integration.xml.selector.BooleanTestXPathMessageSelector
- All Implemented Interfaces:
GenericSelector<Message<?>>
,MessageSelector
Boolean XPath testing
MessageSelector
.
Requires an XPathExpression
which can be evaluated using XPathExpression.evaluateAsBoolean(Node)
.
Supports payloads of type Document
or String
.- Author:
- Jonas Partner, Gary Russell
-
Constructor Summary
ConstructorDescriptionBooleanTestXPathMessageSelector
(String expression) Create a boolean testing XPathMessageSelector
with no namespace support.BooleanTestXPathMessageSelector
(String expression, String prefix, String namespace) Create a boolean testing XPathMessageSelector
supporting a single namespace.BooleanTestXPathMessageSelector
(String expression, Map<String, String> namespaces) Create a boolean testing XPathMessageSelector
supporting multiple namespaces.BooleanTestXPathMessageSelector
(XPathExpression expression) Create a boolean testing XPathMessageSelector
using the providedXPathExpression
. -
Method Summary
Methods inherited from class org.springframework.integration.xml.selector.AbstractXPathMessageSelector
getConverter, getXPathExpresion, setConverter
-
Constructor Details
-
BooleanTestXPathMessageSelector
Create a boolean testing XPathMessageSelector
supporting multiple namespaces.- Parameters:
expression
- XPath expression as a Stringnamespaces
- Map of namespaces where the keys are namespace prefixes
-
BooleanTestXPathMessageSelector
Create a boolean testing XPathMessageSelector
supporting a single namespace.- Parameters:
expression
- XPath expression as a Stringprefix
- namespace prefixnamespace
- namespace URI
-
BooleanTestXPathMessageSelector
Create a boolean testing XPathMessageSelector
with no namespace support.- Parameters:
expression
- XPath expression as a String
-
BooleanTestXPathMessageSelector
Create a boolean testing XPathMessageSelector
using the providedXPathExpression
.- Parameters:
expression
- XPath expression
-
-
Method Details
-
accept
Return true if theXPathExpression
evaluates totrue
-