9 Standard Methods

9.1 GetMonitoredItems

GetMonitoredItems is used to get information about monitored items of a subscription. Its intended use is defined in OPC 10000-4.

Signature

	GetMonitoredItems(
		 [in] UInt32 subscriptionId
		 [out] UInt32[] serverHandles
		 [out] UInt32[] clientHandles
		);
Argument Description
subscriptionIdIdentifier of the subscription.
serverHandlesArray of monitoredItemIds (serverHandles) for all MonitoredItems of the Subscription identified by subscriptionId
clientHandlesArray of clientHandles for all MonitoredItems of the Subscription identified by subscriptionId

Method Result Codes (defined in Call Service)

Result Code Description
Bad_SubscriptionIdInvalidDefined in OPC 10000-4
Bad_UserAccessDenied

Defined in OPC 10000-4

The Method was not called in the context of the Session that owns the Subscription.

Table 118 specifies the AddressSpace representation for the GetMonitoredItems Method.

Table 118 – GetMonitoredItems Method AddressSpace definition
Attribute Value
BrowseNameGetMonitoredItems
References NodeClass BrowseName DataType TypeDefinition ModellingRule
HasPropertyVariableInputArgumentsArgument[] PropertyTypeMandatory
HasPropertyVariableOutputArgumentsArgument[] PropertyTypeMandatory
Conformance Units
Base Info ServerType

9.2 ResendData

ResendData is used to get the current values of the data monitored items of a Subscription where the MonitoringMode is set to Reporting. Its intended use is defined in OPC 10000-4.

Signature

	ResendData(
		 [in] UInt32 subscriptionId
		);
Argument Description
subscriptionIdIdentifier of the Subscription to resend.

Method Result Codes (defined in Call Service)

Result Code Description
Bad_SubscriptionIdInvalidDefined in OPC 10000-4
Bad_UserAccessDenied

Defined in OPC 10000-4

The Method was not called in the context of the Session that owns the Subscription.

Table 119 specifies the AddressSpace representation for the ResendData Method.

Table 119 – ResendData Method AddressSpace definition
Attribute Value
BrowseNameResendData
References NodeClass BrowseName DataType TypeDefinition ModellingRule
HasPropertyVariableInputArgumentsArgument[] PropertyTypeMandatory
Conformance Units
Base Info ServerType

9.3 SetSubscriptionDurable

SetSubscriptionDurable Method is used to set a Subscription into a mode where MonitoredItem data and event queues are stored and delivered even if an OPC UA Client was disconnected for a longer time or the OPC UA Server was restarted. Its intended use is defined in OPC 10000-4.

Signature

	SetSubscriptionDurable(
		 [in] UInt32 subscriptionId
		 [in] UInt32 lifetimeInHours
		 [out] UInt32 revisedLifetimeInHours
		);
Argument Description
subscriptionIdIdentifier of the Subscription.
lifetimeInHoursThe requested lifetime in hours for the durable Subscription.
revisedLifetimeInHoursThe revised lifetime in hours the Server applied to the durable Subscription.

Method Result Codes (defined in Call Service)

Result Code Description
Bad_SubscriptionIdInvalidDefined in OPC 10000-4
Bad_InvalidState

Defined in OPC 10000-4

This is returned when a Subscription already contains MonitoredItems.

Bad_UserAccessDenied

Defined in OPC 10000-4

The Method was not called in the context of the Session that owns the Subscription.

Table 120 specifies the AddressSpace representation for the SetSubscriptionDurable Method.

Table 120 – SetSubscriptionDurable Method AddressSpace definition
Attribute Value
BrowseNameSetSubscriptionDurable
References NodeClass BrowseName DataType TypeDefinition ModellingRule
HasPropertyVariableInputArgumentsArgument[] PropertyTypeMandatory
HasPropertyVariableOutputArgumentsArgument[] PropertyTypeMandatory
Conformance Units
Base Info ServerType

9.4 RequestServerStateChange

The Method RequestServerStateChange allows a Client to request a state change in the Server.

The Client shall provide credentials with administrative rights when invoking this Method on the Server.

Signature

	RequestServerStateChange(
		 [in] ServerState state
		 [in] DateTime estimatedReturnTime
		 [in] UInt32 secondsTillShutdown
		 [in] LocalizedText reason
		 [in] Boolean restart
		);
Argument Description
stateThe requested target state for the Server. If the new state is accepted by the Server, the State in the ServerStatus is updated with the new value.
estimatedReturnTime

Indicates the time at which the Server is expected to be available in the state RUNNING_0. If no estimate is known, a null DateTime shall be provided. This time will be available in the EstimatedReturnTime Property.

This parameter shall be ignored by the Server and the Property EstimatedReturnTime shall be set to null if the new state is RUNNING_0.

secondsTillShutdownThe number of seconds until a Server shutdown. This parameter is ignored unless the state is set to SHUTDOWN_4 or restart is set to True.
reasonA localized text string that describes the reason for the state change request.
restartA flag indicating if the Server should be restarted before it attempts to change into the requested change. If the restart is True the server changes it state to SHUTDOWN_4 before the restart if secondsTillShutdown is not 0.

Method Result Codes (defined in Call Service)

Result Code Description
Bad_UserAccessDeniedThe current user is not authorized to invoke the method
Bad_InvalidStateThe requested state was not accepted by the server

Table 121 specifies the AddressSpace representation for the RequestServerStateChange Method.

Table 121 – RequestServerStateChange Method AddressSpace definition
Attribute Value
BrowseNameRequestServerStateChange
References NodeClass BrowseName DataType TypeDefinition ModellingRule
HasPropertyVariableInputArgumentsArgument[] PropertyTypeMandatory
Conformance Units
Base Info ServerType