#include <opcua_analogitemtype.h>
Public Member Functions | |
AnalogItemType (UaNode *pParentNode, UaVariable *pInstanceDeclarationVariable, NodeManagerConfig *pNodeConfig, UaMutexRefCounted *pSharedMutex=NULL) | |
AnalogItemType (const UaNodeId &nodeId, const UaString &name, OpcUa_UInt16 browseNameNameSpaceIndex, const UaVariant &initialValue, OpcUa_Byte accessLevel, NodeManagerConfig *pNodeConfig, UaMutexRefCounted *pSharedMutex=NULL) | |
virtual | ~AnalogItemType () |
Class representing OPC UA Variable instances of the type AnalogItemType
OpcUa::AnalogItemType::AnalogItemType | ( | UaNode * | pParentNode, |
UaVariable * | pInstanceDeclarationVariable, | ||
NodeManagerConfig * | pNodeConfig, | ||
UaMutexRefCounted * | pSharedMutex = NULL |
||
) |
Constructs an instance of the class AnalogItemType based on an instance declaration variable.
This constructor is used if the variable is created based on an instance declaration of an object or variable type. Since the only difference between the instance declaration variable and the instance variable are the NodeId and the Value, the pointer to the instance declaration node is used to get the attribute values other than the attributes NodeId and Value from the instance declaration node.
The variable is reference counted and can not be deleted directly. The reference counter is set to one after the variable is created. If the variable was successfully added to a NodeManager using the methods NodeManagerConfig::addUaNode or NodeManagerConfig::addNodeAndReference the NodeManager will release this reference during shut down. If the variable was not added to a NodeManager, it must be deleted using the releaseReference method. If the interface pointer is used in other places, the availablity of the variable must be ensured by incrementing the reference counter with addReference when the pointer is stored somewhere and decremented with releaseReference if the interface pointer is not longer needed.
[in] | pParentNode | Parent node of the new variable |
[in] | pInstanceDeclarationVariable | UaVariable interface of the instance declaration node used to provide attribute values other than NodeId and Value |
[in] | pNodeConfig | Interface pointer to the NodeManagerConfig interface used to add and delete node and references in the address space |
[in] | pSharedMutex | Shared mutex object used to synchronize access to the variable. Can be NULL if no shared mutex is provided |
OpcUa::AnalogItemType::AnalogItemType | ( | const UaNodeId & | nodeId, |
const UaString & | name, | ||
OpcUa_UInt16 | browseNameNameSpaceIndex, | ||
const UaVariant & | initialValue, | ||
OpcUa_Byte | accessLevel, | ||
NodeManagerConfig * | pNodeConfig, | ||
UaMutexRefCounted * | pSharedMutex = NULL |
||
) |
Constructs an instance of the class AnalogItemType with the passed attribute values.
This constructor is used if the variable is not created based on an instance declaration. It defines the name, nodeId, initial value and access level of the variable. Additional language specific names and other attribute values can be set with set methods provided by the class. The variable is reference counted and can not be deleted directly. The reference counter is set to one after the variable is created. If the variable was successfully added to a NodeManager using the methods NodeManagerConfig::addUaNode or NodeManagerConfig::addNodeAndReference the NodeManager will release this reference during shut down. If the variable was not added to a NodeManager, it must be deleted using the releaseReference method. If the interface pointer is used in other places, the availablity of the variable must be ensured by incrementing the reference counter with addReference when the pointer is stored somewhere and decremented with releaseReference if the interface pointer is not longer needed.
[in] | nodeId | NodeId of the new variable |
[in] | name | Name of the new variable. Used as browse name and also as display name if no additional language specific names are set. |
[in] | browseNameNameSpaceIndex | Namespace index used for the browse name |
[in] | initialValue | Initial value for the Variable |
[in] | accessLevel | Access level for the Variable |
[in] | pNodeConfig | Interface pointer to the NodeManagerConfig interface used to add and delete node and references in the address space |
[in] | pSharedMutex | Shared mutex object used to synchronize access to the variable. Can be NULL if no shared mutex is provided |
OpcUa::AnalogItemType::~AnalogItemType | ( | ) | [virtual] |
Destroys the AnalogItemType instance