W3C home > Mailing lists > Public > public-qt-comments@w3.org > June 2002

Re: Comments on the XPath data model, from a DOM perspective.

From: Peter Fankhauser <fankp@darmstadt.gmd.de>
Date: Thu, 13 Jun 2002 03:38:51 -0400 (EDT)
To: <public-qt-comments@w3.org>
Cc: <rayw@netscape.com>, <pcotton@microsoft.com>, <lehti@ipsi.fhg.de>
Message-ID: <000401c212ac$1bc3b200$249c0c8d@pcpotato>




Hello Ray Withmer,

This is in response to your comments on the
XPath datamodel from the DOM perspective
(http://lists.w3.org/Archives/Public/www-xml-query-comments/2002Apr/0000
.html)

At Fraunhofer IPSI we are implementing XQuery, including XPath 2.0
on the basis of the Xerces DOM 2 implementation
(see http://ipsi.fhg.de/oasys/projects/ipsi-xq/index_e.html
and http://ipsi.fhg.de/oasys/projects/ipsi-xq/overview_e.html
for a short description of the underlying architecture).

In the most recent version, we have even wrapped the DOM-interface
with a thin layer of XQuery/XPath-Datamodel classes, to allow
for plugging in alternative XML-storage models. 

Generally, the Xerces DOM turns out to be a suitable basis for
the XQuery datamodel. Here are the main problems that we encountered
and their workaround.

(1) Xerces DOM 2 has no (XML-Schema) type annotations. We used
    Xerces' extensibility mechanism of user defined annotations to
    represent them. We will have a look at the DOM 3 Schema module.
(2) Xerces DOM 2 does not directly support node-ids with document
    order.
    Again we represent them by means of user defined annotations.
(3) Some expressions of XQuery return heterogeneous sequences of nodes
    and simple values (aka items). We have implemented such sequences in
    a proprietary way with one level of indirection (pointers to nodes
    and simple values). Because such sequences only occur for interim
XQuery results,
    and never within a constructed element, this is appropriate
    in the IPSI-XQ architecture, which works on the XQuery/XPath
    Datamodel abstraction. However, for applications wanting to
    operate directly on interim XQuery results (e.g. via a cursor on
    DOM-"items" rather than DOM-"nodes"), this indeed can mean an
additional
    complication.

Altogether, the DOM and the XQuery/XPath datamodel are not as far from
each other as may seem at first sight. However, wrapping the DOM-API
with
a (thin) XQuery/XPath abstraction has allowed us to even more closely
align
our implementation with the XQuery working drafts.

Hope this clarifies,

Peter Fankhauser
Infonyte GmbH
(on leave from Fraunhofer IPSI)
Received on Thursday, 13 June 2002 04:30:38 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:45:09 UTC