To write a DOM
to a file in XML form, first import a method like this:
import Ft.Xml.Domlette as domlette
There are two different serializing (printing) methods.
.Print() for correct handling of
indenting and line breaks.
If the output is intended for human consumption, and
you don't mind extra line breaks and indentation added
for legibility, use
arguments are the same as the
To serialize a document
Then pass the document object to it using this general form:
where the optional arguments are:
A file object where you want the XML written. Defaults to standard output.
The character encoding you want to use. The