Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] XPath Data Model Mapping

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: John Cowan <jcowan AT reutershealth.com>
  • To: Elliotte Harold <elharo AT metalab.unc.edu>
  • Cc: xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] XPath Data Model Mapping
  • Date: Mon, 17 Jan 2005 12:09:02 -0500

Elliotte Harold scripsit:
> The XPath support is coming together faster than I expected. I've
> written up a summary of the impedance mismatches between XOM and XPath:
> namespace nodes, rootless documents, adjacent text nodes, etc., and how
> XOM addresses these:
>
> http://www.xom.nu/xpath.xhtml

I think this is Oll Korrect except for the continuing inability to represent
distinct adjacent XPath text nodes in the result. This means, for instance,
that
counting the XPath nodes that match some criterion gives different results
inside an XPath predicate and in Java.

I like the idea of a private subclass of Text. If you add a Nodes expose()
method to Text which just wraps the Text in a Nodes object, then in the
subclass this can return the multiple adjacent Text objects which constitute
it.
This allows the result to be treated as a Text or as multiple Texts, depending
on what's most useful for the user.

--
A rabbi whose congregation doesn't want John Cowan
to drive him out of town isn't a rabbi, http://www.ccil.org/~cowan
and a rabbi who lets them do it jcowan AT reutershealth.com
isn't a man. --Jewish saying http://www.reutershealth.com




Archive powered by MHonArc 2.6.24.

Top of Page