This Methodis used to add a PublishedEventsType Objectto the DataSetFolderType Object. The configuration parameters passed in with this Methodare further described in the PublishedEventsTypedefined in 9.1.4.4.1and the PublishedDataSetTypedefined in 9.1.4.2.
The settings in the EventNotifier, SelectedFields andFilterare used to configure the data acquisition for the DataSetand are used to initialize the correspondingPropertiesof the PublishedEventsType.
The DataSetMetaDataof the PublishedDataSetTypeis created from meta-data of the selected Eventfields and the settings in FieldNameAliasesand FieldFlags.
The Clientshall be authorized to modify the configuration for the PubSubfunctionality when invoking this Methodon the Server.
Signature
AddPublishedEvents(
[in]String Name
[in]NodeId EventNotifier
[in]String[] FieldNameAliases
[in]DataSetFieldFlags[] FieldFlags
[in]SimpleAttributeOperand[]SelectedFields
[in]ContentFilter Filter
[out]ConfigurationVersionDataTypeConfigurationVersion
[out] NodeId DataSetNodeId
);
Argument |
Description |
Name |
Name of the DataSet Objectto create. |
EventNotifier |
The NodeIdof the Objectin the event notifier tree of the OPC UA Serverthat is used to collect Eventsfrom. |
FieldNameAliases |
The names assigned to the selected fields in the DataSetMetaDataand in the DataSetMessagesfor tagged message encoding. The size and the order of the array shall match the SelectedFields. The string is used to set the name field in the FieldMetaDatathat is part of the DataSetMetaData. |
FieldFlags |
The field flags assigned to the selected fields in the DataSetMetaData. The size and the order of the array shall match the SelectedFields. The flag is used to set the corresponding field in the FieldMetaDatathat is part of the DataSetMetaData. |
SelectedFields |
The selection of Event Fields contained in the DataSetgenerated for an Eventand sent through the DataSetWriter. The SimpleAttributeOperand DataTypeis defined in OPC 10000-4. |
Filter |
The filter applied to the Events. It allows the reduction of the DataSetsgenerated from Eventsthrough a filter like filtering for a certain EventType. The ContentFilter DataTypeis defined in OPC 10000-4. |
ConfigurationVersion |
Returns the initial configuration version of the PublishedDataSets. |
DataSetNodeId |
NodeIdof the created PublishedDataSets Object. |
Method Result Codes
ResultCode |
Description |
Bad_InvalidState |
The current state of the Objectdoes not allow a configuration change. |
Bad_NodeIdExists |
A data set Objectwith the name already exists. |
Bad_NodeIdUnknown |
|
Bad_EventFilterInvalid |
The Eventfilter is not valid. |
Bad_UserAccessDenied |
|
Bad_InvalidArgument |
The Serveris not able to apply the Name. The Namemay be too long or may contain invalid characters. |