Errata exists for this version of the document.
This Method is used to set the SubscribedDataSet to SubscribedDataSetMirrorType used to represents the fields of the DataSet as Variables in the Subscriber Address Space. This Method creates an Object below the SubscribedDataSet and below this Object it creates a Variable Node for every field in the DataSetMetaData.
A Variable representing a field of the DataSet shall be created with the following rules
- TypeDefinition is BaseDataVariableType or a subtype.
- The Reference from the parent Node to the Variable is of type HasComponent.
- The initial AccessLevel of the Variables is CurrentRead.
- The RolePermissions is derived from the parent Node.
- The other Attribute values are taken from the FieldMetaData.
- The properties in the FieldMetaData are created as Properties of the Variable.
- The DataTypes are created in the Subscriber from the DataSetMetaData if they do not exist. The NamespaceUri of the created DataTypes shall match the namespace contained in the DataSetMetaData.
The Client shall be authorized to modify the configuration for the PubSub functionality when invoking this Method on the Server.
Signature
CreateDataSetMirror (
[in]String ParentNodeName
[in]RolePermissionType[]RolePermissions
[out]NodeId ParentNodeId
);
Argument |
Description |
ParentNodeName |
This parameter defines the BrowseName and DisplayName of the parent Node for the Variables representing the fields of the subscribed DataSet. |
RolePermissions |
Value of the RolePermissions Attribute to be set on the parent Node. This value is also used as RolePermissions for all Variables of the DataSet mirror. |
ParentNodeId |
Method Result Codes
ResultCode |
Description |
Bad_InvalidState |
The DataSetReader is not configured yet or the ConfigurationVersion does not match the version in the Publisher. |
Bad_UserAccessDenied |