Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] XOM 1.1: XPath

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: Elliotte Harold <elharo AT metalab.unc.edu>
  • To: Michael Kay <mike AT saxonica.com>
  • Cc: "'Bradley S. Huffman'" <hip AT a.cs.okstate.edu>, xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] XOM 1.1: XPath
  • Date: Sat, 08 Jan 2005 09:03:37 -0500

Michael Kay wrote:

You need to think in terms of two views: the XOM view, and the XPath view.
The merged node appears only in the XPath view, it should never be visible
in the XOM view. An XPath expression that finds the merged node should
return the first corresponding text node back across the API, it should not
make the merged node visible. This way, both views of the tree are
consistent in their own terms.

Agreed, except that it should return all the corresponding text nodes back across the API, not just the first one. That is if XPath text node A is made up of XOM Text objects t1, t2, and t3, then an XPath expressions that matches text node A will return a Nodes object containing t1, t2, and t3 in their original order.

--
Elliotte Rusty Harold elharo AT metalab.unc.edu
XML in a Nutshell 3rd Edition Just Published!
http://www.cafeconleche.org/books/xian3/
http://www.amazon.com/exec/obidos/ISBN=0596007647/cafeaulaitA/ref=nosim




Archive powered by MHonArc 2.6.24.

Top of Page