|
|
От: |
BlackHeretic
|
|
| Дата: | 06.09.09 15:54 | ||
| Оценка: | |||
DocumentBuilder db = dbf.newDocumentBuilder();
Document doc = db.newDocument();
Element root = doc.createElement(ROOT);
doc.appendChild(root);
stack.serializeTo(root);
track.createReverseStack().serializeTo(root);
OutputFormat of = new OutputFormat(doc, "utf-8", true);
XMLSerializer serializer = new XMLSerializer(os, of);
serializer.processingInstruction("xml-stylesheet", "type=\"text/xsl\" href=\"demo.xsl\"");
serializer.asDOMSerializer().serialize(doc);