Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] RE: XPath support in XOM

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: xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] RE: XPath support in XOM
  • Date: Mon, 10 Jan 2005 15:42:19 -0500

Michael Kay wrote:

If the user controls how many text node objects there are, and if XOM gives
different results depending how many there are, then I'm happy for XPath to
do likewise. I think this is better than ./text()[contains(., "o")]
returning 4 text nodes of which only one contains an "o".

But it doesn't return 4 text nodes. It returns 4 Text objects, which together make up 1 text node. That's a crucial distinction.

Counter-issue: Suppose someone does ./text()[contains(., "cat")] where the first Text is "There is a c" and the second Text is "at named David." Is it really appropriate for that expression to return nothing?

--
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