C# project nodes
The code of a NetLogic represents the project nodes by special C# classes that contain and expose properties.
IUANode class
IUANode
class Displays the following base properties of any project node:
- BrowseName
- The name of the node in the project. Cannot be localized.
- DisplayName
- The name of the node visible in the user interface. Can be localized.
- NodeId
- The automatically assigned unique ID for the node.
IUAObject class
IUAObject
classDisplays the properties of any instance of a project object (for example: a graphical object, alarm, driver).
It is an
IUANode
subclass, which displays all of its properties. It also exposes the ObjectType
property, which is a reference to the object type (IUAObjectType
class) from which the instance derives.IUAObjectType class
IUAObjectType
classDisplays the properties of any type of a project object (for example: a graphical object, alarm, driver).
It is an
IUANode
subclass, which displays all of its properties. It also exposes the SuperType
property, which is the C# object that represents the object type from which the same IUAObjectType
derives.IUAVariable class
IUAVariable
classDisplays the properties of any project variable instance (base variable, analog variable, controller tag, node pointer).
It is an
IUANode
subclass, which displays all of its properties. It also exposes the following properties:
- ArrayDimensions
- The quantity of cells in the array.
- DataType
- The data type that the variable can contain (for example:OpcUa.DataTypes.Boolean,OpcUa.DataTypes.Int16).
- Value
- The value of the variable (UAValueproperty).
- VariableType
- The C# object that represents the type of the variable from which the instance derives.
IUAVariableType class
IUAVariableType
classDisplays the properties of any type of a project variable.
It is an
IUANode
subclass, which displays all of its properties. It also exposes the following properties:
- ArrayDimensions
- The quantity of cells in the array.
- DataType
- The data type that the variable can contain (for example:OpcUa.DataTypes.Boolean,OpcUa.DataTypes.Int16).
- SuperType
- The C# object that represents the variable type from which the sameIUVariableTypederives.
UAValue class
UAValue
classDisplays a value. The value can then be converted to and from different types of C# data.
Classes for custom and default objects and variables
A corresponding C# class is available for any custom or default objects and variables. The class is always a subclass of
IUAObject
or IUAVariable
, to which any properties specified in the type are added.For example, if a
Motor
object type is created in FactoryTalk Optix Studio
with the Speed
and Acceleration
properties, the Motor
C# class is automatically created with the Speed
, SpeedVariable
, Acceleration
, and AccelerationVariable
properties.C# default class types are defined in
FTOptix
modules. When you save the project, FactoryTalk Optix Studio
creates C# classes that correspond to custom types.
TIP:
Display the type of an object or variable selected from which an instance derives in
Properties
by hovering over the Type
value.