M
meselfo
I cant get the java api to use linefeed and carriage return in the xml
that im producing:
StreamResult result = new StreamResult(output);
DOMSource source = new DOMSource(doc);
Transformer transformer =
TransformerFactory.newInstance().newTransformer();
transformer.setOutputProperty(OutputKeys.INDENT, "yes");
transformer.setOutputProperty(OutputKeys.ENCODING, "UTF-8");
transformer.transform(source, result);
The xml produced is a single line.
What is needed to "pretty print" the xml?
that im producing:
StreamResult result = new StreamResult(output);
DOMSource source = new DOMSource(doc);
Transformer transformer =
TransformerFactory.newInstance().newTransformer();
transformer.setOutputProperty(OutputKeys.INDENT, "yes");
transformer.setOutputProperty(OutputKeys.ENCODING, "UTF-8");
transformer.transform(source, result);
The xml produced is a single line.
What is needed to "pretty print" the xml?