prolog - Factor Documentation (original) (raw)
prolog
XML data types » XML data classes
Prev: | open-tag |
---|---|
Next: | comment |
Class description
Represents an XML prolog, with the following slots:
version | containing "1.0" or "1.1" |
---|---|
encoding | a string representing the encoding type |
standalone | a boolean, whether the document is standalone without external entities |
Definition
TUPLE: prolog
{ version string initial: "" }
{ encoding string initial: "" }
{ standalone boolean initial: f } ;
Methods
USING: kernel namespaces sequences xml.data xml.errors
xml.private xml.state ;
M: prolog process
xml-stack get { V{ { f V{ "" } } } V{ { f V{ } } } } member?
[ bad-prolog ] unless add-child ;
USING: accessors io kernel xml.data xml.writer
xml.writer.private ;
M: prolog write-xml
">](word-version%5F%5Fgt%5F%5F%5F%5Fgt%5F%5F%2Caccessors.html) [write-quoted](word-write-quoted%2Cxml.writer.private.html) [\]](word-%5D%2Csyntax.html)
[\[](word-%5B%2Csyntax.html) [drop](word-drop%2Ckernel.html) " encoding=\\"UTF-8\\"" [write](word-write%2Cio.html) [\]](word-%5D%2Csyntax.html)
[\[](word-%5B%2Csyntax.html) [standalone>>](word-standalone%5F%5Fgt%5F%5F%5F%5Fgt%5F%5F%2Caccessors.html) [\[](word-%5B%2Csyntax.html) " standalone=\\"yes\\"" [write](word-write%2Cio.html) [\]](word-%5D%2Csyntax.html) [when](word-when%2Ckernel.html) [\]](word-%5D%2Csyntax.html) [tri](word-tri%2Ckernel.html)
"?>" write ;