OPC Studio User's Guide and Reference
UAMappingContext Class
Members 



OpcLabs.EasyOpcUA Assembly > OpcLabs.EasyOpc.UA.LiveMapping Namespace : UAMappingContext Class
A mapping context for OPC Unified Architecture (OPC-UA) specifications.
Object Model
UAMappingContext ClassUAEndpointDescriptor ClassUAMonitoringParameters ClassUANodeDescriptor ClassAbstractMapping ClassUAReadParameters ClassUASubscriptionParameters Class
Syntax
'Declaration
 
<ComVisibleAttribute(False)>
<CLSCompliantAttribute(True)>
Public NotInheritable Class UAMappingContext 
   Inherits OpcLabs.BaseLib.LiveMapping.AbstractMappingContext
   Implements System.ICloneable 
'Usage
 
Dim instance As UAMappingContext
[ComVisible(false)]
[CLSCompliant(true)]
public sealed class UAMappingContext : OpcLabs.BaseLib.LiveMapping.AbstractMappingContext, System.ICloneable  
[ComVisible(false)]
[CLSCompliant(true)]
public ref class UAMappingContext sealed : public OpcLabs.BaseLib.LiveMapping.AbstractMappingContext, System.ICloneable  
Remarks

 

The mapping context holds information about the state of the mapping process. In OPC Data Access (OPC-DA), the mapping context is represented by an instance of DAMappingContext class. In OPC Unified Architecture (OPC-UA), the mapping context is represented by an instance of UAMappingContext class.

The state of mapping changes in the mapping context, as the mapping process proceeds from your given “starting” object, to its possible constituent objects.

For example, the mapping context contains the information about the OPC server and current OPC node, and parameters for reading and subscription. As the mapping proceeds to deeper level, the properties in the mapping context are propagated to the deeper levels as well, and they change accordingly. For example, if a member is mapped to an OPC-DA node, the NodeDescriptor property of the DAMappingContext changes to reflect the information about the node. If the member represents an OPC branch and contains another object, this new NodeDescriptor will be the basis for mapping the members of the inner object.

Refer to Propagated Parameters for descriptions of attributes that are maintained in the mapping context.

You need to make sure that enough information is provided for the mapping, either through the “starting” mapping context used with the Map method, or by means of the mapping attributes. Typically, for example, the OPC server’s computer and ProgID (or endpoint URL) will not be specified through the mapping attributes, but will come from your code, so that it can be modified in run-time. In OPC-DA, you will therefore create a new DAMappingContext with properly filled ServerDescriptor, and pass it to the Map method. In OPC-UA, you will create a new UAMappingContext with properly filled EndpointDescriptor, and pass it to the Map method.

 

Inheritance Hierarchy

System.Object
   OpcLabs.BaseLib.LiveMapping.AbstractMappingContext
      OpcLabs.EasyOpc.UA.LiveMapping.UAMappingContext

Requirements

Target Platforms: .NET Framework: Windows 10 (selected versions), Windows 11 (selected versions), Windows Server 2016, Windows Server 2022; .NET: Linux, macOS, Microsoft Windows

See Also