The testxpath tool enables you to try xpath expressions against a standard document. The xpath expression will be evaluated against the provided document and the result returned. To use the command, type:
Tool testxpath <sampledocument>
Assume the standard document is the same as that shown in testfuncs.
Enter command:>tool testxpath \smalldoc.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<a>
<top>
<b>one</b>
<b>two</b>
<x>sreg(iwayhome)</x>
</top>
</a>Now enter an xpath expression against the sample document.
xpath->/a/top/b[1]
<superRoot [baseNode]>
<a [baseNode]/>
<top [baseNode]/>
<b [baseNode]>
<functionPredicate [filterInt]>1</functionPredicate>
</b>
</superRoot>
values->'one'
tree-><?xml version="1.0" encoding="ISO-8859-1" ?>
<xpathresult>
<b>one</b>
</xpathresult>
list-><b>one [parent=top]
xpath->| iWay Software |