This Built-in DataType is composed of three elements that identify a Node within a Server. They are defined in Table 21.
Name |
Type |
Description |
NodeId |
structure |
|
NamespaceIndex |
UInt16 |
The index for a namespace URI (see 8.2.2). |
IdType |
Enum |
The format and data type of the identifier (see 8.2.3). |
Identifier |
* |
The identifier for a Node in the AddressSpace of an OPC UA Server (see 8.2.4). |
See OPC 10000-6 for a description of the encoding of the identifier into OPC UA Messages.
The namespace is a URI that identifies the naming authority responsible for assigning the identifier element of the NodeId. Naming authorities include the local Server, the underlying system, standards bodies and consortia. It is expected that most Nodes will use the URI of the Server or of the underlying system.
Using a namespace URI allows multiple OPC UA Servers attached to the same underlying system to use the same identifier to identify the same Object. This enables Clients that connect to those Servers to recognise Objects that they have in common.
Namespace URIs, like Server names, are identified by numeric values in OPC UA Services to permit more efficient transfer and processing (e.g. table lookups). The numeric values used to identify namespaces correspond to the index into the NamespaceArray. The NamespaceArray is a Variable that is part of the Server Object in the AddressSpace (see OPC 10000-5 for its definition).
The URI for the OPC UA namespace is:
“http://opcfoundation.org/UA/”
Its corresponding index in the namespace table is 0.
The namespace URI is case sensitive.
The IdType element identifies the type of the NodeId, its format and its scope. Its values are defined in Table 22.
Name |
Value |
Description |
Numeric |
0 |
Numeric value |
String |
1 |
String value |
Guid |
2 |
Globally Unique Identifier |
Opaque |
3 |
Namespace specific format |
Normally the scope of NodeIds is the Server in which they are defined. For certain types of NodeIds, NodeIds can uniquely identify a Node within a system, or across systems (e.g. GUIDs). System-wide and globally-unique identifiers allow Clients to track Nodes, such as work orders, as they move between OPC UA Servers as they progress through the system.
Opaque identifiers are identifiers that are free-format byte strings that might or might not be human interpretable.
String identifiers are case sensitive. That is, Clients shall consider them case sensitive. Servers are allowed to provide alternative NodeIds (see 5.2.2) and using this mechanism severs can handle NodeIds as case insensitive.
The Identifier value element is used within the context of the first three elements to identify the Node. Its data type and format is defined by the IdType.
Identifier values of IdType String are restricted to 4096 characters and shall not contain Unicode control characters. Unicode control characters are defined by Unicode C0 and Unicode C1.
A Node in the AddressSpace shall not have a null NodeId. However, many services defined in OPC 10000-4 define special behaviour if a null NodeId is passed as a parameter.
A canonical null NodeId has an IdType equal to Numeric, a NamespaceIndex equal to 0 and an Identifier equal to 0.
In addition to the canonical null NodeId the alternative values defined in Table 23 shall be considered a null NodeId.
Table 23 – NodeId Alternative Null Values
IdType |
NamespaceIndex |
Null Value |
String |
0 |
A null or Empty String (“”) |
Guid |
0 |
A Guid initialised with zeros (e.g. 00000000-0000-0000-0000-000000) |
Opaque |
0 |
A null or Empty ByteString |