[jdom-interest] Re: BUG: XMLOutputter inserts extra empty lines

Joseph Bowbeer jozart at csi.com
Fri Dec 7 01:50:42 PST 2001


PS - Also have a look at gnu.xml.pipeline.TextConsumer, which is the
"pipelined" version of XMLWriter.

 http://www.gnu.org/software/classpathx/jaxp/apidoc/index.html


By the way, the gnu.xml.pipeline design looks very interesting.  Are there
any ideas here we should apply to XMLOutputter?



----- Original Message -----
From: "Joseph Bowbeer" <jozart at csi.com>
To: "Hallvard Tratteberg" <hal at idi.ntnu.no>
Cc: <jdom-interest at jdom.org>; <James.Todd at Sun.COM>
Sent: Friday, December 07, 2001 12:38 AM
Subject: Re: BUG: XMLOutputter inserts extra empty lines


Hallvard Tratteberg writes to James Todd:

> I've been toying with the same idea, a kind of output-analog
> to the Builder, SAXBuilder and SAXParser structure that is
> used when reading, parsing and building a document.
> The idea is to use the SAXReader (or SAXFilter) interface
> to also perform output, and I believe there are SAXReaders
> that do this already, i.e. receive SAX events and write out
> a new XML document ...


JDOM already has some of this:

 org.jdom.output.SAXOutputter (shredder + writer)
 http://cvs.jdom.org/cgi-bin/viewcvs.cgi/jdom/src/java/

 samples.sax.XMLWriter plus some filter implementations
 http://cvs.jdom.org/cgi-bin/viewcvs.cgi/jdom/samples/sax/

By the way, samples.sax.XMLWriter was derived from Megginson's XMLWriter
(ver 0.2).  Our version includes a couple of bug fixes and a different class
hierarchy than Megginson's original version.


The most complete XMLWriter I know of is Dave Brownell's
gnu.xml.util.XMLWriter

 http://www.gnu.org/software/classpathx/jaxp/
 http://www.gnu.org/software/classpathx/jaxp/apidoc/index.html
 http://savannah.gnu.org/cgi-bin/viewcvs/classpathx/jaxp/source/


James Strachan's org.dom4j.io.XMLWriter is also worthy of mention:

 http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/dom4j/dom4j/src/java/

---
Joe Bowbeer






More information about the jdom-interest mailing list