文書型 > XML Support > How Arbortext Editor Recognizes an XML Document
  
How Arbortext Editor Recognizes an XML Document
When reading a document, Arbortext Editor recognizes it as an XML document by its XML declaration processing instruction (PI) if one is present. When reading an external text entity, Arbortext Editor recognizes it as XML by its XML encoding PI if one is present. If there are no such PIs present, the -xml option on the read or edit command can be used to force the file to be read as XML.
When writing a document as XML, Arbortext Editor writes the XML declaration PI for main document files and writes the encoding PI for external text entities. The XML version is also written to the document's PI. For a new document created and saved in Arbortext Editor, the XML version is based on the version in the template file for the document type. For XML documents created and saved using the ACL function doc_open or the AOM Application interface openDocument method, the XML version is based on the setting of the set xmlversion option. The XML version is used for the validation of characters.
For more information, see
read command (Arbortext Command Language Reference PDF)
edit command (Arbortext Command Language Reference PDF)
doc_open function (Arbortext Command Language Reference PDF)
set xmlversion command (Arbortext Command Language Reference PDF)