public static ConstructIdForComponent ( NodeState component, ushort namespaceIndex ) : Opc.Ua.NodeId | ||
component | NodeState | The component. |
namespaceIndex | ushort | Index of the namespace. |
return | Opc.Ua.NodeId |
/// <summary> /// Creates the NodeId for the specified node. /// </summary> /// <param name="context">The context.</param> /// <param name="node">The node.</param> /// <returns>The new NodeId.</returns> /// <remarks> /// This method is called by the NodeState.Create() method which initializes a Node from /// the type model. During initialization a number of child nodes are created and need to /// have NodeIds assigned to them. This implementation constructs NodeIds by constructing /// strings. Other implementations could assign unique integers or Guids and save the new /// Node in a dictionary for later lookup. /// </remarks> public override NodeId New(ISystemContext context, NodeState node) { if (node is ServerStatusState) { return(node.NodeId); } return(ParsedNodeId.ConstructIdForComponent(node, NamespaceIndex)); }
/// <summary> /// Constructs the node identifier for a component. /// </summary> /// <param name="component">The component.</param> /// <param name="namespaceIndex">Index of the namespace.</param> /// <returns>The node identifier for a component.</returns> public static NodeId ConstructIdForComponent(NodeState component, ushort namespaceIndex) { return ParsedNodeId.ConstructIdForComponent(component, namespaceIndex); }