Extensions.Xml.XmlFromByteField
Jump to navigation
Jump to search
Contents
Classification
Name | XmlFromByteField |
Short Description | Returns an XmlDocument from a ByteField. |
Class | Term |
Extension | OTX Xml extension |
Group | Xml related Terms |
Exceptions | XmlFormatException |
Checker Rules | - |
Standard Compliant | Yes |
OTL Syntax
XmlDocumentTerm Xml.XmlFromByteField(ByteFieldTerm byteField, EncodingTerm fallbackEncoding);
Description
The XmlFromByteField term returns an XmlDocument from a ByteField.
Return Value
The Term returns the value, see table below.
In OTX, Terms are categorized according to its return data type!
Data Type | Description |
XmlDocument | The XmlDocument from a ByteField. |
Properties
Name | Data Type | Class | Default | Cardinality | Description |
ByteField | ByteField | Term | - | [1..1] | The ByteField that encapsulates the XML data. |
FallbackEncoding | Encoding | Term | @Encoding:UTF-8 | [0..1] | Optional encoding value of the ByteField, if no encoding is described in the XML prolog or byte order mark (BOM). If the encoding is defined in the prolog this value should be ignored. If an invalid encoding (BIN, OCT, HEX) is specified, a XmlFormatException shall be thrown |
OTL Examples
/// Local Declarations
ByteField ByteField1;
Xml.XmlElement XmlElement1;
Xml.XmlDocument XmlDocument1;
/// Flow
XmlElement1 = Xml.CreateXmlElement("root", NULL, {"attr":"val"});
XmlDocument1 = Xml.CreateXmlDocument(XmlElement1, "1.0", @Encoding:UTF-8, false);
ByteField1 = Xml.XmlToByteField(XmlDocument1);
XmlDocument1 = Xml.XmlFromByteField(ByteField1, @Encoding:UTF-8);
See also
CopyXmlElement
CreateXmlDocument
CreateXmlElement
GetXmlElementAttributes
GetXmlElementChildElements
GetXmlElementName
GetXmlElementsByXPath
GetXmlElementText
GetXmlRootElement
XmlLoadFromFile
XmlToByteField