High Performance OPC UA Server SDK  1.2.0.193
ua_writevalue Struct Reference

A structure that is defined as the type of the nodesToWrite parameter of the Write service. More...

#include <writevalue.h>

Data Fields

struct ua_nodeid node_id
 NodeId of the node that contains the attributes.
 
uint32_t attribute_id
 Id of the attribute. More...
 
struct ua_string index_range
 This parameter is used to identify a single element of an array, or a single range of indexes for arrays. More...
 
struct ua_datavalue value
 The node’s attribute value. More...
 

Related Functions

void ua_writevalue_init (struct ua_writevalue *t)
 Initialize an ua_writevalue struct with a valid value. More...
 
void ua_writevalue_clear (struct ua_writevalue *t)
 Clear all resources alloctated in an ua_writevalue struct. More...
 
int ua_writevalue_compare (const struct ua_writevalue *a, const struct ua_writevalue *b)
 Compare two ua_writevalue structs. More...
 
int ua_writevalue_copy (struct ua_writevalue *dst, const struct ua_writevalue *src)
 Create a copy of a ua_writevalue struct. More...
 

Detailed Description

A structure that is defined as the type of the nodesToWrite parameter of the Write service.

Friends And Related Function Documentation

void ua_writevalue_clear ( struct ua_writevalue t)
related

Clear all resources alloctated in an ua_writevalue struct.

Frees allocated memory like arrays and resets numeric values. The ua_writevalue struct itself is not freed and must be freed by the caller if required. This function always succeeds for a valid ua_writevalue struct, that was validly decoded, initilized by ua_writevalue_init or created with ua_writevalue_copy.

int ua_writevalue_compare ( const struct ua_writevalue a,
const struct ua_writevalue b 
)
related

Compare two ua_writevalue structs.

Compares the content of the ua_writevalue struct a to the content of the ua_writevalue struct b. If a is smaller than b, an integer less than zero is returned, if a is bigger than b, an integer greater than zero is returned. If both structs are equal zero is returned.

This function creates a total order on ua_writevalue structs, so it is well suited to not only determine equality, but also sort multiple instances of this struct.

int ua_writevalue_copy ( struct ua_writevalue dst,
const struct ua_writevalue src 
)
related

Create a copy of a ua_writevalue struct.

Copy all fields from struct ua_writevalue src to dst. Creates a deep copy so all content is recusively copied and both src and dst can be used and must be freed separately.

dst is not cleared before the copy operation, so it must not have any allocated data. It may or may not be initilized by the caller before copy.

Returns
Zero on success or ua_statuscode on failure.
void ua_writevalue_init ( struct ua_writevalue t)
related

Initialize an ua_writevalue struct with a valid value.

After initialization the fields of the struct are set to valid and consistent values and can safley be accessed. An initialized ua_writevalue struct can also be passed to ua_writevalue_compare, ua_writevalue_copy and ua_writevalue_clear. This function will always succeed as long as an ua_writevalue struct is passed to it.

Field Documentation

attribute_id

Id of the attribute.

This shall be a valid attribute id.

The IntegerIds for the Attributes are defined in NodeAttributesMask.

index_range

This parameter is used to identify a single element of an array, or a single range of indexes for arrays.

The first element is identified by index 0 (zero).

This parameter is not used if the specified attribute is not an array. However, if the specified attribute is an array and this parameter is not used, then all elements are to be included in the range. The parameter is null if not used.

value

The node’s attribute value.

If the indexRange parameter is specified, the Value shall be an array even if only one element is being written.

If the SourceTimestamp or the ServerTimestamp is specified, the Server shall use these values. The Server returns a Bad_WriteNotSupported error if it does not support writing of timestamps.

A Server shall return a Bad_TypeMismatch error if the data type of the written value is not the same type or subtype as the attribute’s DataType. Based on the DataType hierarchy, subtypes of the attribute DataType shall be accepted by the Server. For the value attribute the DataType is defined through the DataType attribute. A ByteString is structurally the same as a one dimensional array of Byte. A Server shall accept a ByteString if an array of Byte is expected.

The Server returns a Bad_DataEncodingUnsupported error if it does not support writing of the passed data encoding.


The documentation for this struct was generated from the following files: