An InstanceDeclarationis an Object, Variableor Methodthat references a ModellingRulewith a HasModellingRule Referenceand is the TargetNodeof a hierarchical Referencefrom a TypeDefinitionNodeor another InstanceDeclaration. The type of an InstanceDeclarationmay be abstract, however the instance must be of a concrete type.

If no ModellingRuleexists then the Nodeis neither considered for instantiation of a type nor for subtyping.

If a Nodereferenced by a TypeDefinitionNodedoes not reference a ModellingRuleit indicates that this Nodeonly belongs to the TypeDefinitionNodeand not to the instances. For example, an ObjectType Nodemay contain a Propertythat describes scenarios where the type could be used. This Propertywould not be considered when creating instances of the type. This is also true for subtyping, that is, subtypes of the type definition would not inherit the referenced Node.

The InstanceDeclarationHierarchyof a TypeDefinitionNodecontains the TypeDefinitionNodeand all InstanceDeclarationsthat are directly or indirectly referenced from the TypeDefinitionNodeusing forward hierarchical References.

A similar Nodeof an InstanceDeclarationis a Nodethat has the same BrowseNameand NodeClassas the InstanceDeclarationand in cases of Variablesand Objectsthe same TypeDefinitionNodeor a subtype of it.

All targets of forward hierarchical Referencesfrom a TypeDefinitionNodeshall have a BrowseNamethat is unique within the TypeDefinitionNode. The same restriction applies to the targets of forward hierarchical Referencesfrom any InstanceDeclaration. This means that any InstanceDeclarationwithin the InstanceDeclarationHierarchycan be uniquely identified by a sequence of BrowseNames. This sequence of BrowseNamesis called a BrowsePath.

Some restrictions exist regarding the Attributesof InstanceDeclarationswhen the InstanceDeclarationis overridden or instantiated. The BrowseNameand the NodeClassshall never change and always be the same as the original InstanceDeclaration.

In addition, the rules defined in 6.2.7apply for InstanceDeclarationsof the NodeClass Variable.

Some restrictions exist regarding the Attributesof a VariableTypeor a Variableused as an InstanceDeclarationwith regard to the data type of the Value Attribute.

When a Variableused as InstanceDeclarationor a VariableTypeis overridden or instantiated the following rules apply:

  1. The DataType Attribute can only be changed to a new DataTypeif the new DataTypeis a subtype of the DataTypeoriginally used.
  2. The ValueRank Attributemay only be further restricted
  3. ‘Any’ may be set to any other value;
  4. ‘ScalarOrOneDimension’ may be set to ‘Scalar’ or ‘OneDimension’;
  5. ‘OneOrMoreDimensions’ may be set to a concrete number of dimensions (value > 0).
  6. All other values of this Attributeshall not be changed.
  7. The ArrayDimensions Attribute may be added if it was not provided or when modifying the value of an entry in the array from 0 to a different value. All other values in the array shall remain the same.

InstanceDeclarationsare identified by their BrowsePath. Different Serversmight use different NodeIdsfor the InstanceDeclarationsof common TypeDefinitionNodes, unless the definition of the TypeDefinitionNodealready defines a NodeIdfor the InstanceDeclaration. All TypeDefinitionNodesdefined in OPC 10000-5already define the NodeIdsfor their InstanceDeclarationsand therefore shall be used in all Servers.