Hi,
Does anyone know if there is a straightforward way to serialize a parsed cyberneko ElementNSImpl object?
Here is my example in Clojure of serializing the whole DOM (an HTMLDocumentImpl object). This works, but I have not yet figured out how to do this for an element from the dom (ElementNSImpl).
(defn dom->xml
[dom]
(let [sw (java.io.StringWriter.)]
(.serialize
(org.apache.xml.serialize.XMLSerializer.
sw (org.apache.xml.serialize.OutputFormat. dom))
dom)
(.toString sw)))
Thanks, Rob