1.6.0 (latest) 1.5.0 1.4.0 1.3.0 1.2.0 1.1.0 1.0.0

    public sealed class DataPolicy : IMessage<DataPolicy>, IEquatable<DataPolicy>, IDeepCloneable<DataPolicy>, IBufferMessage, IMessage

Reference documentation and code samples for the BigQuery Data Policy v1 API class DataPolicy.

Represents the label-policy binding.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> DataPolicy

## Implements

[IMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.md.txt)[DataPolicy](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.DataPolicy.md.txt), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[DataPolicy](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.DataPolicy.md.txt), [IDeepCloneable](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.md.txt)[DataPolicy](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.DataPolicy.md.txt), [IBufferMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.md.txt), [IMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.md.txt)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.BigQuery.DataPolicies.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.md.txt)

## Assembly

Google.Cloud.BigQuery.DataPolicies.V1.dll

## Constructors

### DataPolicy()

    public DataPolicy()

### DataPolicy(DataPolicy)

    public DataPolicy(DataPolicy other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `DataPolicy` |

## Properties

### DataMaskingPolicy

    public DataMaskingPolicy DataMaskingPolicy { get; set; }

The data masking policy that specifies the data masking rule to use.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `DataMaskingPolicy` |   |

### DataPolicyId

    public string DataPolicyId { get; set; }

User-assigned (human readable) ID of the data policy that needs to be
unique within a project. Used as {data_policy_id} in part of the resource
name.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### DataPolicyName

    public DataPolicyName DataPolicyName { get; set; }

[DataPolicyName](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.DataPolicyName.md.txt)-typed view over the [Name](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.BigQuery.DataPolicies.V1/latest/Google.Cloud.BigQuery.DataPolicies.V1.DataPolicy.md.txt#Google_Cloud_BigQuery_DataPolicies_V1_DataPolicy_Name) resource name property.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `DataPolicyName` |   |

### DataPolicyType

    public DataPolicy.Types.DataPolicyType DataPolicyType { get; set; }

Type of data policy.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `DataPolicyTypesDataPolicyType` |   |

### HasPolicyTag

    public bool HasPolicyTag { get; }

Gets whether the "policy_tag" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### MatchingLabelCase

    public DataPolicy.MatchingLabelOneofCase MatchingLabelCase { get; }

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `DataPolicyMatchingLabelOneofCase` |   |

### Name

    public string Name { get; set; }

Output only. Resource name of this data policy, in the format of
`projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### PolicyCase

    public DataPolicy.PolicyOneofCase PolicyCase { get; }

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `DataPolicyPolicyOneofCase` |   |

### PolicyTag

    public string PolicyTag { get; set; }

Policy tag resource name, in the format of
`projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |