OPC UA (CVOpcUa.dll) 14.0
OpcUa Node Functions

Typedefs

typedef void * CVOPCNODE
 Handle of an OPCUA Node object. More...
 

Functions

CVOPCNODE CreateCVOPCMethod (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent)
 Creates an OPCUA Method Node with the specified parameter. More...
 
CVOPCNODE CreateCVOPCMethodW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent)
 Creates an OPCUA Method Node with the specified parameter. More...
 
CVOPCNODE CreateCVOPCObject (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent)
 Creates an OPCUA Object with the specified parameter. More...
 
CVOPCNODE CreateCVOPCObjectFromType (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, CVOPCNODEID TypeDefinition)
 Creates an OPCUA Object with the specified parameter and the type definition. More...
 
CVOPCNODE CreateCVOPCObjectFromTypeW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, CVOPCNODEID TypeDefinition)
 Creates an OPCUA Object with the specified parameter and the type definition. More...
 
CVOPCNODE CreateCVOPCObjectType (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, TCVOPCAbstractDataType IsAbstract)
 Creates an OPCUA ObjectType with the specified parameter. More...
 
CVOPCNODE CreateCVOPCObjectTypeW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, TCVOPCAbstractDataType IsAbstract)
 Creates an OPCUA ObjectType with the specified parameter. More...
 
CVOPCNODE CreateCVOPCObjectW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent)
 Creates an OPCUA Object with the specified parameter. More...
 
CVOPCNODE CreateCVOPCVariableFloat (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, double Value)
 Creates an OPCUA Variable with the specified parameter, data type and set its value as double. More...
 
CVOPCNODE CreateCVOPCVariableFloatW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, double Value)
 Creates an OPCUA Variable with the specified parameter, data type and sets its value as double. More...
 
CVOPCNODE CreateCVOPCVariableFromType (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, CVOPCNODEID TypeDefinition)
 Creates an OPCUA Variable with the specified parameter and type definition. More...
 
CVOPCNODE CreateCVOPCVariableFromTypeW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, CVOPCNODEID TypeDefinition)
 Creates an OPCUA Variable with the specified parameter and type definition. More...
 
CVOPCNODE CreateCVOPCVariableInteger (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, cvbint64_t Value)
 Creates an OPCUA Variable with the specified parameter, data type and set its value as int64. More...
 
CVOPCNODE CreateCVOPCVariableIntegerW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, cvbint64_t Value)
 Creates an OPCUA Variable with the specified parameter, data type and set its value as int64. More...
 
CVOPCNODE CreateCVOPCVariableString (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, const char *Value)
 Creates an OPCUA Variable with the specified parameter, data type and C string value. More...
 
CVOPCNODE CreateCVOPCVariableStringW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, TCVOPCVarType VarType, TCVOPCDataType DataType, const wchar_t *Value)
 Creates an OPCUA Variable with the specified parameter, data type and value as wide C string. More...
 
CVOPCNODE CreateCVOPCVariableType (cvbuint16_t NameSpaceIndex, const char *Name, CVOPCNODEID Parent, TCVOPCAbstractDataType IsAbstract)
 Creates an OPCUA VariableType with the specified parameter. More...
 
CVOPCNODE CreateCVOPCVariableTypeW (cvbuint16_t NameSpaceIndex, const wchar_t *Name, CVOPCNODEID Parent, TCVOPCAbstractDataType IsAbstract)
 Creates an OPCUA VariableType with the specified parameter. More...
 
cvbres_t CVOPCGetAttributeIdDataType (TCVOPCAttributeId AttributeId, TCVOPCDataType &dataType)
 Returns the dataType of a specific node attribute. More...
 
cvbres_t CVOPCNodeAddMethodArgAsFloat (CVOPCNODE Method, const char *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, double Value)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as double. More...
 
cvbres_t CVOPCNodeAddMethodArgAsFloatW (CVOPCNODE Method, const wchar_t *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, double DefaultValue)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as double. More...
 
cvbres_t CVOPCNodeAddMethodArgAsInteger (CVOPCNODE Method, const char *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, cvbint64_t Value)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as int64. More...
 
cvbres_t CVOPCNodeAddMethodArgAsIntegerW (CVOPCNODE Method, const wchar_t *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, cvbint64_t DefaultValue)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as int64. More...
 
cvbres_t CVOPCNodeAddMethodArgAsString (CVOPCNODE Method, const char *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, const char *Value)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as C String. More...
 
cvbres_t CVOPCNodeAddMethodArgAsStringW (CVOPCNODE Method, const wchar_t *ArgumentName, TCVOPCArgumentType ArgumentType, TCVOPCDataType DataType, const wchar_t *DefaultValue)
 Adds Argument with defined DataType to OPCUA Method. Initial value is set as wide C String. More...
 
cvbres_t CVOPCNodeAddReference (CVOPCNODE Source, CVOPCNODEID Destination, TCVOPCReferenceType Reference, TCVOPCReferenceDirection IsForward)
 Adds a reference to the OPCUA Server. More...
 
cvbres_t CVOPCNodeBrowse (CVOPCNODE StartingNode, TCVOPCBrowseFilter *browseFilter, CVOPCBROWSERESULT &BrowseList)
 Browse the children of a given OPCUA Node present in the OPCUA Server which is connected to a given OPCUA Client. More...
 
cvbres_t CVOPCNodeCallMethod (CVOPCNODE Method)
 Calls an OPCUA Method of an OPCUA Server which is connected via an OPCUA Client. More...
 
cvbres_t CVOPCNodeGetAttributeAsFloat (CVOPCNODE Node, TCVOPCAttributeId AttributeId, double &Attribute)
 Gets the selected Attribute of an OPCUA Node object as double value. More...
 
cvbres_t CVOPCNodeGetAttributeAsInteger (CVOPCNODE Node, TCVOPCAttributeId AttributeId, cvbint64_t &Attribute)
 Gets the selected Attribute of an OPCUA Node object as int64 value. More...
 
cvbres_t CVOPCNodeGetAttributeAsString (CVOPCNODE Node, TCVOPCAttributeId AttributeId, char *Attribute, size_t &AttributeSize)
 Gets the selected Attribute of an OPCUA Node object as C string. More...
 
cvbres_t CVOPCNodeGetAttributeAsStringW (CVOPCNODE Node, TCVOPCAttributeId AttributeId, wchar_t *Attribute, size_t &AttributeSize)
 Gets the selected Attribute of an OPCUA Node object as wide C string. More...
 
cvbres_t CVOPCNodeGetConnectionStatus (CVOPCNODE Node, TCVOPCConnectionStatus &ConnectionStatus)
 Gets the #TOpcConnectionStatus connections status of an OPCUA Node object. More...
 
cvbres_t CVOPCNodeGetMethodArgAsFloat (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, double &Value)
 Gets the given OPCUA Method Argument value as double. More...
 
cvbres_t CVOPCNodeGetMethodArgAsInteger (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, cvbint64_t &Value)
 Gets the given OPCUA Method Argument value as int64. More...
 
cvbres_t CVOPCNodeGetMethodArgAsString (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, char *Value, size_t &ValueSize)
 Gets the given OPCUA Method Argument value as C string. More...
 
cvbres_t CVOPCNodeGetMethodArgAsStringW (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, wchar_t *Value, size_t &ValueSize)
 Gets the given OPCUA Method Argument value as wide C string. More...
 
cvbres_t CVOPCNodeGetMethodArgCount (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t &ArgumentCount)
 Gets the number of input or output Arguments in the given OPCUA Method. More...
 
cvbres_t CVOPCNodeGetMethodArgDataType (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, TCVOPCDataType &DataClass)
 Queries the data class (integer, float or string) of the selected input or output argument of a given OPCUA Method. More...
 
cvbres_t CVOPCNodeGetNodeClass (CVOPCNODE Node, TCVOPCNodeClass &NodeClass)
 Gets the OPCUA NodeClass of an OPCUA Node object. More...
 
cvbres_t CVOPCNodeGetNodeId (CVOPCNODE Node, CVOPCNODEID &NodeId)
 Gets the OPCUA DataType of an OPCUA Node object. More...
 
cvbres_t CVOPCNodeSetAttributeAsFloat (CVOPCNODE Node, TCVOPCAttributeId AttributeId, double Attribute)
 Sets the selected Attribute of an OPCUA Node object as a double. More...
 
cvbres_t CVOPCNodeSetAttributeAsInteger (CVOPCNODE Node, TCVOPCAttributeId AttributeId, cvbint64_t Attribute)
 Sets the selected Attribute of an OPCUA Node object as an int64 . More...
 
cvbres_t CVOPCNodeSetAttributeAsString (CVOPCNODE Node, TCVOPCAttributeId AttributeId, const char *Attribute)
 Sets the selected Attribute of an OPCUA Node object as a C string . More...
 
cvbres_t CVOPCNodeSetAttributeAsStringW (CVOPCNODE Node, TCVOPCAttributeId AttributeId, const wchar_t *Attribute)
 Sets the selected Attribute of an OPCUA Node object as wide C string. More...
 
cvbres_t CVOPCNodeSetMethodArgAsFloat (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, double Value)
 Sets the given OPCUA Method Argument value as double. More...
 
cvbres_t CVOPCNodeSetMethodArgAsInteger (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, cvbint64_t Value)
 Sets the given OPCUA Method Argument value as int64. More...
 
cvbres_t CVOPCNodeSetMethodArgAsString (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, const char *Value)
 Sets the given OPCUA Method Argument value as wide C string. More...
 
cvbres_t CVOPCNodeSetMethodArgAsStringW (CVOPCNODE Method, TCVOPCArgumentType ArgumentType, size_t position, const wchar_t *Value)
 Sets the given OPCUA Method Argument value as wide C string. More...
 
cvbres_t CVOPCNodeSetModelingRule (CVOPCNODE Node, TCVOPCModRule ModellingRule)
 Sets the OPCUA Modelling Rule of an OPCUA Node object. More...
 
cvbres_t CVOPCNodeSetParentReference (CVOPCNODE Node, TCVOPCReferenceType Reference)
 Sets the parent's reference type of an OPCUA Node object. More...
 
cvbres_t CVOpcNSetNodeId (CVOPCNODE Node, CVOPCNODEID NodeId)
 Sets the OPCUA NodeId of an OPCUA Node object. More...
 
cvbres_t CVOpcNSetVDataClass (CVOPCNODE VariableOrType, TCVOPCDataType DataType)
 Sets the OPCUA DataType of an OPCUA Variable or VariableType object. More...
 
cvbbool_t IsCVOPCNode (CVOPCNODE Node)
 Checks if handle is valid and points to OPCUA Node. More...
 

Detailed Description

Functions to create and access OPCUA Node objects and its attributes. Available node classes are Variable, Object, Method, VariableType and ObjectType. Variables and Objects could be instantiated. Methods are always linked to one object. VariableTypes and ObjectTypes could be used a model for Variables and Object instances.

Typedef Documentation

◆ CVOPCNODE

Handle of an OPCUA Node object.

The following node attributes cannot be changed once a node has been created:

  • NodeClass
  • NodeId
  • Symmetric
  • ContainsNoLoop

The following attributes cannot be written from the server (but from the client), as they are specific to the different users:

  • UserWriteMask
  • UserAccessLevel
  • UserExecutable

Historizing is currently unsupported

Note
OPCUA nodes are available for different node classes (for details refer to:
https://opcfoundation.org/developer-tools/specifications-unified-architecture/part-3-address-space-model/
for details)

CVOPCNODE objects are reference counted. If one is not needed anymore call the ReleaseObject function of the CVCImg.dll. It is recommended to call the ShareObject function in a program unit (like a class or function) when a handle is set and call ReleaseObject when the handle is not needed anymore.

Function Documentation

◆ CreateCVOPCMethod()

CVOPCNODE CreateCVOPCMethod ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent 
)

Creates an OPCUA Method Node with the specified parameter.

Note
The default method does not contain arguments. This need to be added by #OpcNAddMArgAsInteger, #OpcNAddMArgAsFloat or #OpcNAddMArgAsString. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterMCallback.
Attention
Always use initialized OPCUA Method Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Method Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Method should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Method.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Method to be created belongs to.
Returns
  • #OPCNODE Handle of OPCUA Method Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCMethodW()

CVOPCNODE CreateCVOPCMethodW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent 
)

Creates an OPCUA Method Node with the specified parameter.

Note
The default method does not contain arguments. This need to be added by #OpcNAddMArgAsInteger, #OpcNAddMArgAsFloat or #OpcNAddMArgAsString. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterMCallback.
Attention
Always use initialized OPCUA Method Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Method Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Method should belong to.
[in]NameWide C String literal for non-localized, human-readable name of an OPCUA Method.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Method to be created belongs.
Returns
  • #OPCNODE Handle of OPCUA Method Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObject()

CVOPCNODE CreateCVOPCObject ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent 
)

Creates an OPCUA Object with the specified parameter.

Note
This function is intended to create an OPCUA Object with a type definition that differs from OPCUA BaseVariableType. Most of the more complex OPCUA VariableTypes do have any data value but hold other variables as properties. Further, the default reference type is OPCUA HasComponenent.
Attention
Always use initialized OPCUA Object objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Object Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Object should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Object.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Object to be created belongs to.
Returns
  • #OPCNODE Handle of OPCUA Object Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObjectFromType()

CVOPCNODE CreateCVOPCObjectFromType ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
CVOPCNODEID  TypeDefinition 
)

Creates an OPCUA Object with the specified parameter and the type definition.

Note
The OPCUA Object which is created by this function has the default type definition OPCUA BaseObjectType. Depending on the type definition the OPCUA Object might hold references to other OPCUA Objects, Variables and Methods. Further, the default reference type is OPCUA HasComponenent.
Attention
Always use initialized OPCUA Object objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Object Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Object should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Object.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Object to be created belongs to.
Returns
  • #OPCNODE Handle of OPCUA Object Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObjectFromTypeW()

CVOPCNODE CreateCVOPCObjectFromTypeW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
CVOPCNODEID  TypeDefinition 
)

Creates an OPCUA Object with the specified parameter and the type definition.

Note
The OPCUA Object which is created by this function has the default type definition OPCUA BaseObjectType. Depending on the type definition the OPCUA Object might hold references to other OPCUA Objects, Variables and Methods. Further, the default reference type is OPCUA HasComponenent.
Attention
Always use initialized OPCUA Object objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Object Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Object should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Object.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Object to be created belongs to.
Returns
  • #OPCNODE Handle of OPCUA Object Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObjectType()

CVOPCNODE CreateCVOPCObjectType ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
TCVOPCAbstractDataType  IsAbstract 
)

Creates an OPCUA ObjectType with the specified parameter.

Attention
Always use initialized OPCUA ObjectType objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA ObjectType Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA ObjectType should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA VariableType.
[in]ParentOPCUA NodeId of the parent to which the OPCUA ObjectType to be created belongs.
[in]IsAbstractBoolean which defines the OPCUA ObjectType to be abstract if TRUE
Returns
  • #OPCNODE Handle of OPCUA ObjectType Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObjectTypeW()

CVOPCNODE CreateCVOPCObjectTypeW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
TCVOPCAbstractDataType  IsAbstract 
)

Creates an OPCUA ObjectType with the specified parameter.

Attention
Always use initialized OPCUA ObjectType objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA ObjectType Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA ObjectType should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA VariableType.
[in]ParentOPCUA NodeId of the parent to which the OPCUA ObjectType to be created belongs.
[in]IsAbstractBoolean which defines the OPCUA ObjectType to be abstract if TRUE
Returns
  • #OPCNODE Handle of OPCUA ObjectType Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCObjectW()

CVOPCNODE CreateCVOPCObjectW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent 
)

Creates an OPCUA Object with the specified parameter.

Note
This function is intended to create an OPCUA Object with a type definition that differs from OPCUA BaseVariableType. Most of the more complex OPCUA VariableTypes do have any data value but hold other variables as properties. Further, the default reference type is OPCUA HasComponenent.
Attention
Always use initialized OPCUA Object objects and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Object Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Object should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA Object.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Object to be created belongs to.
Returns
  • #OPCNODE Handle of OPCUA Object Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableFloat()

CVOPCNODE CreateCVOPCVariableFloat ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
double  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and set its value as double.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Node. This string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Variable to be created.
[in]ValueSets the value of the OPCUA Variable as double.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableFloatW()

CVOPCNODE CreateCVOPCVariableFloatW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
double  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and sets its value as double.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA Node. This wide string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Variable to be created.
[in]ValueSets the value of the OPCUA Variable as double.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableFromType()

CVOPCNODE CreateCVOPCVariableFromType ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
CVOPCNODEID  TypeDefinition 
)

Creates an OPCUA Variable with the specified parameter and type definition.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Node. This string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]TypeDefinitionType definition that is used to instantiate the OPCUA Node.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableFromTypeW()

CVOPCNODE CreateCVOPCVariableFromTypeW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
CVOPCNODEID  TypeDefinition 
)

Creates an OPCUA Variable with the specified parameter and type definition.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA Node. This wide string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]TypeDefinitionType definition that is used to instantiate the OPCUA Node.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableInteger()

CVOPCNODE CreateCVOPCVariableInteger ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
cvbint64_t  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and set its value as int64.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Node. This string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Node to be created.
[in]ValueSets the value of the OPCUA Variable as int64.
Returns

◆ CreateCVOPCVariableIntegerW()

CVOPCNODE CreateCVOPCVariableIntegerW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
cvbint64_t  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and set its value as int64.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA Node. This wide string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Node to be created.
[in]ValueSets the value of the OPCUA Variable as int64.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableString()

CVOPCNODE CreateCVOPCVariableString ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
const char *  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and C string value.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA Node. This string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Node to be created.
[in]ValueSets the value of the OPCUA Variable as C string.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableStringW()

CVOPCNODE CreateCVOPCVariableStringW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
TCVOPCVarType  VarType,
TCVOPCDataType  DataType,
const wchar_t *  Value 
)

Creates an OPCUA Variable with the specified parameter, data type and value as wide C string.

Note
The OPCUA Node which is created by this function has the default type definition OPCUA BaseVariableType. Further, the default reference type is OPCUA HasComponenent. Callbacks could be registered once the node has been added with #OpcServerAddNode to a Server with #OpcServerRegisterVCallback or directly by adding the Variable with #OpcServerAddVariable.
Attention
Always use initialized OPCUA Variable Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA Variable Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA Node should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA Node. This wide string must be 0 terminated.
[in]ParentOPCUA NodeId of the parent to which the OPCUA Node to be created belongs.
[in]VarTypeOPCUA Node Type for the OPCUA Node to created.
[in]DataTypeData type definition of the OPCUA Node to be created.
[in]ValueSets the value of the OPCUA Variable as wide C string.
Returns
  • #OPCNODE Handle of OPCUA Variable Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableType()

CVOPCNODE CreateCVOPCVariableType ( cvbuint16_t  NameSpaceIndex,
const char *  Name,
CVOPCNODEID  Parent,
TCVOPCAbstractDataType  IsAbstract 
)

Creates an OPCUA VariableType with the specified parameter.

Attention
Always use initialized OPCUA VariableType Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA VariableType Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA VariableType should belong to.
[in]NameString literal for non-localized, human-readable name of an OPCUA VariableType.
[in]ParentOPCUA NodeId of the parent to which the OPCUA VariableType to be created belongs.
[in]IsAbstractBoolean which defines the OPCUA VariableType to be abstract if TRUE
Returns
  • #OPCNODE Handle of OPCUA VariableType Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CreateCVOPCVariableTypeW()

CVOPCNODE CreateCVOPCVariableTypeW ( cvbuint16_t  NameSpaceIndex,
const wchar_t *  Name,
CVOPCNODEID  Parent,
TCVOPCAbstractDataType  IsAbstract 
)

Creates an OPCUA VariableType with the specified parameter.

Attention
Always use initialized OPCUA VariableType Nodes and initialize unused handles with nullptr. Use only initialized parameters to create OPCUA VariableType Nodes.
Parameters
[in]NameSpaceIndexIndex of the namespace where the OPCUA VariableType should belong to.
[in]NameWide C string literal for non-localized, human-readable name of an OPCUA VariableType.
[in]ParentOPCUA NodeId of the parent to which the OPCUA VariableType to be created belongs.
[in]IsAbstractBoolean which defines the OPCUA VariableType to be abstract if TRUE
Returns
  • #OPCNODE Handle of OPCUA VariableType Node.
  • nullptr on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCGetAttributeIdDataType()

cvbres_t CVOPCGetAttributeIdDataType ( TCVOPCAttributeId  AttributeId,
TCVOPCDataType &  dataType 
)

Returns the dataType of a specific node attribute.

Parameters
[in]AttributeIdIdentifier for the attribute which data type is queried.
[out]TCVOpcDataTypeData type of the selected attribute.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsFloat()

cvbres_t CVOPCNodeAddMethodArgAsFloat ( CVOPCNODE  Method,
const char *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
double  Value 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as double.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameString literal for human-readable name of the argument. This string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueSets default value of the Argument as double.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsFloatW()

cvbres_t CVOPCNodeAddMethodArgAsFloatW ( CVOPCNODE  Method,
const wchar_t *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
double  DefaultValue 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as double.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameWide string literal for human-readable name of the argument. This wide string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueSets default value of the Argument as double.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsInteger()

cvbres_t CVOPCNodeAddMethodArgAsInteger ( CVOPCNODE  Method,
const char *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
cvbint64_t  Value 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as int64.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameString literal for human-readable name of the argument. This string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueSets default value of the Argument as int64.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsIntegerW()

cvbres_t CVOPCNodeAddMethodArgAsIntegerW ( CVOPCNODE  Method,
const wchar_t *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
cvbint64_t  DefaultValue 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as int64.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameWide string literal for human-readable name of the argument. This wide string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueSets default value of the Argument as int64.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsString()

cvbres_t CVOPCNodeAddMethodArgAsString ( CVOPCNODE  Method,
const char *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
const char *  Value 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as C String.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameString literal for human-readable name of the argument. This string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueString Sets default value of the Argument as C String.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddMethodArgAsStringW()

cvbres_t CVOPCNodeAddMethodArgAsStringW ( CVOPCNODE  Method,
const wchar_t *  ArgumentName,
TCVOPCArgumentType  ArgumentType,
TCVOPCDataType  DataType,
const wchar_t *  DefaultValue 
)

Adds Argument with defined DataType to OPCUA Method. Initial value is set as wide C String.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object where the Argument should be added.
[in]ArgumentNameWide String literal for human-readable name of the argument. This wide string must be 0 terminated.
[in]ArgumentTypeDefines if argument is used as input or output.
[in]DataTypeOPCUA DataType of the OPCUA Method Argument.
[in]ValueString Sets default value of the Argument as wide C String.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeAddReference()

cvbres_t CVOPCNodeAddReference ( CVOPCNODE  Source,
CVOPCNODEID  Destination,
TCVOPCReferenceType  Reference,
TCVOPCReferenceDirection  IsForward 
)

Adds a reference to the OPCUA Server.

Note
References define relations between OPCUA Nodes. It is possible to have multiple references in between nodes.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]SourceOPCUA Node that is the source of the reference.
[in]DestinationOPCUA Node that is the destination of the reference.
[in]ReferenceOPCUA Reference of a certain ReferenceType that defines the relationship between two nodes.
[in]IsForwardBoolean flag that defines if the reference is forward reference or backward reference.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeBrowse()

cvbres_t CVOPCNodeBrowse ( CVOPCNODE  StartingNode,
TCVOPCBrowseFilter *  browseFilter,
CVOPCBROWSERESULT &  BrowseList 
)

Browse the children of a given OPCUA Node present in the OPCUA Server which is connected to a given OPCUA Client.

Note
Only the children of the OPCUA Starting Node are browsed. This is a one level browse.
Attention
The OPCUA Client must be connected to an OPCUA Server to succeed.
Parameters
[in]ClientOPCUA Client handle.
[in]StartingNodeOPCUA NodeId of the OPCUA Node where the browse operation should start.
[in]DepthDepth of the browse operation on the address space node set is limited to this parameter.
[in]MaxResultsMaximum number of nodes that will be returned from the browse operation.
[out]BrowseListReference to BrowseList object that contains the result of the browse operation.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if either Client or StartingNode are not a valid objects.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeCallMethod()

cvbres_t CVOPCNodeCallMethod ( CVOPCNODE  Method)

Calls an OPCUA Method of an OPCUA Server which is connected via an OPCUA Client.

Note
If the OPCUA Method has Input Argument, the Input Argument should be set to the desired values before calling this function. If not Input Arguments are set the default values will be used. The result of this operation updates the Output Arguments which are part of the OPCUA Method object.
Parameters
[in]ClientOPCUA Client handle.
[in]MethodNodeIdOPCUA NodeId that uniquely identifies the OPCUA Method.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if either Client or Method are not a valid object.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetAttributeAsFloat()

cvbres_t CVOPCNodeGetAttributeAsFloat ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
double &  Attribute 
)

Gets the selected Attribute of an OPCUA Node object as double value.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be read.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[out]AttributeReference to variable in which the current Attribute of the OPCUA Node is written.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_Float.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetAttributeAsInteger()

cvbres_t CVOPCNodeGetAttributeAsInteger ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
cvbint64_t &  Attribute 
)

Gets the selected Attribute of an OPCUA Node object as int64 value.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be read.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[out]AttributeReference to variable in which the current Attribute of the OPCUA Node is written.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_Integer.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetAttributeAsString()

cvbres_t CVOPCNodeGetAttributeAsString ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
char *  Attribute,
size_t &  AttributeSize 
)

Gets the selected Attribute of an OPCUA Node object as C string.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be read.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]Attributechar buffer to be filled with queried information; nullptr for size query.
[in,out]]AttributeSize Gives the buffer size of Attribute or receives the minimal needed size (including the terminating zero in either case) if Attribute is NULL.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_String.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetAttributeAsStringW()

cvbres_t CVOPCNodeGetAttributeAsStringW ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
wchar_t *  Attribute,
size_t &  AttributeSize 
)

Gets the selected Attribute of an OPCUA Node object as wide C string.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be read.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]AttributeWide char buffer to be filled with queried information; nullptr for size query.
[in,out]]AttributeSize Gives the buffer size of Attribute or receives the minimal needed size (including the terminating zero in either case) if Attribute is NULL.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_String.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetConnectionStatus()

cvbres_t CVOPCNodeGetConnectionStatus ( CVOPCNODE  Node,
TCVOPCConnectionStatus &  ConnectionStatus 
)

Gets the #TOpcConnectionStatus connections status of an OPCUA Node object.

Note
Checks whether the OPCUA node object is connected to an OPCUA Server, OPCUA Client or not.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be read.
[out]NodeClassOPCUA NodeId of the given OPCUA Node.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgAsFloat()

cvbres_t CVOPCNodeGetMethodArgAsFloat ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
double &  Value 
)

Gets the given OPCUA Method Argument value as double.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[out]ValueReference to variable in which the current value of the selected OPCUA Method Argument is written.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]DataClassdata class (integer, float or string)
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_Float
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgAsInteger()

cvbres_t CVOPCNodeGetMethodArgAsInteger ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
cvbint64_t &  Value 
)

Gets the given OPCUA Method Argument value as int64.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[out]ValueReference to variable in which the current value of the selected OPCUA Method Argument is written.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]DataClassdata class (integer, float or string)
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_Integer
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgAsString()

cvbres_t CVOPCNodeGetMethodArgAsString ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
char *  Value,
size_t &  ValueSize 
)

Gets the given OPCUA Method Argument value as C string.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[out]Valuechar buffer to be filled with queried information; nullptr for size query.
[in,out]]ValueSize Gives the buffer size of Value of the selected OPCUA Method Argument or receives the minimal needed size (including the terminating zero in either case) if Value is NULL.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_String
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgAsStringW()

cvbres_t CVOPCNodeGetMethodArgAsStringW ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
wchar_t *  Value,
size_t &  ValueSize 
)

Gets the given OPCUA Method Argument value as wide C string.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[out]ValueWide char buffer to be filled with queried information; nullptr for size query.
[in,out]]ValueSize Gives the buffer size of Value of the selected OPCUA Method Argument or receives the minimal needed size (including the terminating zero in either case) if Value is NULL.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_String
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgCount()

cvbres_t CVOPCNodeGetMethodArgCount ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t &  ArgumentCount 
)

Gets the number of input or output Arguments in the given OPCUA Method.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be counted.
[out]ArgumentCountNumber of input or output arguments depending on the ArgumentType
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetMethodArgDataType()

cvbres_t CVOPCNodeGetMethodArgDataType ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
TCVOPCDataType &  DataClass 
)

Queries the data class (integer, float or string) of the selected input or output argument of a given OPCUA Method.

Note
Function could be used to find the appropriate data class of argument so that it can be properly read out or set: #CVOpcNGetArgAsInteger, #CVOpcNGetArgAsFloat, #CVOpcNGetArgAsString; #CVOpcNSetArgAsInteger, #CVOpcNSetArgAsFloat, #CVOpcNSetArgAsString;
Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[out]DataClassdata class (integer, float or string)
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetNodeClass()

cvbres_t CVOPCNodeGetNodeClass ( CVOPCNODE  Node,
TCVOPCNodeClass &  NodeClass 
)

Gets the OPCUA NodeClass of an OPCUA Node object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which NodeClass should be queried.
[out]NodeClassOPCUA NodeId of the given OPCUA Node.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeGetNodeId()

cvbres_t CVOPCNodeGetNodeId ( CVOPCNODE  Node,
CVOPCNODEID &  NodeId 
)

Gets the OPCUA DataType of an OPCUA Node object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which NodeId should be accessed.
[out]NodeIdOPCUA NodeId of the given OPCUA Node.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetAttributeAsFloat()

cvbres_t CVOPCNodeSetAttributeAsFloat ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
double  Attribute 
)

Sets the selected Attribute of an OPCUA Node object as a double.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be modified.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]AttributeNew value of the OPCUA Node Attribute.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_Float.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetAttributeAsInteger()

cvbres_t CVOPCNodeSetAttributeAsInteger ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
cvbint64_t  Attribute 
)

Sets the selected Attribute of an OPCUA Node object as an int64 .

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be modified.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]AttributeNew value of the OPCUA Node Attribute.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data class than #DT_Integer.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetAttributeAsString()

cvbres_t CVOPCNodeSetAttributeAsString ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
const char *  Attribute 
)

Sets the selected Attribute of an OPCUA Node object as a C string .

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which should be modified.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]AttributeNew value of the OPCUA Node Attribute. This string must be 0 terminated.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data type than C string.
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetAttributeAsStringW()

cvbres_t CVOPCNodeSetAttributeAsStringW ( CVOPCNODE  Node,
TCVOPCAttributeId  AttributeId,
const wchar_t *  Attribute 
)

Sets the selected Attribute of an OPCUA Node object as wide C string.

Note
Overwrites the access level of OPCUA Node object.
Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr. Not every attribute could be set as a string.
Parameters
[in]NodeOPCUA Node which should be modified.
[in]AttributeIdOPCUA AttributeId for the given OPCUA Node.
[in]AttributeNew value of the OPCUA Node Attribute. The wide C string must be 0 terminated.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Attribute to be queried has another data type than wide C Strin.g
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetMethodArgAsFloat()

cvbres_t CVOPCNodeSetMethodArgAsFloat ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
double  Value 
)

Sets the given OPCUA Method Argument value as double.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ValueNew value of the selected argument represented as double.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]DataClassdata class (integer, float or string)
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_Float
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetMethodArgAsInteger()

cvbres_t CVOPCNodeSetMethodArgAsInteger ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
cvbint64_t  Value 
)

Sets the given OPCUA Method Argument value as int64.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ValueNew value of the selected argument represented as int64.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]DataClassdata class (integer, float or string)
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_Integer
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetMethodArgAsString()

cvbres_t CVOPCNodeSetMethodArgAsString ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
const char *  Value 
)

Sets the given OPCUA Method Argument value as wide C string.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ValueNew value of the selected argument represented as C string. This string must be 0 terminated.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_String
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetMethodArgAsStringW()

cvbres_t CVOPCNodeSetMethodArgAsStringW ( CVOPCNODE  Method,
TCVOPCArgumentType  ArgumentType,
size_t  position,
const wchar_t *  Value 
)

Sets the given OPCUA Method Argument value as wide C string.

Attention
Always use initialized string variables and initialize unused handles with nullptr.
Parameters
[in]MethodOPCUA Method object.
[in]ValueNew value of the selected argument represented as wide C string. This wide string must be 0 terminated.
[in]ArgumentTypeDefines which argument type (input or output arguments) should be inspected.
[in]PositionIndex used to identify the input or output argument which data class should be queried
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_INVALIDDATATYPE) if the Argument's data class is not #DT_String
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetModelingRule()

cvbres_t CVOPCNodeSetModelingRule ( CVOPCNODE  Node,
TCVOPCModRule  ModellingRule 
)

Sets the OPCUA Modelling Rule of an OPCUA Node object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node to be modified.
[in]ModellingRuleOPCUA ModellingRule for the given OPCUA Node object.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOPCNodeSetParentReference()

cvbres_t CVOPCNodeSetParentReference ( CVOPCNODE  Node,
TCVOPCReferenceType  Reference 
)

Sets the parent's reference type of an OPCUA Node object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node to be modified.
[out]ParentOPCUA NodeId of the parent for the given OPCUA Node object.
[out]RefenceTypeOPCUA ReferenceType of for the given OPCUA Node object.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOpcNSetNodeId()

cvbres_t CVOpcNSetNodeId ( CVOPCNODE  Node,
CVOPCNODEID  NodeId 
)

Sets the OPCUA NodeId of an OPCUA Node object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node which NodeId should be modified.
[in]NodeIdOPCUA NodeId to be set for the given OPCUA Node.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ CVOpcNSetVDataClass()

cvbres_t CVOpcNSetVDataClass ( CVOPCNODE  VariableOrType,
TCVOPCDataType  DataType 
)

Sets the OPCUA DataType of an OPCUA Variable or VariableType object.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]VariableOrTypeOPCUA Variable or VariableType to be modified.
[in]DataTypeOPCUA DataType for the given OPCUA Variable or VariableType object.
Returns
  • #CVC_ERROR (#CVC_E_OK) on success.
  • #CVC_ERROR (#CVC_E_WRONGOBJECT) if Node is not a valid object
  • Smaller than zero on error (Use CVOPCGetLastErrorString function for a human readable error description).

◆ IsCVOPCNode()

cvbbool_t IsCVOPCNode ( CVOPCNODE  Node)

Checks if handle is valid and points to OPCUA Node.

Attention
Always use initialized OPCUA Node objects and initialize unused handles with nullptr.
Parameters
[in]NodeOPCUA Node handle to check.
Returns
TRUE if handle is correct OPCUA Node, FALSE otherwise.