Mashups in EMML : Writing Mashups in EMML : Adding Metadata to Mashups : <presto:macro-meta> : <xpath>
<xpath>
The effect of this metadata varies based on where it is used:
*When used inside <presto:type>, this is optional configuration that defines the behavior of the Path Selection list for this property. By default, users can assign any block property dynamically using the Path Selection list.
You may use this metadata element to prevent users from entering literal values for a property and limit the choices available in the Path Selection list to a single document or a specific branch of nodes within that document. See Limit Dynamic Choices and Forbid Literal Entries for details.
*When type="path" in <presto:type>, you may also use this metadata element to limit the types of nodes that user can choose in the Path Selection list. In this case, the block property is assigned the XPath expression for the selected node rather than the actual value of the selected node. See Get the Chosen Path as Text for details.
*When used inside <presto:list>, this metadata defines the path to obtain a dynamic set of valid values for this list. See Dynamic List Values from a Macro Input Parameter for details.
Can Contain
Empty
Allowed In
Attributes
Name
Required
Description
usage
Wires automatically limits user choices from block results in the Path Selection list based on the datatype of the macro input parameter. For input parameters with simple datatypes, for example, Wires only allows users to select simple nodes, also know as leaf nodes.
When <presto:xpath> is a child of <presto:type datatype="path">, automatic detection is not possible. This attribute allows you to control the types of nodes that users may select in that case:
*array = users may select only repeating nodes, simple (with data) or complex (with children)
*branch = users may select only complex nodes with children, either a single node or repeating nodes
*leaf = users may select only a single simple node with data or a repeating simple node
*path = users may select any type of node
*If omitted = users may select any type of node
limitTo
Yes
Limits the choices presented to users in thePath Selection list to nodes in a specific document-type input parameter, and optionally nodes within a specific path in that document.
When <presto:xpath> is defined as a child of <presto:list>, this attribute identifies a document-type input parameter, and optional path within that document, that provides the valid values for the list.
Copyright © 2006-2015 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback