# OpcNotificationDataSet&lt;T&gt; Members

> Reference: Defines the base class of the data sets of a notification (see Data).

<dl class="api-definition">
<dt>Type</dt>
<dd><a href="./">OpcNotificationDataSet&lt;T&gt;</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>

## Constructors

### OpcNotificationDataSet

<span class="api-meta">protected</span>

Initializes a new instance of the [OpcNotificationDataSet&lt;T&gt;](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotificationdataset-1/) class using the specified `content` of the `notification` specified.

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

```csharp
protected OpcNotificationDataSet(
    NotificationData content,
    OpcNotification notification)
```

</div>

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

```vbnet
Protected Sub New(content As NotificationData, notification As OpcNotification)
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `content` | <abbr title="OPC Foundation stack type, not documented here: Opc.Ua.NotificationData">NotificationData</abbr> | The notification data to represent. |
| `notification` | [OpcNotification](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotification/) | The [OpcNotification](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotification/) which contains the data set. |

**Exceptions**

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

## Properties

### Items

Gets the items of the data set.

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

```csharp
public OpcNotificationDataSetItemReadOnlyCollection<T> Items { get; }
```

</div>

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

```vbnet
Public ReadOnly Property Items As OpcNotificationDataSetItemReadOnlyCollection(Of T)
```

</div>

**Property value**

[OpcNotificationDataSetItemReadOnlyCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotificationdatasetitemreadonlycollection-1/)&lt;T&gt;

A read-only collection of the items of the data set.

**Remarks**

The items are loaded using [LoadItems](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotificationdataset-1/members#loaditems) as long as the collection is empty.

### Notification

Gets the notification which contains the data set.

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

```csharp
public OpcNotification Notification { get; }
```

</div>

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

```vbnet
Public ReadOnly Property Notification As OpcNotification
```

</div>

**Property value**

[OpcNotification](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotification/)

The [OpcNotification](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotification/) which contains the data set.

**Implements**

[Notification](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.iopcnotificationdataset/members#notification)

## Methods

### LoadItems

<span class="api-meta">protected · virtual</span>

When overridden in a derived class, adds the items of the data set to the `items` specified.

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

```csharp
protected virtual void LoadItems(OpcNotificationDataSetItemCollection<T> items)
```

</div>

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

```vbnet
Protected Overridable Sub LoadItems(
    items As OpcNotificationDataSetItemCollection(Of T))
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `items` | [OpcNotificationDataSetItemCollection](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnotificationdatasetitemcollection-1/)&lt;T&gt; | The collection to add the items to. |

**Remarks**

The default implementation does not add any items.
