THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Code Block | ||||
---|---|---|---|---|
| ||||
<xpath resultType="java.lang.String">/foo:person/@id</xpath> |
In @XPath:
Available as of Camel 2.1
Code Block |
---|
@XPath(value = "concat('foo-',//order/name/)", resultType = String.class) String name)
|
Where we use the xpath function concat to prefix the order name with foo-
. In this case we have to specify that we want a String as result type so the concat function works.
Examples
Here is a simple example using an XPath expression as a predicate in a Message Filter
...