xml-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Keith Pajkowski <Keith.Pajkow...@T1Xpert.com>
Subject building DOM tree from scratch
Date Wed, 31 May 2000 18:26:29 GMT
We want to convert a data structure to an XML equivalent on the fly, i.e.,
build a DOM tree without actually reading in an XML document. The only
example of this I can find is written in XML4J and made use of the (now
deprecated) class TXDocument. In this example the completed document was
output using the instruction:

     ((TXDocument)doc).printWithFormat(new PrintWriter(System.out));

I looked at the DOMWriter.java example in the latest XerxesJ release. When I
try to output the XML document using OutputStreamWriter, XercesJ prints the
message:
 
     [#document:  null]

Sun's jaxp will not even compile the class, citing "Can't convert
org.w3c.dom.Document to char[]".

Any references you can send would be much appreciated.


Keith Pajkowski
T1Xpert.com
212 771 1059



Mime
View raw message