C++ Based OPC UA Client/Server/PubSub SDK
1.7.1.476
|
Interface definition of NodeManager used for browsing and managing the address space. More...
#include <nodemanager.h>
Inherits UaServerApplicationModule.
Inherited by NodeManagerUaNode.
Public Member Functions | |
NodeManager () | |
construction | |
virtual | ~NodeManager () |
destruction | |
virtual UaStatus | sessionOpened (Session *) |
Notifies the node manager that a new session was opened. More... | |
virtual UaStatus | sessionActivated (Session *) |
Notifies the node manager that a session was activated. More... | |
virtual UaStatus | sessionClosed (Session *) |
Notifies the node manager that a session was closed. More... | |
virtual UaStatus | browse (const ServiceContext &serviceContext, BrowseContext &browseContext, UaReferenceDescriptions &References)=0 |
Discover the references of a specified node of a view. More... | |
virtual UaStatus | translateBrowsePathToNodeId (const ServiceContext &serviceContext, const UaNodeId &startingNode, UaRelativePath &relativePath, UaBrowsePathTargets &browsePathTargets)=0 |
Translates a relative browse path to a node id. More... | |
virtual VariableHandle * | getVariableHandle (Session *pSession, VariableHandle::ServiceType serviceType, OpcUa_NodeId *pNodeId, OpcUa_Int32 AttributeId) const =0 |
Get the variable handle for the passed node Id. More... | |
virtual HistoryVariableHandle * | getHistoryVariableHandle (Session *pSession, HistoryVariableHandle::ServiceType serviceType, OpcUa_NodeId *pNodeId, UaStatus &result) const |
Get the history variable handle for the passed node Id. More... | |
virtual UaStatus | getEventManagers (Session *pSession, OpcUa_NodeId *pNodeId, OpcUa_EventFilter *eventFilter, EventManagerArray &eventManagers) const |
Get a list of EventManager interfaces for an event notifier. More... | |
virtual MethodHandle * | getMethodHandle (Session *pSession, OpcUa_NodeId *pObjectNodeId, OpcUa_NodeId *pMethodNodeId, UaStatus &result) const |
Get the method handle for the passed node Id. More... | |
virtual UaStatus | addNode (const ServiceContext &serviceContext, const UaNodeId &parentNodeId, const UaNodeId &referenceTypeId, const UaNodeId &requestedNewNodeId, const UaQualifiedName &browseName, OpcUa_NodeClass nodeClass, const UaExtensionObject &nodeAttributes, const UaNodeId &typeDefinition, UaNodeId &addedNodeId) |
Add node to the NodeManager. More... | |
virtual UaStatus | addReference (const ServiceContext &serviceContext, const UaNodeId &sourceNodeId, const UaNodeId &referenceTypeId, OpcUa_Boolean isForward, const UaNodeId &targetNodeId, OpcUa_NodeClass targetNodeClass) |
Add reference to the NodeManager. More... | |
virtual UaStatus | deleteNode (const ServiceContext &serviceContext, const UaNodeId &nodeId, OpcUa_Boolean deleteTargetReference) |
Delete node from the NodeManager. More... | |
virtual UaStatus | deleteReference (const ServiceContext &serviceContext, const UaNodeId &sourceNodeId, const UaNodeId &referenceTypeId, OpcUa_Boolean isForward, const UaNodeId &targetNodeId, OpcUa_Boolean deleteBidirectional) |
Delete reference from the NodeManager. More... | |
virtual NodeManagerCrossReferences * | getNodeManagerCrossReferences () |
Get the interface NodeManagerCrossReferences if available. More... | |
virtual NodeManagerConfig * | getNodeManagerConfig () |
Get the interface NodeManagerConfig if available. More... | |
virtual NodeManagerUaNode * | getNodeManagerUaNode () |
Get the interface NodeManagerUaNode if available. More... | |
virtual NodeAccessInfo * | getDefaultPermissions (OpcUa_UInt16 nsIndex) const |
Get the default permission defined for this namespace. More... | |
virtual UaStatus | createRoleOperations (const UaString &roleName, RoleTypeOperations **ppRoleTypeOperations) |
Create a new Role with the specified name and return a pointer to the new RoleTypeOperation instance. More... | |
virtual UaStatus | removeRoleOperations (RoleTypeOperations *pRoleTypeOperations) |
Remove a Role that was created by this NodeManager. More... | |
Public Member Functions inherited from UaServerApplicationModule | |
virtual UaStatus | startUp (ServerManager *pServerManager)=0 |
Start up module. More... | |
virtual UaStatus | shutDown ()=0 |
Shut down module. More... | |
Interface definition of NodeManager used for browsing and managing the address space.
The NodeManager interface provides the browsing capability for the nodes managed by the NodeManager instance. It returns also the responsible IOManager, MethodManager, HistoryManager or EventManager for a passed node (NodeId). The interface provides optional methods to add nodes and references and to delete nodes and references.
One NodeManager is typically responsible for the nodes of one namespace. This is all nodes where the NodeIds have the same namespace index. A namespace index is assigned a namespace URI when the NodeManager is registered with the SDK. The interface NodeManagerList is used to register the NodeManager. The method NodeManagerList::addNodeManager returns the namespace index for the namespace URI. This namespace index is then used for all NodeIds of nodes managed by this NodeManager.
It is possible to register several namespace URIs for one NodeManager interface. The NodeManager is then responsible for managing the resulting list of namespace indices.
One NodeManager can use several IOManagers, MethodManagers or HistoryManagers e.g. one NodeManager can manage nodes for several subsystems but it can use one instance of a IOManager per subsystem. The number of IOManagers, MethodManagers or HistoryManagers is not limited. But it is strongly recommended to limit the EventManagers in a server.
|
virtual |
Add node to the NodeManager.
serviceContext | General context for the service calls containing information like the session object, return diagnostic mask and timeout hint. |
parentNodeId | The NodeId of the parent node of the node to create. |
referenceTypeId | Type of the reference to create from the source node to the new node. |
requestedNewNodeId | The new NodeId of the requested node. |
browseName | The browse name of the node to create. |
nodeClass | The node class of the node to create. |
nodeAttributes | All other attribute values of the node to create. |
typeDefinition | The type definition of the node to create. |
addedNodeId | The NodeId of the newly created node. |
Reimplemented in NodeManagerRoot.
|
virtual |
Add reference to the NodeManager.
serviceContext | General context for the service calls containing information like the session object, return diagnostic mask and timeout hint. |
sourceNodeId | The NodeId of source node for the reference to create. |
referenceTypeId | Type of the reference to create from the source node to the target node. |
isForward | Indicates if the reference is in forward direction from the source to the target node. |
targetNodeId | The NodeId of target node for the reference to create. |
targetNodeClass | The NodeClass of the target Node. |
Reimplemented in NodeManagerRoot.
|
pure virtual |
Discover the references of a specified node of a view.
This method is used to return a list of references and target nodes for the passed node to browse for the services Browse and BrowseNext.
serviceContext | General context for the service call containing information like the session object, return diagnostic mask and timeout hint. |
browseContext | Browse context for the first browse or the following browse next calls with continuation point. |
References | Array of ReferenceDescription results for the browsed node. |
Implemented in NodeManagerRoot, and NodeManagerUaNode.
|
virtual |
Create a new Role with the specified name and return a pointer to the new RoleTypeOperation instance.
roleName | The name for the new Role to add. |
ppRoleTypeOperations | A pointer to the RoleOperation interface created by the Nodemanager. |
Reimplemented in NodeManagerUaNode.
|
virtual |
Delete node from the NodeManager.
serviceContext | General context for the service calls containing information like the session object, return diagnostic mask and timeout hint. |
nodeId | The NodeId of the node to delete. |
deleteTargetReference | Indicates if the inverse references in the target nodes must be deleted |
Reimplemented in NodeManagerRoot.
|
virtual |
Delete reference from the NodeManager.
serviceContext | General context for the service calls containing information like the session object, return diagnostic mask and timeout hint. |
sourceNodeId | The NodeId of source node for the reference to delete. |
referenceTypeId | Type of the reference to delete from the source node to the target node. |
isForward | Indicates if the reference is in forward direction from the source to the target node. |
targetNodeId | The NodeId of target node for the reference to delete. |
deleteBidirectional | Flag indicating if the reference should be deleted in both directions. |
Reimplemented in NodeManagerRoot.
|
virtual |
Get the default permission defined for this namespace.
Reimplemented in NodeManagerUaNode, and NodeManagerRoot.
|
virtual |
Get a list of EventManager interfaces for an event notifier.
This method is used to get a list of EventManager interfaces for the passed object node which must be an event notifier. Since the event notifier can be the root for an event hierarchy with different event sources and different EventManagers. The NodeManager can filter based on the passed event filter. But this can be done also later by the EventManager.
pSession | Interface to the Session context for the method call |
pNodeId | NodeId of the requested event notifier node. The pointer to the NodeId is only valid during this call. |
eventFilter | Event filter defined by the client. The pointer to the event filter is only valid during this call. The event filter is also passed to EventManager::beginStartMonitoring() in the EventMonitoringContextCreate. |
eventManagers | The list of EventManager interfaces for the passed event notifier. This list is returned by the NodeManager. |
Reimplemented in NodeManagerRoot, and NodeManagerBase.
|
virtual |
Get the history variable handle for the passed node Id.
This method is used to get the HistoryVariableHandle for a node used to access the related HistoryManager in the services ReadHistory and UpdateHistory.
pSession | Interface to the Session context for the method call |
serviceType | Service type enumerator |
pNodeId | NodeId of the requested node. The pointer to the NodeId is only valid during this call. |
result | the result of the current Operation. |
Reimplemented in NodeManagerRoot, NodeManagerBase, and NodeManagerNS1.
|
virtual |
Get the method handle for the passed node Id.
This method is used to get the MethodHandle for a Object node / Method combination used to access the related MethodManager in the service Call.
pSession | Interface to the Session context for the method call |
pObjectNodeId | The NodeId of the requested Object. The pointer to the NodeId is only valid during this call. |
pMethodNodeId | The NodeId of the requested Method. The pointer to the NodeId is only valid during this call. |
result | The result of the current Operation. |
Reimplemented in NodeManagerRoot, and NodeManagerUaNode.
|
virtual |
Get the interface NodeManagerConfig if available.
Reimplemented in NodeManagerRoot, and NodeManagerUaNode.
|
virtual |
Get the interface NodeManagerCrossReferences if available.
Reimplemented in NodeManagerRoot, and NodeManagerUaNode.
|
virtual |
Get the interface NodeManagerUaNode if available.
Reimplemented in NodeManagerUaNode.
|
pure virtual |
Get the variable handle for the passed node Id.
This method is used to get the VariableHandle for a node used to access the related IOManager in the services Read, Write and CreateMonitoredItems. The provided VariableHandle is reference counted. The reference count is 1 after initial creation of the object. The SDK will release its reference after the transaction is finished. If the VariableHandle is stored in an application specific object, the reference counter must be incremented to keep the one reference. If this stored pointer is used to return the VariableHandle in following getVariableHandle calls, the reference counter must be incremented before returning the pointer.
pSession | Interface to the Session context for the method call. The Session object is reference counted. The Session is valid until the client has closed the Session or it timed out. If the Session pointer is stored in user objects, these objects must add their own reference. |
serviceType | Service type enumerator |
pNodeId | NodeId of the requested node. The pointer to the NodeId is only valid during this call. |
AttributeId | AttributeId of the requested node |
Implemented in NodeManagerRoot, and NodeManagerUaNode.
|
virtual |
Remove a Role that was created by this NodeManager.
This decreases the ReferenceCounter of pRoleOperations.
pRoleTypeOperations | A pointer to the RoleOperation interface. |
Reimplemented in NodeManagerUaNode.
Notifies the node manager that a session was activated.
The method can be overwritten in a derived class if the implementation needs to know which sessions are active
Reimplemented in NodeManagerRoot.
Notifies the node manager that a session was closed.
The method can be overwritten in a derived class if the implementation needs to know which sessions are active
Reimplemented in NodeManagerRoot.
Notifies the node manager that a new session was opened.
This information can be used to establish a connection to an underlying system if Session specific (e.g. user specific) connections are necessary. The method can be overwritten in a derived class if the implementation needs to know which sessions are active
Reimplemented in NodeManagerRoot.
|
pure virtual |
Translates a relative browse path to a node id.
This method is used to request the Server to translate a browse paths to a NodeId for the target node. There could be a list of target nodes but the normal case is a single result for a starting node and a path.
The browse path is constructed of a starting Node and a RelativePath. The specified starting Node identifies the Node from which the RelativePath is based. The RelativePath contains a sequence of BrowseNames. The relative path parameter contains a list of relative path elements and the current position of the translate process since the translate can affect more than one node manager and the implementation of this method is only required to process relative path elements and starting nodes managed by the current node manager instance but it may also resolve the full path for all involved NodeManagers.
If not all path elements can be resolved by the NodeManager, the call can be returned with the last resolved target node and the remaining index provided in browsePathTargets, or the NodeManager calls translateBrowsePathToNodeId() on the NodeManager that is responsible for the next node in the path.
If the path cannot be resolved completely but the next node in the path is in another server, the method must return OpcUa_UncertainReferenceOutOfServer.
If a path results in more than one result, the implementation of this method must resolve the full path for all possible results.
serviceContext | General context for the service calls containing information like the session object, return diagnostic mask and timeout hint. |
startingNode | Starting node from where the relative path is defined. |
relativePath | Relative path from the starting node to the searched node including the current position of the translate process. |
browsePathTargets | All result target nodes for the browse path or the partial result for the already resolved part of the path. |
Implemented in NodeManagerRoot, and NodeManagerUaNode.