OTX Reference  
OpenTestSystem.Otx.Extensions.XML.Terms.XmlFromByteField Class Reference

Returns a XmlDocument from a ByteField. More...

Inheritance diagram for OpenTestSystem.Otx.Extensions.XML.Terms.XmlFromByteField:
Inheritance graph

Public Attributes

ByteFieldTerm byteField
 Cardinality [1]
The ByteField which encapsulates the XML data. It can be retrieved from a file via the ReadBytes term. More...
 
EncodingTerm fallbackEncoding
 Cardinality [1]
Optional encoding value of the ByteField (Default = "UTF-8"), if not encoding is described in XML prolog. If the encoding is defined in prolog this value should be ignored. If an invalid encoding (BIN, OCT, HEX) is specified, a XmlFormatException shall be thrown. More...
 
- Public Attributes inherited from OpenTestSystem.Otx.Core.Terms.Term
MetaData metaData
 Cardinality [0..1]
The MetaData type allows tools to store additional, mainly tool-specific data. More...
 

Detailed Description

Returns a XmlDocument from a ByteField.

The XmlFromByteField activity returns a XmlDocument from a ByteField.

Exceptions
Exceptions.XmlFormatException
Syntax
XmlElementTerm = Xml.XmlFromByteField(ByteFieldTerm byteField, EncodingTerm fallbackEncoding = @Encoding:UTF-8);
ByteFieldTerm byteField
Cardinality [1] The ByteField which encapsulates the XML data. It can be retrieved from a file via th...
Definition: XML.cs:1527
EncodingTerm fallbackEncoding
Cardinality [1] Optional encoding value of the ByteField (Default = "UTF-8"), if not encoding is desc...
Definition: XML.cs:1537
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);

Member Data Documentation

◆ byteField

ByteFieldTerm OpenTestSystem.Otx.Extensions.XML.Terms.XmlFromByteField.byteField

Cardinality [1]
The ByteField which encapsulates the XML data. It can be retrieved from a file via the ReadBytes term.

◆ fallbackEncoding

EncodingTerm OpenTestSystem.Otx.Extensions.XML.Terms.XmlFromByteField.fallbackEncoding

Cardinality [1]
Optional encoding value of the ByteField (Default = "UTF-8"), if not encoding is described in XML prolog. If the encoding is defined in prolog this value should be ignored. If an invalid encoding (BIN, OCT, HEX) is specified, a XmlFormatException shall be thrown.