[jdom-interest] Re: Patches for JDOMSource and JDOMResult (was: Re: [jdom-interest] JDOMResult silently absorbs document fragments)

Markus Pallo pallo at dig.de
Thu Aug 29 00:13:49 PDT 2002

with the new Xerces version from the repository 2.1.0 it works, looks like 
they fixed the Parser.

I will patch now my JDOM version with your fix and hope it will be included 
next time.

Thanks for your time.


On Thursday 22 August 2002 10:36, Laurent Bihanic wrote:
> Markus Pallo wrote:
> > i continued now my tests. It looks like xerces is unable to parse the
> > document fragment which is created in SAXOutputter dtdEvents(Document
> > document). Also caucho sax parser tells unable to parse Document.
> > The root element is missing.
> This is not an error: it was done on purpose. SAXOutputter builds a DTD
> string from the DocType found in the document and handed it to a parser for
> that parser to fire the DTD events. Of course, there is no root element
> because SAXOutputter will fired the SAX events related to the JDOM document
> just after the parser reported a SAXParseException. This exception is
> expected as shown by the comments in the catch() clause just after the call
> to
> createDTDParser().parse().
> What's weird in your case is that Xerces fires an IndexOutOfBoundException
> instead of the expected SAXParseException. Which version of Xerces are you
> using? Is your DTD file correct (i.e. parsed successfully by the same
> parser when directly referenced from an XML document)?
> Laurent
> _______________________________________________
> To control your jdom-interest membership:
> http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourho

More information about the jdom-interest mailing list