[jdom-interest] Using NanoXML and JDOM

Paul Libbrecht paul at mathweb.org
Mon Oct 1 15:01:06 PDT 2001


Actually, I'd highly recommend to get rid of Xerces as soon as you're no 
more interested into its (probably powerful) flexibility...

A candid benchmark happened to me as follows: to parse the same set of 40 
files exposing DOM using Xerces takes the double of the time as parsing 
the same files fire SAX-events to JDOM using Xerces which, in turn, takes 
the double of the time to using Michael Kay of ICL's revisited AElfred 
parser to fire SAX events.
Oh, and for the comparison, the JDOM docs loaded in RAM take the half of 
the memory of the DOM-exposing objects of Xerces for the same collection 
of files.

So if you are interested only at the JDOM objects, do, do, do, change 
parser.

Michael Kay's revisited AElfred parser has a BSD license and, this is 
probably why you're interested at it, is extremely small: 29 Kb compressed.
What's greatest, it holds in two source files !
More info from his Saxon page (the parser is included in it):
	http://users.iclway.co.uk/mhkay/saxon/

Aside of not supporting DOM, I'd urge JDOM gurus to consider including it.
This would be even more friendly as he has made glue code to accept JDOM 
documents as transformation source (which is, I believe, an optimal way).

Paul


On Mercredi, septembre 19, 2001, at 04:01  PM, Sebastien Pierre wrote:

> Hi all,
>
> Is it possible to use another SAX parser than the ones that comes with
> JDOM?
> I was thinking about NanoXML.




More information about the jdom-interest mailing list