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

Re: Some clarificatiosn -- RE: [Question] How to do incremental parsing?

  • From: Lars Marius Garshol <larsga@g...>
  • To: "'xml-dev@l...'" <xml-dev@l...>
  • Date: Fri, 06 Jul 2001 15:43:43 +0200

parsing dom4j

* Mousheng Xu
| 
| The problem of SAX is that you will have to write all those tedious
| "startElement", "endElement" stuff 

Getting used to SAX takes a little readjustment of the brain (a
process I personally tend to enjoy), but once you do it is really easy
to write SAX applications. A couple of little utilities also make life
a lot easier.

Other than that it is really no different from writing a DOM
application, where you have to call all those tedious stuff to do what
you want. :-)

| and the parsing never stops!

Throw a SAXException and parsing will stop immediately.

| Some mentioned the row processing feature of dom4j, kXML, SAXON,
| minidom, easydom, and Orchard. Do they read the whole doc into
| memory before parsing anyway, like the DOM lazy eval? 

No. That would entirely defeat these purpose of these processing
modes. Given that you're working with Java I would start by looking at
dom4j and SAXON (in that order).

| If these parsers are based on xerces SAX, the chances are the whole
| doc is read into the memory.

SAXON can use any SAX parser; it uses Ælfred by default. 

I think dom4j is also parser-independent.
 
| * What is "persistent DOM"?

A DOM that accesses a structure stored in a persistent store, rather
than an in-memory object structure.

--Lars M.


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.