High Performance OPC UA Server SDK  1.2.0.193
ua_callmethodresult Struct Reference

A structure that is defined as the type of the results parameter of the Call service. More...

#include <callmethodresult.h>

Data Fields

ua_statuscode status_code
 StatusCode of the method executed in the server. More...
 
ua_statuscodeinput_argument_results
 List of StatusCodes for each inputArgument.
 
int32_t num_input_argument_results
 Number of elements in ua_callmethodresult::input_argument_results.
 
struct ua_diagnosticinfoinput_argument_diag_infos
 List of diagnostic information for each inputArgument. More...
 
int32_t num_input_argument_diag_infos
 Number of elements in ua_callmethodresult::input_argument_diag_infos.
 
struct ua_variantoutput_arguments
 List of output argument values. More...
 
int32_t num_output_arguments
 Number of elements in ua_callmethodresult::output_arguments.
 

Related Functions

void ua_callmethodresult_init (struct ua_callmethodresult *t)
 Initialize an ua_callmethodresult struct with a valid value. More...
 
void ua_callmethodresult_clear (struct ua_callmethodresult *t)
 Clear all resources alloctated in an ua_callmethodresult struct. More...
 
int ua_callmethodresult_compare (const struct ua_callmethodresult *a, const struct ua_callmethodresult *b)
 Compare two ua_callmethodresult structs. More...
 
int ua_callmethodresult_copy (struct ua_callmethodresult *dst, const struct ua_callmethodresult *src)
 Create a copy of a ua_callmethodresult struct. More...
 
static int ua_callmethodresult_resize_input_argument_results_array (struct ua_callmethodresult *val, int32_t new_len)
 Resize the input_argument_results array of a ua_callmethodresult struct. More...
 
static int ua_callmethodresult_resize_input_argument_diag_infos_array (struct ua_callmethodresult *val, int32_t new_len)
 Resize the input_argument_diag_infos array of a ua_callmethodresult struct. More...
 
static int ua_callmethodresult_resize_output_arguments_array (struct ua_callmethodresult *val, int32_t new_len)
 Resize the output_arguments array of a ua_callmethodresult struct. More...
 

Detailed Description

A structure that is defined as the type of the results parameter of the Call service.

Friends And Related Function Documentation

void ua_callmethodresult_clear ( struct ua_callmethodresult t)
related

Clear all resources alloctated in an ua_callmethodresult struct.

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

int ua_callmethodresult_compare ( const struct ua_callmethodresult a,
const struct ua_callmethodresult b 
)
related

Compare two ua_callmethodresult structs.

Compares the content of the ua_callmethodresult struct a to the content of the ua_callmethodresult 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_callmethodresult structs, so it is well suited to not only determine equality, but also sort multiple instances of this struct.

int ua_callmethodresult_copy ( struct ua_callmethodresult dst,
const struct ua_callmethodresult src 
)
related

Create a copy of a ua_callmethodresult struct.

Copy all fields from struct ua_callmethodresult 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_callmethodresult_init ( struct ua_callmethodresult t)
related

Initialize an ua_callmethodresult 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_callmethodresult struct can also be passed to ua_callmethodresult_compare, ua_callmethodresult_copy and ua_callmethodresult_clear. This function will always succeed as long as an ua_callmethodresult struct is passed to it.

static int ua_callmethodresult_resize_input_argument_diag_infos_array ( struct ua_callmethodresult val,
int32_t  new_len 
)
related

Resize the input_argument_diag_infos array of a ua_callmethodresult struct.

Depending on new_len and the current size of the array, the array will be created, increased, decreased or deleted. In case array members are removed these are cleared properly, new array members are initialized with zero.

Parameters
new_lenNew length of the input_argument_diag_infos array in number of members.
Returns
Zero on success or ua_statuscode on failure.
static int ua_callmethodresult_resize_input_argument_results_array ( struct ua_callmethodresult val,
int32_t  new_len 
)
related

Resize the input_argument_results array of a ua_callmethodresult struct.

Depending on new_len and the current size of the array, the array will be created, increased, decreased or deleted. In case array members are removed these are cleared properly, new array members are initialized with zero.

Parameters
new_lenNew length of the input_argument_results array in number of members.
Returns
Zero on success or ua_statuscode on failure.
static int ua_callmethodresult_resize_output_arguments_array ( struct ua_callmethodresult val,
int32_t  new_len 
)
related

Resize the output_arguments array of a ua_callmethodresult struct.

Depending on new_len and the current size of the array, the array will be created, increased, decreased or deleted. In case array members are removed these are cleared properly, new array members are initialized with zero.

Parameters
new_lenNew length of the output_arguments array in number of members.
Returns
Zero on success or ua_statuscode on failure.

Field Documentation

input_argument_diag_infos

List of diagnostic information for each inputArgument.

This list is empty if diagnostics information was not requested in the request header or if no diagnostic information was encountered in processing of the request.

output_arguments

List of output argument values.

An empty list indicates that there are no output arguments. The size and order of this list matches the size and order of the output arguments defined by the OutputArguments Property of the method.

The name, a description and the data type of each argument are defined by the Argument structure in each element of the methods OutputArguments Property.

status_code

StatusCode of the method executed in the server.

This StatusCode is set to the Bad_InvalidArgument StatusCode if at least one input argument broke a constraint (e.g. wrong data type, value out of range).

This StatusCode is set to a bad StatusCode if the method execution failed in the server, e.g. based on an exception or an HRESULT.


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