# OpcReadOnlyNodeIdCollection Members

> Reference: Provides a read-only collection of OpcNodeId instances.

<dl class="api-definition">
<dt>Type</dt>
<dd><a href="./">OpcReadOnlyNodeIdCollection</a></dd>
<dt>Namespace</dt>
<dd><a href="../namespaces/opc.uafx">Opc.UaFx</a></dd>
<dt>Assembly</dt>
<dd>Opc.UaFx.Advanced.dll</dd>
<dt>Package</dt>
<dd>Opc.UaFx.Advanced v2.59.0</dd>
<dt>Also in</dt>
<dd>Opc.UaFx.Client</dd>
</dl>

Inherits members from [ReadOnlyCollection&lt;OpcNodeId&gt;](https://learn.microsoft.com/dotnet/api/system.collections.objectmodel.readonlycollection-1).

## Constructors

### OpcReadOnlyNodeIdCollection

<span class="api-meta">2 overloads</span>

| Overload | Description |
|---|---|
| [OpcReadOnlyNodeIdCollection(IEnumerable&lt;OpcNodeId&gt;)](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/members#opcreadonlynodeidcollection-system-collections-generic-ienumerable-of-opc-uafx-opcnodeid) | Initializes a new instance of the [OpcReadOnlyNodeIdCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/) class that is a read-only representation of the items in the `enumerable`. |
| [OpcReadOnlyNodeIdCollection(IList&lt;OpcNodeId&gt;)](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/members#opcreadonlynodeidcollection-system-collections-generic-ilist-of-opc-uafx-opcnodeid) | Initializes a new instance of the [OpcReadOnlyNodeIdCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/) class that is a read-only wrapper around the specified `list`. |

#### OpcReadOnlyNodeIdCollection(IEnumerable&lt;OpcNodeId&gt;)

Initializes a new instance of the [OpcReadOnlyNodeIdCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/) class that is a read-only representation of the items in the `enumerable`.

<div class="api-signature" data-lang="csharp">

```csharp
public OpcReadOnlyNodeIdCollection(IEnumerable<OpcNodeId> enumerable)
```

</div>

<div class="api-signature" data-lang="vbnet">

```vbnet
Public Sub New(enumerable As IEnumerable(Of OpcNodeId))
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `enumerable` | [IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[OpcNodeId](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodeid/)&gt; | The [IEnumerable&lt;T&gt;](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1) of [OpcNodeId](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodeid/) values to copy. |

**Exceptions**

| Exception | Condition |
|---|---|
| [ArgumentNullException](https://learn.microsoft.com/dotnet/api/system.argumentnullexception) | The `enumerable` is a null reference (Nothing in Visual Basic). |

#### OpcReadOnlyNodeIdCollection(IList&lt;OpcNodeId&gt;)

Initializes a new instance of the [OpcReadOnlyNodeIdCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcreadonlynodeidcollection/) class that is a read-only wrapper around the specified `list`.

<div class="api-signature" data-lang="csharp">

```csharp
public OpcReadOnlyNodeIdCollection(IList<OpcNodeId> list)
```

</div>

<div class="api-signature" data-lang="vbnet">

```vbnet
Public Sub New(list As IList(Of OpcNodeId))
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `list` | [IList](https://learn.microsoft.com/dotnet/api/system.collections.generic.ilist-1)&lt;[OpcNodeId](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodeid/)&gt; | The [IList&lt;T&gt;](https://learn.microsoft.com/dotnet/api/system.collections.generic.ilist-1) of [OpcNodeId](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodeid/) values to wrap. |

**Exceptions**

| Exception | Condition |
|---|---|
| [ArgumentNullException](https://learn.microsoft.com/dotnet/api/system.argumentnullexception) | The `list` is a null reference (Nothing in Visual Basic). |
