Namespace: Opc.UaFx
Assemblies: Opc.UaFx.Advanced.dll, Opc.UaFx.Advanced.dll
The OpcNodeId type exposes the following members.
Initializes a new instance of the OpcNodeId class using the value
specified.
C#
public OpcNodeId(byte[] value)
Parameters
value
Byte[]
The opaque value of the identifier to represent. A value equals a null reference (Nothing in Visual Basic) or an array with the length equals to zero results into a null identifier (see IsNull).
Initializes a new instance of the OpcNodeId class using the value
and namespaceIndex
specified.
C#
public OpcNodeId(byte[] value, int namespaceIndex)
Parameters
value
Byte[]
The opaque value of the identifier to represent. A value equals a null reference (Nothing in Visual Basic) or an array with the length equals to zero results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and nodeNamespace
specified.
C#
public OpcNodeId(byte[] value, OpcNamespace nodeNamespace)
Parameters
value
Byte[]
The opaque value of the identifier to represent. A value equals a null reference (Nothing in Visual Basic) or an array with the length equals to zero results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and namespaceIndex
specified.
C#
public OpcNodeId(Guid value, int namespaceIndex)
Parameters
value
Guid
The general unique identifier (= GUID) to use as the value of the identifier to represent. A value equals Empty results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and nodeNamespace
specified.
C#
public OpcNodeId(Guid value, OpcNamespace nodeNamespace)
Parameters
value
Guid
The general unique identifier (= GUID) to use as the value of the identifier to represent. A value equals Empty results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and namespaceIndex
specified.
C#
public OpcNodeId(int value, int namespaceIndex)
Parameters
value
Int32
The numeric value of the identifier to represent. A value equals zero results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and nodeNamespace
specified.
C#
public OpcNodeId(int value, OpcNamespace nodeNamespace)
Parameters
value
Int32
The numeric value of the identifier to represent. A value equals zero results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and namespaceIndex
specified.
C#
public OpcNodeId(string value, int namespaceIndex)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
, namespaceIndex
and pathElements
specified.
C#
public OpcNodeId(string value, int namespaceIndex, params OpcName[] pathElements)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
pathElements
OpcName[]
The elements of the OpcNamePath to use as the logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
, namespaceIndex
and path
specified.
C#
public OpcNodeId(string value, int namespaceIndex, OpcNamePath path)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
path
OpcNamePath
The logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
and pathElements
specified.
C#
public OpcNodeId(string value, params OpcName[] pathElements)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
pathElements
OpcName[]
The elements of the OpcNamePath to use as the logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
and path
specified.
C#
public OpcNodeId(string value, OpcNamePath path)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
path
OpcNamePath
The logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
and nodeNamespace
specified.
C#
public OpcNodeId(string value, OpcNamespace nodeNamespace)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
, nodeNamespace
and pathElements
specified.
C#
public OpcNodeId(string value, OpcNamespace nodeNamespace, params OpcName[] pathElements)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
pathElements
OpcName[]
The elements of the OpcNamePath to use as the logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
, nodeNamespace
and path
specified.
C#
public OpcNodeId(string value, OpcNamespace nodeNamespace, OpcNamePath path)
Parameters
value
String
The String value of the identifier to represent. A null reference (Nothing in Visual Basic) or a value equals Empty results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
path
OpcNamePath
The logical (= physically not available in the address space) portion of the identifier.
Initializes a new instance of the OpcNodeId class using the value
and namespaceIndex
specified.
C#
[CLSCompliant(false)] public OpcNodeId(uint value, int namespaceIndex)
Parameters
value
UInt32
The numeric value of the identifier to represent. A value equals zero results into a null identifier (see IsNull).
namespaceIndex
Int32
The index of the namespace that this identifier should refer to.
Initializes a new instance of the OpcNodeId class using the value
and nodeNamespace
specified.
C#
[CLSCompliant(false)] public OpcNodeId(uint value, OpcNamespace nodeNamespace)
Parameters
value
UInt32
The numeric value of the identifier to represent. A value equals zero results into a null identifier (see IsNull).
nodeNamespace
OpcNamespace
The namespace that this identifier should refer to.
Defines the character which is used to separate node-component-node related node identifiers form each other when constructing a node-component-node related node identifier using WithPath(OpcNamePath).
C#
public static readonly char DefaultSeparatorOfPath
Field Value
Char
Gets or sets the globally used OpcNodeIdFactory to generate new instances of the OpcNodeId class.
C#
public static OpcNodeIdFactory Factory { get; set; }
Property Value
An instance of a sub class of the OpcNodeIdFactory class. The default factory used is the OpcNominalNodeIdFactory.
Gets a value indicating whether the node identifier is a null identifier.
C#
public bool IsNull { get; }
Property Value
The value true if the Value defines a Type specific definition of a null identifier; otherwise the value false.
Remarks
A null identifier originates when a node identifier is created using: * A Byte-array as the identifier value. In case there the Opaque identifier value is a null reference (Nothing in Visual Basic) or an empty array (the length is equals zero).
Gets the OpcNamespace used by the OpcNodeId to describe the namespace to that the node identifier belongs.
C#
public OpcNamespace Namespace { get; }
Property Value
An instance of the OpcNamespace with the known information about the namespace to that the OpcNodeId belongs.
Gets the index of the namespace that this identifier belongs.
C#
public int NamespaceIndex { get; }
Property Value
The index value which refers to the namespace in the namespace array of the server to that the node identifier belong.
Remarks
The available namespaces of the server can be retrieved through reading the value of the namespaces-node using the node identifier 'OpcObjectTypes.Server.Namespaces'.
Gets the uniform resource identifier (URI) of the namespace referred by the NamespaceIndex.
C#
public Uri NamespaceUri { get; }
Property Value
The Uri to that the OpcNodeId refers using the NamespaceIndex.
Gets the original format of the node identifier from that the instance was constructed.
C#
public OpcNodeIdFormat OriginalFormat { get; }
Property Value
The format used by the String passed to the Parse(String) method from that the identifier has been constructed. If this instance has not been constructed through a Parse(String) call a constructor dependent OpcNodeIdFormat enumeration member.
Gets the path portion of the Value which refers to the logical (= physically not available in the address space) portion of the identifier.
C#
public OpcNamePath Path { get; }
Property Value
An instance of the OpcNamePath identifying the browse path to use to determine the according entity through the physically existing members in the address space.
Remarks
A OpcNodeId with a OpcNamePath not equals Empty identifies an entity which is not necessarily physically available in the address space. We define that the identifier of the physical ancestor of the entity identified by such an identifier (its logical owner which is physically available in the address space) is encoded in the Value of its OpcNodeId followed by the string formatted Path. Excluding the Path from this OpcNodeId (see ExcludePath) results into the identifier of the 'physical' ancestor. Using these (path-less) identifier the ancestor can be looked up in the address space and can be used to browse for the entity using the Path of the identifier of its successor.
Gets the type of Value used to define the identifier.
C#
public OpcNodeIdType Type { get; }
Property Value
One of the members defined by the OpcNodeIdType enumeration. The value dependents on the type of Value used for the identifier.
Determines whether two specified OpcNodeId objects are equals.
C#
public static bool Equals(OpcNodeId first, OpcNodeId second)
Parameters
first
OpcNodeId
The first OpcNodeId to compare, or a null reference (Nothing in Visual Basic).
second
OpcNodeId
The second OpcNodeId to compare, or a null reference (Nothing in Visual Basic).
Returns
The value true if the first
is equals to the second
; otherwise the value false.
Determines whether two specified OpcNodeId objects are equals according to a specific comparison method.
C#
public static bool Equals(OpcNodeId first, OpcNodeId second, OpcNodeIdComparison comparisonType)
Parameters
first
OpcNodeId
The first OpcNodeId to compare, or a null reference (Nothing in Visual Basic).
second
OpcNodeId
The second OpcNodeId to compare, or a null reference (Nothing in Visual Basic).
comparisonType
OpcNodeIdComparison
One of the members defined by the OpcNodeIdComparison enumeration that specifies the rules for the comparison.
Returns
The value true if the first
is equals to the second
; otherwise the value false.
Determines whether the specified OpcNodeId object is equals to this instance according to a specific comparison method.
C#
public bool Equals(OpcNodeId other, OpcNodeIdComparison comparisonType)
Parameters
other
OpcNodeId
The OpcNodeId to compare to this instance.
comparisonType
OpcNodeIdComparison
One of the members defined by the OpcNodeIdComparison enumeration that specifies the rules for the comparison.
Returns
The value true if the other
is equals to this instance; otherwise the value false.
Retrieves a new OpcNodeId there its Value not longer contains any Path information.
C#
public OpcNodeId ExcludePath()
Returns
A new instance of the OpcNodeId class using the same Namespace as this OpcNodeId and the same Value, but without any Path portion used by this OpcNodeId.
Remarks
In case there the identifier of the ancestor from that this OpcNodeId (with path) was created from is not of the TypeString this method will not recover its original OpcNodeIdType.
Indicates whether the specified OpcNodeId is null or its Value is null, default or an empty string (“”).
C#
public static bool IsNullOrEmpty(OpcNodeId identifier)
Parameters
identifier
OpcNodeId
The OpcNodeId to test.
Returns
The value true if the identifier
parameter or its Value is null, default or an empty string (“”); otherwise the value false.
Remarks
This method ignores the circumstance whether the Namespace of the identifier
might be specified anyway.
Creates a new OpcNodeId instance from the name
specified.
C#
public static OpcNodeId Of(OpcName name)
Parameters
name
OpcName
The OpcName its Value and NamespaceIndex is used to create a new OpcNodeId of the type String.
Returns
A new instance of the OpcNodeId created from the Value and NamespaceIndex of the name
specified.
Exceptions
The name
does not provide a Value nor a NamespaceIndex from that a OpcNodeId can be created (see IsNull).
The name
is a null reference (Nothing in Visual Basic).
Creates a new parent-child related OpcNodeId instance from the name
and parentNodeId
specified.
C#
public static OpcNodeId Of(OpcName name, OpcNodeId parentNodeId)
Parameters
name
OpcName
The OpcName its Value and NamespaceIndex is used to create a new OpcNodeId of the type String.
parentNodeId
OpcNodeId
The OpcNodeId of the parent node its identifier is to be integrated into the new node identifier.
Returns
A new instance of the OpcNodeId created from the Value and NamespaceIndex of the name
specified.
Exceptions
The name
does not provide a Value nor a NamespaceIndex from that a OpcNodeId can be created (see IsNull).
The name
or parentNodeId
is a null reference (Nothing in Visual Basic).
Creates a new parent-child related OpcNodeId instance from the name
and parentNodeId
specified.
C#
public static OpcNodeId Of(OpcName name, OpcNodeId parentNodeId, char separator)
Parameters
name
OpcName
The OpcName its Value and NamespaceIndex is used to create a new OpcNodeId of the type String.
parentNodeId
OpcNodeId
The OpcNodeId of the parent node its identifier is to be integrated into the new node identifier.
separator
Char
The Char used to separate the child node identifier from the parentNodeId
.
Returns
A new instance of the OpcNodeId created from the Value and NamespaceIndex of the name
specified.
Exceptions
The name
does not provide a Value nor a NamespaceIndex from that a OpcNodeId can be created (see IsNull).
The name
or parentNodeId
is a null reference (Nothing in Visual Basic).
Remarks
In case there the parentNodeId
ends with the separator
specified it will be not adopted by the newly created node identifier.
Resolves this node identifier to a new node identifier its Namespace might be known in the context of the resolver
object specified.
C#
public OpcNodeId Resolve(IOpcNamespaceResolver resolver)
Parameters
resolver
IOpcNamespaceResolver
An instance implementing the IOpcNamespaceResolver interface to use to retrieve the namespace known using the namespace information of this identifier.
Returns
A deep copy of this OpcNodeId using either the resolved namespace or the same namespace as this node identifier.
Exceptions
The resolver
is a null reference (Nothing in Visual Basic).
Returns a string representing the node identifier.
C#
public override string ToString()
Returns
A string formatted using the OriginalFormat from that the OpcNodeId has been constructed. The format dependents on the format detected through calling Parse(String) or the format defined using a specific constructor.
Returns a string representing the node identifier in the format
specified.
C#
public string ToString(OpcNodeIdFormat format)
Parameters
format
OpcNodeIdFormat
One of the formatting styles defined by the OpcNodeIdFormat enumeration.
Returns
A string formatted using the format
specified.
Determines whether a string is a valid node identifier.
C#
public static bool TryParse(string value, out OpcNodeId nodeId)
Parameters
value
String
The string to validate.
nodeId
OpcNodeId
The OpcNodeId version of the string.
Returns
The value true, if value
is a valid node identifier; otherwise the value false.
Retrieves the Value of the nodeId
as an Uri.
C#
public static Uri UriIdentifier(OpcNodeId nodeId)
Parameters
nodeId
OpcNodeId
The OpcNodeId from its Value an Uri is to be retrieved.
Returns
An Uri if the Type of the nodeId
is equals String and the Value can be parsed to an Uri; otherwise a null reference (Nothing in Visual Basic).
Exceptions
The nodeId
is a null reference (Nothing in Visual Basic).
Remarks
This method can be used in scenarios there a server uses Uri-formatted strings as the identifier for its nodes, while its node managers defines different namespaces where the namespaceUris define base-uri's of the node identifier uri's. This allows the framework to determine the manager of a node without the need to know the concrete index of the namespace which defines the identifier of a node.
Defines a new OpcNodeId using the Value, Namespace and Path of this OpcNodeId by combining this Path with the pathElements
specified.
C#
public OpcNodeId WithPath(params OpcName[] pathElements)
Parameters
pathElements
OpcName[]
The elements of the OpcNamePath to use as the logical (= physically not available in the address space) portion to append to the Path of this OpcNodeId for the identifier to create.
Returns
A new OpcNodeId derived from this OpcNodeId by extending the Path using the pathElements
specified.
Remarks
In case there this OpcNodeId is not of the TypeString the new one will be, because of the Path is encoded in the Value.
Defines a new OpcNodeId using the Value, Namespace and Path of this OpcNodeId by combining this Path with the path
specified.
C#
public OpcNodeId WithPath(OpcNamePath path)
Parameters
path
OpcNamePath
The logical (= physically not available in the address space) portion to append to the Path of this OpcNodeId for the identifier to create.
Returns
A new OpcNodeId derived from this OpcNodeId by extending the Path using the path
specified.
Remarks
In case there this OpcNodeId is not of the TypeString the new one will be, because of the Path is encoded in the Value.
Returns a value indicating whether two instance of OpcNodeId are equal.
C#
public static bool operator ==(OpcNodeId left, OpcNodeId right)
Converts a OpcNodeId to an ExpandedNodeId object.
C#
[CLSCompliant(false)] public static explicit operator ExpandedNodeId(OpcNodeId value)
Converts a ExpandedNodeId to an OpcNodeId object.
C#
[CLSCompliant(false)] public static implicit operator OpcNodeId(ExpandedNodeId value)
Returns a value indicating whether two instances of OpcNodeId are not equal.
C#
public static bool operator !=(OpcNodeId left, OpcNodeId right)