Most mediation primitives have properties that are specified using an XPath 1.0 expression; for example the root property takes an XPath 1.0 expression which specifies the part of the message that is available to the primitive for processing. The XPath Expression Builder provides a tree view of the message, and allows you to visually build an XPath 1.0 expression or to manually specify an XPath 1.0 expression.
You can use XPath 1.0 expressions in your flow to access specific parts of a message. You can then process the message; for example you can transform, filter or retrieve values from a message,
The input message is displayed in the XPath Expression Builder's schema viewer. Wire the primitive's input terminal before you launch the XPath Expression Builder, so that the complete message is available in the schema viewer.
The
XPath Expression Builder is typically launched by clicking the Custom
XPath button in the details properties view of a node or mediation
primitive. For properties that are set in a table, click on the end of an
expression to see the button that launches the XPath Expression
Builder.
The Schema Viewer section provides a tree view of the input message. To visually build your XPath expression follow these steps:
The complete XPath expression is shown under the title Full XPath Expression:
You can enter an XPath expression manually by selecting the Override check box and typing your expression. Or, if you want to build complex expressions, you can begin by creating an expression using the expression builder, then select Override to edit it.
Note: The syntax of your XPath 1.0 expression will not be checked.
The following example shows the relationship between a business object in the interface and an XPath condition in the XPath Expression Builder.
An Employee business object is created containing
four fields: id, isManager, name, and department.
The Employee business object is used as the input and output message types for the EmployeeInterface.
The following picture shows the example XPath 1.0 expression in the XPath Expression Builder:
See http://www.w3.org/TR/xpath for more information on XPath 1.0.