OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   Re: [xml-dev] SAX XPath Filter

[ Lists Home | Date Index | Thread Index ]

Bart Swennenhuis wrote:


> 2. Of course I would like to improve the XPath support in the
>    QueryTransformerHandler. But it is very tricky to write this component.
>    I cannot find any code that I can use, but it is very unlikely that this
>    idea is new.
>    So I am looking for an org.xml.sax.ContentHandler that filters data from
>    a SAX stream, using XPath expressions.

This has come up before. I'd love to see a component like this. You'd
have to restrict what can be selected in expressions, of course (e.g. no
predicates selecting along the child axis), and have to maintain some
state from previous SAX events to help with pattern matching.

You may want to check out STX [1]. It's not Jaxen-based, though, and
it's still at a pretty early state. I've thought it would be cool to
have a Jaxen-based toolkit for supporting processors based upon the
Schema Adjunct Framework [2] and/or Schematron [3]. Ideally, these
should support SAX-based processing (with restrictions on patterns) or
document model-based processing using any Jaxen-supported model. I'm
hoping to get around to writing something like this, eventually.

Ah, the fun one can have with Jaxen. The opportunities are boundless.

[1] http://www.gingerall.cz/stx/index.html
[2] http://www.tibco.com/products/extensibility/saf/exec-summary/
[3] http://www.ascc.net/xml/resource/schematron/schematron.html

  • References:


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS