[jdom-interest] RE: Line breaks after xml declaration
William Krick
wkrick at eio-online.com
Tue Jul 18 13:30:07 PDT 2006
RE: Line breaks after xml declarationYou'll probably have to turn off the
XML declaration when converting to a string, then add it manually like
this...
Format fmt = Format.getCompactFormat();
fmt.setOmitDeclaration(true);
XMLOutputter outputter = new XMLOutputter(fmt);
String declaration = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>";
String xml = declaration + outputter.outputString(doc);
-----Original Message-----
From: Heise, Robert [mailto:Robert.Heise at Peopleclick.com]
Sent: Tuesday, July 18, 2006 3:14 PM
To: jdom-interest at jdom.org
Subject: [jdom-interest] RE: Line breaks after xml declaration
I have a xml client that requires no line breaks in the xml. Is there
anyway to turn off, strip out, the line break after the xml declaration when
using Document?
Thanks
Rob
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.jdom.org/pipermail/jdom-interest/attachments/20060718/27a80b6a/attachment.htm
More information about the jdom-interest
mailing list