[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: helper classes for SAX

  • From: "Michael Kay" <M.H.Kay@e...>
  • To: "Don Park" <donpark@q...>, "Peter Murray-Rust" <peter@u...>, "xml-dev Mailing List" <xml-dev@i...>
  • Date: Wed, 25 Feb 1998 11:37:25 -0000

helper classes
>"Should we add helper classes to SAX?"
>
I have written a package on top of SAX which I hope to publish soon - I need
to get it past some corporate processes


I wrote it because I found I was doing the same thing repeatedly in a number
of SAX applications. I call the package SAXON (sorry), and it provides the
following services:

- allows you to register a handler for a particular element type (or a
particular element type in the context of a parent element type). The
handler can supply methods to process the element start or end, the
character data or ignorable white space in the element, or the start or end
of a consecutive group of one or more elements (cf. XSL)
- provides you with context information about the element; in particular,
its parent and ancestors, their attributes, and also their elder sibling
elements.
- allows you to associate user data with an element, so for example your
start-element method can pass data to the corresponding end-element method
- allows you to associate an output "bucket" with an element type, so that
all output for that element and its children (unless otherwise specified)
goes into that bucket. Useful for splitting documents and for limited
re-ordering of elements
- allows multiple handlers per element type
- includes some standard element handlers for doing HTML rendition, for
generating automatic numbering, etc

Although I'm not in a position to go public with it yet, I'll be happy to
share the current state of development with any individual who wants to
collaborate.

I do realise of course that some of these facilities can be achieved by
using the DOM instead of an event-based parser, and there is a world of
stuff in JUMBO that I haven't expored yet. I was trying to add value to SAX
without going heavyweight, which of course is a delicate line to tread.

Regards, Mike Kay
ICL




xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i...
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@i... the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@i... the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@i...)


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.