# OpcEncodingMask Class

<span class="api-meta">since v2.8</span>

<dl class="api-definition">
<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>Members</dt>
<dd><a href="./members">OpcEncodingMask Members</a></dd>
<dt>Also in</dt>
<dd>Opc.UaFx.Client</dd>
</dl>

Defines the characteristics of the 'EncodingMask' of a type with optional members.

## Syntax

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

```csharp
public class OpcEncodingMask
```

</div>

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

```vbnet
Public Class OpcEncodingMask
```

</div>

## Inheritance

[Object](https://learn.microsoft.com/dotnet/api/system.object) → **OpcEncodingMask**

## Constructors

| Name | Description |
|---|---|
| [OpcEncodingMask](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#opcencodingmask)<span class="api-meta">2 overloads</span> | Initializes a new instance of the OpcEncodingMask class using the `kind` defined while the [Size](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#size) of the mask is determined depending on the [OpcEncodingMaskKind](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmaskkind/) specified. |

## Properties

| Name | Description |
|---|---|
| [Default](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#default)<span class="api-meta">static</span> | Gets the default characteristics used to encode optional members of a type using the [Explicit](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmaskkind/#explicit). |
| [DefaultAuto](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#defaultauto)<span class="api-meta">static · since v2.50</span> | Gets the default characteristics used to encode optional members of a type using the [Auto](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmaskkind/#auto). |
| [Kind](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#kind) | Gets a value which defines how the 'EncodingMask' of a type is used and an which way it is declared and used by the type to control the existence of its optional members. |
| [Size](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#size) | Gets the number of bytes to use for the 'EncodingMask'. |
| [SizeInBits](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcencodingmask/members#sizeinbits) | Gets the number of bits to use for the 'EncodingMask'. |

## Applies to

| Package | Versions |
|---|---|
| Opc.UaFx.Advanced | v2.8–v2.59 |
