9.1.4.5.5 AddPublishedEventsTemplate Method

This Method is used to add a PublishedEventsType Object to the DataSetFolderType Object. The configuration parameters provided with this Method are further described in the PublishedEventsType defined in 9.1.4.4.1 and the PublishedDataSetType defined in 9.1.4.2.

The Client shall be authorized to modify the configuration for the PubSub functionality when invoking this Method on the Server.

Signature

	AddPublishedEventsTemplate (
		[in]	String				Name,
		[in]	DataSetMetaDataType		DataSetMetaData,
		[in]	NodeId				EventNotifier,
		[in]	SimpleAttributeOperand[]	SelectedFields,
		[in]	ContentFilter			Filter,
		[out]	NodeId				DataSetNodeId
		);
	
Argument Description
NameName of the Object to create.
DataSetMetaData

The DataSetMetaData predefined by the caller. The initial setting shall not be changed by the Publisher. If the dataSetClassId of the DataSetMetaData is not null, the DataSetClassId Property of the PublishedDataSetType shall be created and initialized with the dataSetClassId value.

The name of the PublishedDataSet Object is defined by the name in the DataSetMetaData.

EventNotifierThe NodeId of the Object in the event notifier tree of the OPC UA Server from which Events are collected.
SelectedFields

The selection of Event Fields contained in the DataSet generated for an Event and sent through the DataSetWriter.

The size of the array shall match the size of the fields array in the DataSetMetaData.

If there is no Event field available for a field in the DataSetMetaData the browsePath field for the SimpleAttributeOperand entry shall be set to null.

The SimpleAttributeOperand DataType is defined in OPC 10000-4.

FilterThe filter applied to the Events. It allows the reduction of the DataSets generated from Events through a filter like filtering for a certain EventType. The ContentFilter DataType is defined in OPC 10000-4.
DataSetNodeId NodeId of the created PublishedDataSets Object.

Method Result Codes

ResultCode Description
Bad_InvalidStateThe current state of the Object does not allow a configuration change.
Bad_NodeIdExistsA DataSet Object with the name already exists.
Bad_NodeIdUnknownThe Event notifier node is not known in the Server.
Bad_EventFilterInvalidThe Event filter is not valid.
Bad_UserAccessDeniedThe Session user is not allowed to configure the Object.
Bad_InvalidArgumentThe Server is not able to apply the Name. The Name may be too long or may contain invalid characters.

Table 262 specifies the AddressSpace representation for the AddPublishedEventsTemplate Method.

Table 262 – AddPublishedEventsTemplate Method AddressSpace definition
Attribute Value
BrowseNameAddPublishedEventsTemplate
References NodeClass BrowseName DataType TypeDefinition ModellingRule
HasPropertyVariableInputArgumentsArgument[] PropertyTypeMandatory
HasPropertyVariableOutputArgumentsArgument[] PropertyTypeMandatory
ConformanceUnits
PubSub Model PublishedDataSet Events