[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [xml-dev] DOM or SAX: Sense and Sensibility
> From: Michael Kay [mailto:michael.h.kay@ntlworld.com]
> Sent: Thursday, November 08, 2001 1:25 AM
> To: 'Michael Brennan'; 'bob mcwhirter'; xml-dev@lists.xml.org
> Subject: RE: [xml-dev] DOM or SAX: Sense and Sensibility
>
>
> > Is anyone working on any XSLT implementations that work with
> > Jaxen? That
> > would be very cool.
>
> In recent releases of Saxon I've been following a similar
> direction, of
> making the XPath engine able to work with multiple document
> representations.
> The current release includes a JDOM driver to illustrate the
> principle.
Cool! I'll have to take a look at that.
> Incidentally, some of the things DOM4J and Jaxen are doing
> look very similar
> to the original "Java only" Saxon library before it changed
> direction to
> become an XSLT engine.
I did some playing with SAXON about a year and a half ago. I experimented
with a data-binding mechanism that leveraged this capability of SAXON --
implementing ElementHandlers that fired off when certain XPath expressions
were matched. At the time, I didn't follow through with it. I changed course
and ended up implementing something that looks very much like RelaxNGCC
(except without the full schema language -- it used a proprietary language
that resembled a simple subset of TREX). The main impetus for the change in
course was to let developers use a more top-down structured approach rather
than the pattern-matching approach. I find myself gravitating back to the
pattern-matching approach, although I also like the approach of giving the
option to a developer of annotating a schema with the necessary logic, and
letting the tool infer the necessary matching pattern from the context in
the schema. I think that would be an interesting approach for supporting
XSLT templates, too.