Interface for OPC UA Object nodes created and managed with the SDK. More...
#include <uabasenodes.h>
Public Member Functions | |
UaObject () | |
virtual OpcUa_Byte | eventNotifier () const =0 |
virtual MethodManager * | getMethodManager (UaMethod *pMethod) const |
OpcUa_NodeClass | nodeClass () const |
virtual void | getAttributeValue (Session *pSession, OpcUa_Int32 attributeId, UaDataValue &uaDataValue) |
Protected Member Functions | |
virtual | ~UaObject () |
Interface for OPC UA Object nodes created and managed with the SDK.
The class is derived from the interface UaNode. Classes implementing the interface UaObject must also implement the interface UaNode. OPC UA Objects are used to represent systems, system components, real-world objects and software objects. They have the NodeClass Object. The detailed description of Objects and their attributes can be found in the general description of the Object node class.
For the use of the toolkit level of the SDK where the nodes are managed by the SDK, all Object nodes must implement this interface.
UaObject::~UaObject | ( | ) | [protected, virtual] |
Destruction of the UaObject. The object is reference counted and can not be deleted directly. The methods addReference and releaseReference are used to manage the reference to this object.
UaObject::UaObject | ( | ) |
Construction of the UaObject. The object is reference counted and can not be deleted directly. The reference counter is set to one after the object is created. If the object 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 object 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 object 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.
virtual OpcUa_Byte UaObject::eventNotifier | ( | ) | const [pure virtual] |
Returns the value of the EventNotifier attribute.
The EventNotifier Attribute is used to indicate if the Node can be used to subscribe to Events or the read / write historic Events.
The EventNotifier is an 8-bit unsigned integer used as bit field with the following bit fields:
Define | Value | Bit | Description |
---|---|---|---|
OpcUa_EventNotifiers_None | 0x0 | The Object does not produce events and has no event history. | |
OpcUa_EventNotifiers_SubscribeToEvents | 0x1 | 0 | The Object produces event notifications. |
1 | Reserved for future use. Must always be zero. | ||
OpcUa_EventNotifiers_HistoryRead | 0x4 | 2 | The Object has an event history which may be read. |
OpcUa_EventNotifiers_HistoryWrite | 0x8 | 3 | The Object has an event history which may be updated. |
The second two bits also indicate if the history of the Events is available via the OPC UA server.
Implemented in OpcUa::BaseObjectType, UaStateMachineType, UaFolder, UaAreaFolder, UaGenericObject, UaObjectServer, UaObjectServerCapabilities, UaModelingRule, UaObjectServerDiagnostic, and UaObjectVendorServerInfo.
void UaObject::getAttributeValue | ( | Session * | pSession, |
OpcUa_Int32 | attributeId, | ||
UaDataValue & | uaDataValue | ||
) | [virtual] |
MethodManager * UaObject::getMethodManager | ( | UaMethod * | pMethod ) | const [virtual] |
Get the MethodManager interface for a method of this object.
pMethod | The method object the manager is requested for. |
Reimplemented in OpcUa::BaseObjectType, UaStateMachineType, UaGenericObject, UaObjectServerCapabilities, UaModelingRule, UaObjectServerDiagnostic, and UaObjectVendorServerInfo.
OpcUa_NodeClass UaObject::nodeClass | ( | ) | const [inline, virtual] |
Get the node class of the Node.
Implements UaNode.
Reimplemented in UaGenericObject.