Object
NodeClass
is used to define objects as parts involved in the underling real-time process. Each Object
in the Address Space has an assigned object type. The OPC UA specification has defined a BaseObjectType
from which all other ObjectType
s shall either inherit, directly or indirectly.BaseObjectType
are listed in Table 1.ServerType
ServerCapabilitiesType
ServerDiagnosticsType
SessionsDiagnosticsSummaryType
SessionDiagnosticsObjectType
VendorServerInfoType
ObjectType
defines an empty ObjectType
that has no components and vendors should derive from this type to expose application specific information.ServerRedundancyType
BaseEventType
EventTypes
derive from it.ModellingRuleType
NamingRule
which has the following values i.e. Optional, Mandatory, or Constraint.FolderType
DisplayName
Attribute should imply the semantics associated with the use of it.DataTypeEncodingType
DataType
s of Variable
s NodeClass
, e.g. “Default”, “UA Binary” or “XML”.DataTypeSystemType
Value
attributes.BaseEventType
has many specialized subtypes to allow handling most common transient Events. System configuration changes, operator interaction and system errors are examples of Events. OPC UA Part 9 – Alarm and Conditions expands on this object type to define alarm and condition events.HasTypeDefinition
reference to its type definition (depicted as double closed and filled arrows).DataType
attribute.VariableType
s is BaseVariableType
(Figure 2). This means that all other types must inherit from it. The PropertyType
and the BaseDataVariableType
are most important for information representation. Consequently, there are two independent inheritance sub-trees.BaseDataType
, which is abstract and defines a value that can have any valid type (Figure 3). The double closed arrows point to the source of the HasSubtype
reference. An interesting feature of these types is that even though they have an abstract BaseDataType
both are concrete and therefore can be instantiated. Abstract DataType
s do not have any encoding and cannot be exchanged on the wire; therefore the instantiated variables with an abstract DataType
must redefine it. The DataType
attribute can only be changed to a new one if it is a subtype of the original DataType
.PropertyType
must not have subtypes. Additionally, it is not permitted to have a Property as source of the HierarchicalReference
s type or any type inherited from it. In other words properties cannot be complex. To prevent recursion, properties are also not allowed to have properties defined for them. Additionally, a node and all its properties shall always reside in the same server.BaseDataVariableType
is a parent of two sets of types dedicated to:DataTypeDictionaryType
and DataTypeDescriptionType
,ServerVendorCapabilityType
, ServerStatusType
, etc.DataItemType
that derives from the BaseDataVariableType
to represent any item of data (see Figure 4). Users can create new types from the already defined ones to meet specific requirements of the application (see example case below). A detailed description of the types derived from the BaseDataVariableType
is beyond the scope of this chapter, but some features of this inheritance branch are worth noting. As opposed to the properties, the variables may be complex. One example of a complex VariableType
is the ServerStatusType
shown in Figure 5. Components of the complex variable can be accessed independently. The next very important future of the variables is that new user specific types can be freely defined by deriving them from those already defined.Variable
Value
attribute is defined by the associated DataType
. DataType
is pointed out by the DataType
attribute of the Variable
and VariableType
nodes. The DataType
attribute is of the NodeId
type (Table 2). In many cases, the value of the DataType
attribute – called DataTypeId
– will be well-known to clients and servers. Well-known values of DataTypeId
allow clients to use random addressing and interpret values without having to read the type description from the server. Therefore, servers may use well-known DataTypeId
values without representing the corresponding DataType
nodes in their Address Space.DataType
NodeClass
is dedicated to describe types. In this case, the represented types have a special mission, because they describe data provided by the UA Server to clients. For example, a node of the DataType can provide information to clients that the data has a numeric value and the clients reading it can use this knowledge to interpret and process the obtained value – stream of bits.BaseDataType
is the root of the inheritance tree. The simplified inheritance hierarchy of the standard data types is shown in Figure 6, where the whole sub-tree of built-in types are represented commonly by a single symbol.Int32
and Double
. The built-in data types with a short description are listed in the Table 2NodeId
type. This type needs some comments, because it is intended to be used by the random addressing mechanism to represent information allowing clients to uniquely identify and access the nodes. This built-in data type is a structure composed of:namespaceIndex
: numeric values used to identify namespaceidentifierType
: identifies the type of the NodeId
, its format and its scopeidentifier
: a unique identifier within the context of the namespaceNodeId
. Namespace URIs are identified by numeric values in OPC UA Services to permit a more efficient transfer and processing (e.g. table lookups).identifierType
field may have the following values:BaseDataType
, that needs some comments. It is to be used to represent a limited set of simple information entities. Therefore it is a simple and abstract type. All enumerations, like NodeClass
, have to inherit from it. All types inheriting from the Enumeration
have a special processing for the encoding.Structure
(Figure 6) is an abstract data type defined as the base for all structured types. All data types inheriting from it have a special processing for the encoding. All complex data, if not defined explicitly as primitive in the specification, are created by defining of new types derived from the Structure
.Structure
ServerStatusType
has components of a simple data type. Advantages of this approach:ServerStatusDataType
that inherits from the Structure. The ServerStatusDataType
arranges the server status data as a collection of fields. Advantages of this approach:DataTypeDescription
to interpret the data. The data structure is not visible in the Address Space; additional Properties describing the data structure cannot be added to the data type. Individual parts of data cannot be read without accessing the whole data structure.HierarchicalReferences
NonHierarchicalReferences
HierarchicalReferences
do not forbid loops. For example, starting from node “A” and following HierarchicalReferences
may lead to browse to node “A” again.HasChild
is an abstract type derived from HierarchicalReferences
that creates a branch of types, which forbids loops. In this case, starting from node “A” and only following references, which are subtypes of HasChild
, we shall never be able to return to “A”. But it is allowed that there may be more than one path leading to another node “B”.HasChild
branch contains HasComponent
and HasProperty
. Both are derived from the Aggregates type and used to reflect the parent – child relationship. There is also HasSubtype
on this branch, but in this case it is used to expose the inheritance hierarchy.HasComponent
usage scopeHasComponent
is derived from the Aggregates
(Figure 8) is defined to build the part of relationship, i.e. the target node of HasComponent
is a part of the source node. This type is used to relate objects, object types, variables and methods. Table 3 contains the allowed composite nodes (source) and allowed components as the target of this type of reference. By using this reference, the variable is defined as a DataVariable
.HasProperty
derived from Aggregates
(Figure 8) is to identify the properties of a node. The source node of this type can be of any NodeClass
. The target node shall be a variable. By using the HasProperty
, the variable is defined as Property
. Since properties shall not have properties, a property shall never be the source node of a HasProperty
reference.ServerType
has HasProperty
references pointing to the ServerArray
, NamespaceArray
, ServiceLevel
and Auditing properties. The ServerStatus
is a child variable pointed by a reference of the HasComponent
type. Objects of this type have also components: ServerCapabilities
, ServerDiagnostics
, VendorServerInfo
, ServerRedundancy
objects pointed also by a reference of the HasComponent
type.HasSubtype
is a subtype of the HasChild
type. It is worth noting, that inheritance using HasSubtype is represented using the one-to-many (parent/child) relationship. Because new types can be freely derived from the existing ones we cannot enumerate all children in advance - the tree must be built and maintained dynamically during the life-cycle of the Address Space. This means that when a new type is created it is created with a reference to its base (parent), which results in a new subtype being added to the parent.Organizes
is the next subtype of HierarchicalReferences
. The semantics of it is to organize nodes in the Address Space. It can be used to span multiple hierarchies independent of any hierarchy created with the non-looping Aggregates
references. The source node of references of this type shall be an object or a view. If it is an object it should be an object of the FolderType
or one of its subtypes. The target node of this type can be of any NodeClass
.StateMachineType
that defines a single variable of the StateVariableType
, which represents the current state of the machine. An instance of the StateMachineType
shall generate an event whenever a state change occurs. Transitions are represented as objects of the TransitionType
. Each valid transition shall have exactly one FromState
reference and exactly one ToState
reference, each pointing to an object of the StateType
.MyStateMachineType
is derived directly or indirectly from the StateMachineType
. All states, transitions and methods are components of this type.