This Structured DataType is used to provide the metadata for a field of a custom Structure DataType. The StructureField is formally defined in Table 35.
Table 35 – StructureField Structure
|name||String||A name for the field that is unique within the StructureDefinition.|
|description||LocalizedText||A localized description of the field|
|dataType||NodeId||The NodeId of the DataType for the field. When used by a StructureDefinition with a structureType of Structure, StructureWithOptionalFields or Union then the datatype shall be a concrete DataType, BaseDataType DataType or Structure DataType If the structureType is StructureWithSubtypedValues, or UnionWithSubtypedValues and the isOptional field is TRUE then the encoding of the field shall be able to transport any subtype of the DataType. OPC 10000-6 provides more details of specific encodings.|
|valueRank||Int32||The value rank for the field.It shall be Scalar (-1) or a fixed rank Array (>=1).|
|arrayDimensions||UInt32||This field specifies the maximum supported length of each dimension. If the maximum is unknown the value shall be 0. The number of elements shall be equal to the value of the valueRank field. This field shall be null if valueRank ≤ 0.The maximum number of elements of an array transferred on the wire is 2147483647 (max Int32).|
|maxStringLength||UInt32||If the dataType field is a String, LocalizedText (text field) or ByteString then this field specifies the maximum supported length in bytes. If the maximum is unknown the value shall be 0. If the dataType field is not a String or ByteString the value shall be 0.If the valueRank is greater than 0 this field applies to each element of the array.|
|isOptional||Boolean||If the structureType is StructureWithOptionalFields this field indicates if a data type field in a Structure is optional. In this case a value of FALSE means the StructureField is always present in all occurances of the Structure DataType and a value of TRUE means the StructureField may be present in an occurance of the Structure DataType. If the structureType is Structure or Union this field shall be FALSE and shall be ignored.If the structureType is StructureWithSubtypedValues, or UnionWithSubTypedValues this field is used to indicate if the data type field allows subtyping. Subtyping is allowed when set to TRUE.|
StructureFields can be exposed as DataVariables that are children of the Variable that contains the Structure Value. In this case the BrowseName of the DataVariable shall be the same as the StructureField name and the NamespaceIndex of the BrowseName shall be the same as the Structure DataType Node NamespaceIndex.