Theres a method setOutputStream in DefaultConfigSerializer. You need to add a 
line similar to

 m_format.put(OutputKeys.INDENT,"yes");

I forget exact code but the above should give you a hint. If you could make 
the serializer configurable so that it generated "nice" XML if you did 
something like

serializer.setIndent( true );

Or at least allowed you to overide it then that would be great. 


On Tue, 5 Mar 2002 18:11, Leif Mortenson wrote:
> I was wondering if there was any way to configure SAX to create XML
> which contains whitespace.
> Currently the XML produced does not contain any linefeeds or whitespace.
>
> Ie, I would like to be able to change this output:
> ---
> <a><b><c1>foo</c1><c2>foo</c2></b></a>
> ---
>
> To
> ---
> <a>
> <b>
> <c1>foo</c1>
> <c2>foo</c2>
> </b>
> </a>
> ---
>
> Or something a little more human readable.
>
> Thanks Leif

-- 
Cheers,

Pete

"Whoever would overthrow the liberty of a nation must begin by subduing the
freeness of speech." - Benjamin Franklin

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to