OTX Reference  
OpenTestSystem.Otx.Extensions.XML.Actions.SetXmlElementAttributes Class Reference

Sets attributes of a XmlElement. More...

Inheritance diagram for OpenTestSystem.Otx.Extensions.XML.Actions.SetXmlElementAttributes:
Inheritance graph

Public Attributes

MapTerm attributes
 Contains a map of name/value pairs representing the attributes of the xml node. The name can contain an arbitrary namespace in form of "Namespace:Name". More...
 
XmlElementTerm element
 Represents the XmlElement, which the attributes contains. More...
 
- Public Attributes inherited from OpenTestSystem.Otx.Core.Actions.ActionRealisation
OtxLink validFor
 Validity of ActionRealisation. More...
 

Detailed Description

Sets attributes of a XmlElement.

The SetXmlElementAttributes activity sets attributes of a XmlElement. All existing attributes will be removed. Please note, that the attribute order is not specified.

Checker rules
CheckerRule.Xml_Chk001 - type-safe SetXmlElementAttributes

Syntax
Xml.SetXmlElementAttributes(XmlElementTerm element, MapTerm attributes);
MapTerm attributes
Contains a map of name/value pairs representing the attributes of the xml node. The name can contain ...
Definition: XML.cs:664
XmlElementTerm element
Represents the XmlElement, which the attributes contains.
Definition: XML.cs:654
Examples
// Local Declarations
Xml.XmlElement XmlElement1;
// Flow
XmlElement1 = Xml.CreateXmlElement("person2");
Xml.SetXmlElementAttributes(XmlElement1, {"gender":"male", "age":"22"});

Member Data Documentation

◆ attributes

MapTerm OpenTestSystem.Otx.Extensions.XML.Actions.SetXmlElementAttributes.attributes

Contains a map of name/value pairs representing the attributes of the xml node. The name can contain an arbitrary namespace in form of "Namespace:Name".

◆ element

XmlElementTerm OpenTestSystem.Otx.Extensions.XML.Actions.SetXmlElementAttributes.element

Represents the XmlElement, which the attributes contains.