C# Class Opc.Ua.Server.DiagnosticsNodeManager

A node manager the diagnostic information exposed by the server.
Inheritance: CustomNodeManager2
Afficher le fichier Open project: OPCFoundation/UA-.NET Class Usage Examples

Méthodes publiques

Méthode Description
AddAggregateFunction ( NodeId aggregateId, string aggregateName, bool isHistorical ) : void

Adds an aggregate function to the server capabilities object.

AttachNode ( ILocalNode node ) : void
CreateAddressSpace ( IDictionary externalReferences ) : void

Does any initialization required before the address space can be used.

The externalReferences is an out parameter that allows the node manager to link to nodes in other node managers. For example, the 'Objects' node is managed by the CoreNodeManager and should have a reference to the root folder node(s) exposed by this node manager.

CreateMethod ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, MethodAttributes attributes ) : NodeId
CreateObject ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, ObjectAttributes attributes, ExpandedNodeId typeDefinitionId ) : NodeId
CreateObjectType ( NodeId parentId, NodeId nodeId, QualifiedName browseName, ObjectTypeAttributes attributes ) : NodeId
CreateServerDiagnostics ( ServerSystemContext systemContext, ServerDiagnosticsSummaryDataType diagnostics, NodeValueSimpleEventHandler updateCallback ) : void

Creates the diagnostics node for the server.

CreateSessionDiagnostics ( ServerSystemContext systemContext, SessionDiagnosticsDataType diagnostics, NodeValueSimpleEventHandler updateCallback, SessionSecurityDiagnosticsDataType securityDiagnostics, NodeValueSimpleEventHandler updateSecurityCallback ) : NodeId

Creates the diagnostics node for a subscription.

CreateSubscriptionDiagnostics ( ServerSystemContext systemContext, SubscriptionDiagnosticsDataType diagnostics, NodeValueSimpleEventHandler updateCallback ) : NodeId

Creates the diagnostics node for a subscription.

CreateUniqueNodeId ( ) : NodeId
CreateVariable ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, VariableAttributes attributes, ExpandedNodeId typeDefinitionId ) : NodeId
CreateVariableType ( NodeId parentId, NodeId nodeId, QualifiedName browseName, VariableTypeAttributes attributes ) : NodeId
DeleteNode ( NodeId nodeId, bool deleteChildren, bool silent ) : void
DeleteSessionDiagnostics ( ServerSystemContext systemContext, NodeId nodeId ) : void

Delete the diagnostics node for a session.

DeleteSubscriptionDiagnostics ( ServerSystemContext systemContext, NodeId nodeId ) : void

Delete the diagnostics node for a subscription.

DiagnosticsNodeManager ( IServerInternal server, ApplicationConfiguration configuration ) : System

Initializes the node manager.

FindTargetId ( NodeId sourceId, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : NodeId
GetDefaultHistoryCapabilities ( ) : HistoryServerCapabilitiesState

Gets the default history capabilities object.

GetLocalNode ( NodeId nodeId ) : ILocalNode
GetNamespaceIndex ( string namespaceUri ) : ushort

Returns an index for the NamespaceURI (Adds it to the server namespace table if it does not already exist).

Returns the server's default index (1) if the namespaceUri is empty or null.

GetTargetNode ( NodeId sourceId, NodeId referenceTypeId, bool isInverse, bool includeSubtypes, QualifiedName browseName ) : ILocalNode
New ( ISystemContext context, NodeState node ) : NodeId

Creates the NodeId for the specified node.

OnGetMonitoredItems ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult

Called when a client locks the server.

OnLockServer ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult

Called when a client locks the server.

OnUnlockServer ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult

Called when a client locks the server.

ReferenceSharedNode ( ILocalNode source, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : ILocalNode
ReplaceNode ( ILocalNode existingNode, ILocalNode newNode ) : void
SetDiagnosticsEnabled ( ServerSystemContext context, bool enabled ) : void

Sets the flag controlling whether diagnostics is enabled for the server.

UnreferenceSharedNode ( ILocalNode source, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : ILocalNode

Méthodes protégées

Méthode Description
AddBehaviourToPredefinedNode ( ISystemContext context, NodeState predefinedNode ) : NodeState

Replaces the generic node with a node specific to the model.

Dispose ( bool disposing ) : void

An overrideable version of the Dispose.

LoadPredefinedNodes ( ISystemContext context ) : NodeStateCollection

Loads a node set from a file or resource and addes them to the set of predefined nodes.

OnMonitoredItemCreated ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem ) : void

Called after creating a MonitoredItem.

OnMonitoredItemDeleted ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem ) : void

Called after deleting a MonitoredItem.

OnMonitoringModeChanged ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem, MonitoringMode previousMode, MonitoringMode monitoringMode ) : void

Called after changing the MonitoringMode for a MonitoredItem.

ValidateViewDescription ( ServerSystemContext context, ViewDescription view ) : void

Validates the view description passed to a browse request (throws on error).

Private Methods

Méthode Description
CreateSampledItem ( double samplingInterval, MonitoredItem monitoredItem ) : void

Creates a new sampled item.

DeleteSampledItem ( MonitoredItem monitoredItem ) : void

Deletes a sampled item.

DoSample ( object state ) : void

Polls each monitored item which requires sample.

DoScan ( object alwaysUpdateArrays ) : void

Reports notifications for any monitored diagnostic nodes.

GetTargetNode ( ILocalNode source, NodeId referenceTypeId, bool isInverse, bool includeSubtypes, QualifiedName browseName ) : ILocalNode
IsDiagnosticsNode ( NodeState node ) : bool

Returns true of the node is a diagnostics node.

IsDiagnosticsStructureNode ( NodeState node ) : bool

Returns true of the node is a diagnostics node.

OnBeforeReadDiagnostics ( ISystemContext context, BaseVariableValue variable, NodeState component ) : void

Does a scan before the diagnostics are read.

OnConditionRefresh ( ISystemContext context, MethodState method, NodeId objectId, uint subscriptionId ) : ServiceResult

Handles a request to refresh conditions for a subscription.

OnReadDiagnosticsArray ( ISystemContext context, NodeState node, object &value ) : ServiceResult

Does a scan before the diagnostics are read.

UpdateServerDiagnosticsSummary ( ) : bool

Updates the server diagnostics summary structure.

UpdateSessionDiagnostics ( SessionDiagnosticsData diagnostics, SessionDiagnosticsDataType sessionArray, int index ) : bool

Updates the session diagnostics summary structure.

UpdateSessionSecurityDiagnostics ( SessionDiagnosticsData diagnostics, SessionSecurityDiagnosticsDataType sessionArray, int index ) : bool

Updates the session diagnostics summary structure.

UpdateSubscriptionDiagnostics ( SubscriptionDiagnosticsData diagnostics, SubscriptionDiagnosticsDataType subscriptionArray, int index ) : bool

Updates the subscription diagnostics summary structure.

Method Details

AddAggregateFunction() public méthode

Adds an aggregate function to the server capabilities object.
public AddAggregateFunction ( NodeId aggregateId, string aggregateName, bool isHistorical ) : void
aggregateId NodeId
aggregateName string
isHistorical bool
Résultat void

AddBehaviourToPredefinedNode() protected méthode

Replaces the generic node with a node specific to the model.
protected AddBehaviourToPredefinedNode ( ISystemContext context, NodeState predefinedNode ) : NodeState
context ISystemContext
predefinedNode NodeState
Résultat NodeState

AttachNode() public méthode

public AttachNode ( ILocalNode node ) : void
node ILocalNode
Résultat void

CreateAddressSpace() public méthode

Does any initialization required before the address space can be used.
The externalReferences is an out parameter that allows the node manager to link to nodes in other node managers. For example, the 'Objects' node is managed by the CoreNodeManager and should have a reference to the root folder node(s) exposed by this node manager.
public CreateAddressSpace ( IDictionary externalReferences ) : void
externalReferences IDictionary
Résultat void

CreateMethod() public méthode

public CreateMethod ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, MethodAttributes attributes ) : NodeId
parentId NodeId
referenceTypeId NodeId
nodeId NodeId
browseName QualifiedName
attributes MethodAttributes
Résultat NodeId

CreateObject() public méthode

public CreateObject ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, ObjectAttributes attributes, ExpandedNodeId typeDefinitionId ) : NodeId
parentId NodeId
referenceTypeId NodeId
nodeId NodeId
browseName QualifiedName
attributes ObjectAttributes
typeDefinitionId ExpandedNodeId
Résultat NodeId

CreateObjectType() public méthode

public CreateObjectType ( NodeId parentId, NodeId nodeId, QualifiedName browseName, ObjectTypeAttributes attributes ) : NodeId
parentId NodeId
nodeId NodeId
browseName QualifiedName
attributes ObjectTypeAttributes
Résultat NodeId

CreateServerDiagnostics() public méthode

Creates the diagnostics node for the server.
public CreateServerDiagnostics ( ServerSystemContext systemContext, ServerDiagnosticsSummaryDataType diagnostics, NodeValueSimpleEventHandler updateCallback ) : void
systemContext ServerSystemContext
diagnostics ServerDiagnosticsSummaryDataType
updateCallback NodeValueSimpleEventHandler
Résultat void

CreateSessionDiagnostics() public méthode

Creates the diagnostics node for a subscription.
public CreateSessionDiagnostics ( ServerSystemContext systemContext, SessionDiagnosticsDataType diagnostics, NodeValueSimpleEventHandler updateCallback, SessionSecurityDiagnosticsDataType securityDiagnostics, NodeValueSimpleEventHandler updateSecurityCallback ) : NodeId
systemContext ServerSystemContext
diagnostics SessionDiagnosticsDataType
updateCallback NodeValueSimpleEventHandler
securityDiagnostics SessionSecurityDiagnosticsDataType
updateSecurityCallback NodeValueSimpleEventHandler
Résultat NodeId

CreateSubscriptionDiagnostics() public méthode

Creates the diagnostics node for a subscription.
public CreateSubscriptionDiagnostics ( ServerSystemContext systemContext, SubscriptionDiagnosticsDataType diagnostics, NodeValueSimpleEventHandler updateCallback ) : NodeId
systemContext ServerSystemContext
diagnostics SubscriptionDiagnosticsDataType
updateCallback NodeValueSimpleEventHandler
Résultat NodeId

CreateUniqueNodeId() public méthode

public CreateUniqueNodeId ( ) : NodeId
Résultat NodeId

CreateVariable() public méthode

public CreateVariable ( NodeId parentId, NodeId referenceTypeId, NodeId nodeId, QualifiedName browseName, VariableAttributes attributes, ExpandedNodeId typeDefinitionId ) : NodeId
parentId NodeId
referenceTypeId NodeId
nodeId NodeId
browseName QualifiedName
attributes VariableAttributes
typeDefinitionId ExpandedNodeId
Résultat NodeId

CreateVariableType() public méthode

public CreateVariableType ( NodeId parentId, NodeId nodeId, QualifiedName browseName, VariableTypeAttributes attributes ) : NodeId
parentId NodeId
nodeId NodeId
browseName QualifiedName
attributes VariableTypeAttributes
Résultat NodeId

DeleteNode() public méthode

public DeleteNode ( NodeId nodeId, bool deleteChildren, bool silent ) : void
nodeId NodeId
deleteChildren bool
silent bool
Résultat void

DeleteSessionDiagnostics() public méthode

Delete the diagnostics node for a session.
public DeleteSessionDiagnostics ( ServerSystemContext systemContext, NodeId nodeId ) : void
systemContext ServerSystemContext
nodeId NodeId
Résultat void

DeleteSubscriptionDiagnostics() public méthode

Delete the diagnostics node for a subscription.
public DeleteSubscriptionDiagnostics ( ServerSystemContext systemContext, NodeId nodeId ) : void
systemContext ServerSystemContext
nodeId NodeId
Résultat void

DiagnosticsNodeManager() public méthode

Initializes the node manager.
public DiagnosticsNodeManager ( IServerInternal server, ApplicationConfiguration configuration ) : System
server IServerInternal
configuration ApplicationConfiguration
Résultat System

Dispose() protected méthode

An overrideable version of the Dispose.
protected Dispose ( bool disposing ) : void
disposing bool
Résultat void

FindTargetId() public méthode

public FindTargetId ( NodeId sourceId, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : NodeId
sourceId NodeId
referenceTypeId NodeId
isInverse bool
browseName QualifiedName
Résultat NodeId

GetDefaultHistoryCapabilities() public méthode

Gets the default history capabilities object.
public GetDefaultHistoryCapabilities ( ) : HistoryServerCapabilitiesState
Résultat HistoryServerCapabilitiesState

GetLocalNode() public méthode

public GetLocalNode ( NodeId nodeId ) : ILocalNode
nodeId NodeId
Résultat ILocalNode

GetNamespaceIndex() public méthode

Returns an index for the NamespaceURI (Adds it to the server namespace table if it does not already exist).
Returns the server's default index (1) if the namespaceUri is empty or null.
public GetNamespaceIndex ( string namespaceUri ) : ushort
namespaceUri string
Résultat ushort

GetTargetNode() public méthode

public GetTargetNode ( NodeId sourceId, NodeId referenceTypeId, bool isInverse, bool includeSubtypes, QualifiedName browseName ) : ILocalNode
sourceId NodeId
referenceTypeId NodeId
isInverse bool
includeSubtypes bool
browseName QualifiedName
Résultat ILocalNode

LoadPredefinedNodes() protected méthode

Loads a node set from a file or resource and addes them to the set of predefined nodes.
protected LoadPredefinedNodes ( ISystemContext context ) : NodeStateCollection
context ISystemContext
Résultat NodeStateCollection

New() public méthode

Creates the NodeId for the specified node.
public New ( ISystemContext context, NodeState node ) : NodeId
context ISystemContext The context.
node NodeState The node.
Résultat NodeId

OnGetMonitoredItems() public méthode

Called when a client locks the server.
public OnGetMonitoredItems ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult
context ISystemContext
method MethodState
inputArguments IList
outputArguments IList
Résultat ServiceResult

OnLockServer() public méthode

Called when a client locks the server.
public OnLockServer ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult
context ISystemContext
method MethodState
inputArguments IList
outputArguments IList
Résultat ServiceResult

OnMonitoredItemCreated() protected méthode

Called after creating a MonitoredItem.
protected OnMonitoredItemCreated ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem ) : void
context ServerSystemContext The context.
handle NodeHandle The handle for the node.
monitoredItem MonitoredItem The monitored item.
Résultat void

OnMonitoredItemDeleted() protected méthode

Called after deleting a MonitoredItem.
protected OnMonitoredItemDeleted ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem ) : void
context ServerSystemContext The context.
handle NodeHandle The handle for the node.
monitoredItem MonitoredItem The monitored item.
Résultat void

OnMonitoringModeChanged() protected méthode

Called after changing the MonitoringMode for a MonitoredItem.
protected OnMonitoringModeChanged ( ServerSystemContext context, NodeHandle handle, MonitoredItem monitoredItem, MonitoringMode previousMode, MonitoringMode monitoringMode ) : void
context ServerSystemContext The context.
handle NodeHandle The handle for the node.
monitoredItem MonitoredItem The monitored item.
previousMode MonitoringMode The previous monitoring mode.
monitoringMode MonitoringMode The current monitoring mode.
Résultat void

OnUnlockServer() public méthode

Called when a client locks the server.
public OnUnlockServer ( ISystemContext context, MethodState method, IList inputArguments, IList outputArguments ) : ServiceResult
context ISystemContext
method MethodState
inputArguments IList
outputArguments IList
Résultat ServiceResult

ReferenceSharedNode() public méthode

public ReferenceSharedNode ( ILocalNode source, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : ILocalNode
source ILocalNode
referenceTypeId NodeId
isInverse bool
browseName QualifiedName
Résultat ILocalNode

ReplaceNode() public méthode

public ReplaceNode ( ILocalNode existingNode, ILocalNode newNode ) : void
existingNode ILocalNode
newNode ILocalNode
Résultat void

SetDiagnosticsEnabled() public méthode

Sets the flag controlling whether diagnostics is enabled for the server.
public SetDiagnosticsEnabled ( ServerSystemContext context, bool enabled ) : void
context ServerSystemContext
enabled bool
Résultat void

UnreferenceSharedNode() public méthode

public UnreferenceSharedNode ( ILocalNode source, NodeId referenceTypeId, bool isInverse, QualifiedName browseName ) : ILocalNode
source ILocalNode
referenceTypeId NodeId
isInverse bool
browseName QualifiedName
Résultat ILocalNode

ValidateViewDescription() protected méthode

Validates the view description passed to a browse request (throws on error).
protected ValidateViewDescription ( ServerSystemContext context, ViewDescription view ) : void
context ServerSystemContext
view ViewDescription
Résultat void