write-xml ( xml -- )
Writing XML

Next:xml>string ( xml -- string )


Vocabulary
xml.writer

Inputs and outputs
xmlan XML document


Word description
Prints the contents of an XML document to output-stream.

Notes
This does not preserve what type of quotes were used or what data was omitted from version declaration, as that information isn't present in the XML data representation. The whitespace in the text nodes of the original document is preserved.

See also
xml>string, pprint-xml, pprint-xml>string

Definition


Methods































M: number write-xml "Numbers are not allowed in XML" throw ;






M: prolog write-xml
"<?xml version=" write
[ version>> write-quoted ]
[ drop " encoding=\"UTF-8\"" write ]
[ standalone>> [ " standalone=\"yes\"" write ] when ] tri
"?>" write ;