OTX Reference  
OpenTestSystem.Otx.Extensions.DataType.DataTypes.Structure Class Reference

Structure is an otx:ComplexType. More...

Inheritance diagram for OpenTestSystem.Otx.Extensions.DataType.DataTypes.Structure:
Inheritance graph

Public Attributes

StructureLiteral init
 Cardinality [0..1]
his optional element stands for the initialization of the structure at declaration time. More...
 
OtxLink structureType
 Cardinality [1]
Refers to a certain StructureSignature. More...
 

Detailed Description

Structure is an otx:ComplexType.

A structure is a user-defined data type composed of elements that can have different data types. It is typically used to encapsulate small groups of related elements, such as the coordinates of a rectangle. Structures can contain elements of any OTX data type and also Structure itself in any depth. To define the structure of a Structure the StructureSignature is used. A Structure itself has no literal and also has no init value. To access structure elements only StepByName and not StepByIndex will be used.

Note
IMPORTANT — A Structure value can be persisted if all contained elements can be persisted, see Persistence extension.
Checker rules
CheckerRule.DataType_Chk001 - Accessing structure elements
Core.CheckerRule.Core_Chk053 - no dangling OtxLink associations
CheckerRule.DataType_Chk006 - StructureLiteral structure type matches Structure declaration structure type

Sample

package DataType.StructureSignature StructureSignature1(Boolean StructureElement1 = false, Integer StructureElement2, Float StructureElement3, String StructureElement4, ByteField StructureElement5);
// Global Declarations
public procedure main()
{
// Local Declarations
StructureSignature1 Structure1;
}

Member Data Documentation

◆ init

StructureLiteral OpenTestSystem.Otx.Extensions.DataType.DataTypes.Structure.init

Cardinality [0..1]
his optional element stands for the initialization of the structure at declaration time.

Note
IMPORTANT — Only structure elements which have a literal can be initialized.
IMPORTANT — If the Structure declaration is not explicitly initialized (omitted <init> element), the default value of each element shall be used.

◆ structureType

OtxLink OpenTestSystem.Otx.Extensions.DataType.DataTypes.Structure.structureType

Cardinality [1]
Refers to a certain StructureSignature.