]> gitweb.factorcode.org Git - factor.git/blob - basis/xml/writer/writer-docs.factor
Merge commit 'origin/master' into emacs
[factor.git] / basis / xml / writer / writer-docs.factor
1 ! Copyright (C) 2005, 2009 Daniel Ehrenberg
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: help.syntax help.markup io strings ;
4 IN: xml.writer
5
6 ABOUT: "xml.writer"
7
8 ARTICLE: "xml.writer" "Writing XML"
9     "These words are used in implementing prettyprint"
10     { $subsection write-xml-chunk }
11     "These words are used to print XML normally"
12     { $subsection xml>string }
13     { $subsection write-xml }
14     "These words are used to prettyprint XML"
15     { $subsection pprint-xml>string }
16     { $subsection pprint-xml>string-but }
17     { $subsection pprint-xml }
18     { $subsection pprint-xml-but } ;
19
20 HELP: write-xml-chunk
21 { $values { "object" "an XML element" } }
22 { $description "writes an XML element to " { $link output-stream } "." }
23 { $see-also write-xml-chunk write-xml } ;
24
25 HELP: xml>string
26 { $values { "xml" "an xml document" } { "string" "a string" } }
27 { $description "converts an XML document into a string" }
28 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
29
30 HELP: pprint-xml>string
31 { $values { "xml" "an xml document" } { "string" "a string" } }
32 { $description "converts an XML document into a string in a prettyprinted form." }
33 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
34
35 HELP: write-xml
36 { $values { "xml" "an XML document" } }
37 { $description "prints the contents of an XML document to " { $link output-stream } "." }
38 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
39
40 HELP: pprint-xml
41 { $values { "xml" "an XML document" } }
42 { $description "prints the contents of an XML document to " { $link output-stream } " in a prettyprinted form." }
43 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
44
45 HELP: pprint-xml-but
46 { $values { "xml" "an XML document" } { "sensitive-tags" "a sequence of names" } }
47 { $description "Prettyprints an XML document, leaving the whitespace of the tags with names in sensitive-tags intact." }
48 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
49
50 HELP: pprint-xml>string-but
51 { $values { "xml" "an XML document" } { "sensitive-tags" "a sequence of names" } { "string" string } }
52 { $description "Prettyprints an XML document, returning the result as a string and leaving the whitespace of the tags with names in sensitive-tags intact." }
53 { $notes "does not preserve what type of quotes were used or what data was omitted from version declaration" } ;
54
55 { xml>string write-xml pprint-xml pprint-xml>string pprint-xml>string-but pprint-xml-but } related-words
56