High Performance OPC UA Server SDK  1.7.1.383

Save/load namespaces to/from file. More...

Functions

SERVER_EXPORT int ua_addressspace_load_file (const char *filename, void *store, const struct ua_addressspace_config *add)
 Loads a binary address space file. More...
 
SERVER_EXPORT int ua_addressspace_load_file_ext (const char *filename, void *store, const struct ua_addressspace_config *add, struct ua_file_callbacks *cb)
 Loads a binary address space file. More...
 
SERVER_EXPORT int ua_addressspace_add_structuredefinition (ua_node_t node, struct ua_structuredefinition *def)
 
SERVER_EXPORT int ua_addressspace_add_enumdefinition (ua_node_t node, struct ua_enumdefinition *def)
 

Detailed Description

Save/load namespaces to/from file.

Function Documentation

◆ ua_addressspace_load_file()

SERVER_EXPORT int ua_addressspace_load_file ( const char *  filename,
void *  store,
const struct ua_addressspace_config add 
)

Loads a binary address space file.

This is a wrapper for ua_addressspace_load_file_ext and kept for backwards compatibility.

Parameters
filenameFilename of file to load.
storeA value store implementation. You can use any store implementation like for example the static store. This parameter must not be NULL.
addAdditional memory to add to the memory pools created for this address space. This argument may be NULL if no additional memory is needed.
Returns
Returns the assigned namespace index on success or -1 on failure.

◆ ua_addressspace_load_file_ext()

SERVER_EXPORT int ua_addressspace_load_file_ext ( const char *  filename,
void *  store,
const struct ua_addressspace_config add,
struct ua_file_callbacks cb 
)

Loads a binary address space file.

Parameters
filenameFilename of file to load.
storeA value store implementation. You can use any store implementation like for example the static store. This parameter must not be NULL.
addAdditional memory to add to the memory pools created for this address space. This argument may be NULL if no additional memory is needed.
cbCalltable with different optional callbacks that can be used to get more information about the file. Unused callbacks are initialized with NULL by using ua_file_callbacks_init. So this table can be extended over time without breaking existing code. This parameter must not be NULL.
Returns
Returns the assigned namespace index on success or -1 on failure.