Hi Simon,
Sauquet Dominique wrote:
> Considering the presentation of documents, I was using DOMWriter and as the
> domWriter.setFeature("format-pretty-print",true)
> does not work (no effect at all)
> (I am using Xerces 2-2)
Setting this feature to "true" in the DOMWriter is not supported yet.
> With a DOMWriter how can you set the indentation, set the encoding or
> omit XML declaration ?
You can set encoding using setEncoding method and omit declaration using
"xml-declaration" feature.
For more information, please read [1], [2].
> What is the best practice between DOMWriter or XMLSerializer ?
The DOMWriter is a part of the W3C Load and Save Working draft. While
the specification is not stable, we hope that the draft will reach the
final status some time this year. So if you are looking for a standard
way to serialize documents you should use DOMWriter.
[1] http://www.w3.org/TR/2003/WD-DOM-Level-3-LS-20030226/load-save.html
[2] http://xml.apache.org/xerces2-j/dom3.html
Thank you,
--
Elena Litani / IBM Toronto
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]