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: "Bradley S. Huffman" <hip AT cs.okstate.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 09:34:49 -0600

"Michael Kay" writes:

> In this case I think that Elliotte's solution of mapping one XPath text
> node
> in the XPath result to all four corresponding XOM text nodes in the XOM
> result is still probably the best option; at any rate, I haven't seen a
> better one.

I thought that also, but as Hallvard also point out, even if you're not
using XPath, for robustness your still going to have to take adjacent text
nodes into account. So I'd say include all text nodes in the XPath result
(unwrapped), document the pitfalls with adjacent text nodes (both in the
XPath javadoc and in ParentNode javadoc), and let the user get use to dealing
with it. They are going to have to anyway.

Brad




Archive powered by MHonArc 2.6.24.

Top of Page