This parameter may be used to optionally specify the XML document that is to be written out as output. Any XML element created from a rooted feature by the writer will be inserted into this document. By default, the XML elements are inserted right before the end tag of the XML document’s root element.
XML Document Append Path
This parameter specifies a single element via a QName, or a path to a single element via a path of QNames, in the XML Document.
Each element in the path is separated by a forward slash (/). An asterisk wildcard (*) may also be used as the prefix or local-name of the element’s QName. For example, *:e, p:*, or just * (which is a shorter version of *:*).
This parameter specifies a single insertion point in the XML Document. To append into multiple sections, use the xml_document_append_path format attribute – this format attribute overrides this parameter if present.
XML Document Append As
This parameter controls how the features that are mapped into XML are inserted into the XML Document in relation to the XML Document Append Path.
The possible values for the parameter are:
- Succeeding Children (default)
- Preceding Children
- Preceding Siblings
- Succeeding Siblings
The values are to be understood in relation to the selected or matched element.
Each individual root feature may override this parameter by using the xml_document_append_as format attribute. The possible values for xml_document_append_as are preceding_children, succeeding_children, preceding_siblings, and succeeding_siblings.
Note: To dynamically control the contents of the XML Document (for example, to be able to generate its contents within the workspace with an XMLTemplater transformer), you can add a special writer feature type – _XML_DOCUMENT_ – whose xml_document, xml_document_append_path, and xml_document_append_as format attributes (if present) overwrite their corresponding writer’s parameter values. The possible values for xml_document_append_as are preceding_children, succeeding_children, preceding_siblings, and succeeding_siblings.
Note: XML Fragments having no corresponding feature types may be appended to the XML Document via the special writer feature type – _XML_FRAGMENT_ – the xml fragment is specified with the xml_fragment attribute. The xml_document_append_path, and xml_document_append_as format attributes specify where and how the fragment is appended in the XML Document.