ConfigureSerialization is an optional Method to set the SerializationProperties of the parent SerializationEntity.

The DI:LockingServicesType is an AddIn defined in OPC 10000-100. This AddIn shall be added as instance with the instance name “Lock” if the Server implements the ConfigureSerialization Method.

Before invoking this Method, Clients shall lock the SerializationEntity using the Lock Object instance.

When successful, the Server will create a new DataType for the SerializedData Variable with the DataTypeDefinition Attribute for the metadata and encoding information.

The signature of this Method is specified below. Table 3 and Table 4 specify the arguments and AddressSpace representation, respectively.

Signature

ConfigureSerialization (

[in]KeyValuePair[]SerializationFilterProperties,

[out]Int32[] Results

);

Table 3 – ConfigureSerialization Method arguments

Argument

Description

SerializationFilterProperties

Array of KeyValuePair Structures containing the desired settings. The key field of each Structure contains the BrowseName of a serialization filter Property. The value field contains the desired value to set for this component and must have the same DataType as the serialization filter Property.

A Property can be reset by setting the default Value for the Property.

Results

List of results for the Properties to set (see below). The size and order of the list matches the size and order of the SerializationFilterProperties argument. There is one entry in this list for each Property contained in the SerializationFilterProperties argument.

This array is empty if the Method execution was successful (Method result code Good).

Possible result values.

0 – OK

-1 – E_InvalidProperty – the Property name is unknown

-2 – E_Duplicate – the Property is not unique in SerializationFilterProperties

-3 – E_NotConfigurable – the Property cannot be changed

-4 – E_InvalidType – the DataType is not the same as the one of the Property

-5 – E_UnknownValue – the value provided is not appropriate for the Property

-6 – E_InvalidSetting – the value provided is not allowed as serialization filter

An example is that non-hierarchical References are not allowed to be included

Table 4 – ConfigureSerialization Method AddressSpace definition

Attribute

Value

BrowseName

ConfigureSerialization

References

NodeClass

BrowseName

DataType

TypeDefinition

Other

HasProperty

Variable

InputArguments

Argument[]

PropertyType

M

HasProperty

Variable

OutputArguments

Argument[]

PropertyType

M

Conformance Units

ObjectSerialization Configuration Support

The Method result codes (defined in Call Service) are defined in Table 5. The configuration is applied if a result code with severity Good is returned. Otherwise, no Property is changed.

Table 5 – Possible Method Result Codes

Result Code

Description

Good

The Method execution was successful. The Results array is empty.

Uncertain

The Server is not able to apply the requested changes due to invalid parameters.

The Results argument provides more details.

Bad_InvalidArgument

The SerializationFilterProperties argument array is empty.

Bad_Locked

The SerializationEntity is locked by a different Client’s Session.

Bad_RequiresLock

The SerializationEntity is not locked. Clients must lock the SerializationEntity before invoking a Method.

Bad_UserAccessDenied

The user has not the right to execute the Method.

Bad_UnexpectedError

The Server is not able to execute the function because an unexpected error occurred.

If the desired settings do not deviate from the actual settings, the Method shall do nothing and return Good as result code.