Constructing the Node-Test Portion of a Location Step
The node-test portion of a location step identifies the type of node(s), or the specific node(s), which make up the baseline collection of nodes from which to gather possible matches. It takes three possible forms:
- Use a node name to select nodes with that name.
- Use a node type, followed by empty parentheses, (), to select nodes of that type. The following node types are available:
comment()selects element nodes;text()selects attribute nodes;processing-instruction()selects processing instruction nodes;- and
node()selects nodes of any kind.
- Use
processing-instruction("target")to select processing instructions with a particular target.
