This Structure DataType is used to provide the metadata for a field in a DataSet. The FieldMetaData is formally defined in Table 7.

Table 7 – FieldMetaData structure

Name

Type

Description

FieldMetaData

Structure

Name

String

Name of the field.

The name shall be unique in the DataSet.

Description

LocalizedText

Description of the field.

The default value shall be a null or empty LocalizedText.

FieldFlags

DataSetFieldFlags

Flags for the field.

BuiltInType

Byte

The built-in data type of the field. The possible built-in type values are defined in OPC 10000-6.

All data types are transferred in DataSetMessages as one of the built-in data types. In most cases the identifier of the DataType NodeId matches the built-in type. The following special cases need to be handled in addition:

(1) Abstract types always have the built-in type Variant since they can result in different concrete types in a DataSetMessage. The dataType field may provide additional restrictions e.g. if the abstract type is Number. Abstract types shall not be used if the field is represented as RawData set by the DataSetFieldContentMask defined in 6.2.4.2.

(2) Enumeration DataTypes are encoded as Int32. The Enumeration strings are defined through a DataType referenced through the dataType field.

(3) Structure and Union DataTypes are encoded as ExtensionObject. The encoding rules are defined through a DataType referenced through the dataType field.

(4) DataTypes derived from built-in types have the BuiltInType of the corresponding base DataType. The concrete subtype is defined through the dataType field.

(5) OptionSet DataTypes are either encoded as one of the concrete UInteger DataTypes or as an instance of an OptionSetType in an ExtensionObject.

DataType

NodeId

The NodeId of the DataType of this field.

If the DataType is an Enumeration or an OptionSet, the semantic of the Enumeration DataType is provided through the enumDataTypes field of the DataSetMetaData base type DataTypeSchemaHeader.

If the DataType is a Structure or Union, the encoding and decoding description of the Structure DataType is provided through the structureDataTypes field of the DataSetMetaData base type DataTypeSchemaHeader.

ValueRank

Int32

Indicates whether the dataType is an array and how many dimensions the array has.

It may have the following values:

n > 1: the dataType is an array with the specified number of dimensions.

OneDimension (1): The dataType is an array with one dimension.

OneOrMoreDimensions (0): The dataType is an array with one or more dimensions.

Scalar (−1): The dataType is not an array.

Any (−2): The dataType can be a scalar or an array with any number of dimensions.

ScalarOrOneDimension (−3): The dataType can be a scalar or a one dimensional array.

NOTE All DataTypes are considered to be scalar, even if they have array-like semantics like ByteString and String.

Only a concrete valueRank with values n=-1 or n>0 shall be used if the field is represented as RawData set by the DataSetFieldContentMask defined in 6.2.4.2.

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 or empty if valueRank ≤ 0.

The maximum number of elements of an array transferred on the wire is 2.147.483.647 (max Int32). It is the total number of elements in all dimensions based on the UA Binary encoding rules for arrays.

MaxStringLength

UInt32

If the dataType field is a String, LocalizedText (the text field) or ByteString then this field specifies the maximum supported length of the data in number of bytes. If the maximum is unknown the value shall be 0.If the dataType field is not a String, LocalizedText or ByteString the value shall be 0.

If the valueRank is greater than 0 this field applies to each element of the array.

DataSetFieldId

Guid

The unique ID for the field in the DataSet. The ID is generated when the field is added to the list. A change of the position of the field in the list shall not change the ID.

Properties

KeyValuePair[]

List of Property values providing additional semantic for the field.

If at least one Property value changes, the MajorVersion of the ConfigurationVersion shall be updated.

The Property in the FieldMetaData shall correctly describe the Field Value in the DataSetMessages. For example if the Property is EngineeringUnits, the unit of the Field Value shall match the unit of the FieldMetaData.

The KeyValuePair DataType is defined in OPC 10000-5. For this field the key in the KeyValuePair structure is the BrowseName of the Property and the value in the KeyValuePair structure is the Value of the Property.

Its representation in the AddressSpace is defined in Table 8.

Table 8 – FieldMetaData definition

Attributes

Value

BrowseName

FieldMetaData

IsAbstract

False

Subtype of Structure defined in OPC 10000-5.

Conformance Units

PubSub Parameters Discovery