# Google Cloud Gke Backup V1 Client - Class Filter (1.3.3)

1.3.3 (latest) 1.3.2 1.2.1 1.0.3 0.8.1 0.7.2 0.6.0 0.5.3 0.4.0 0.3.1 0.2.0 0.1.7 Reference documentation and code samples for the Google Cloud Gke Backup V1 Client class Filter.

Defines the filter for `Restore`. This filter can be used to further
refine the resource selection of the `Restore` beyond the coarse-grained
scope defined in the `RestorePlan`. `exclusion_filters` take precedence
over `inclusion_filters`. If a resource matches both `inclusion_filters`
and `exclusion_filters`, it will not be restored.

Generated from protobuf message `google.cloud.gkebackup.v1.Restore.Filter`

## Namespace

Google \\ Cloud \\ GkeBackup \\ V1 \\ Restore

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ inclusion_filters` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` Optional. Selects resources for restoration. If specified, only resources which match `inclusion_filters` will be selected for restoration. A resource will be selected if it matches any `ResourceSelector` of the `inclusion_filters`. |
| `↳ exclusion_filters` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` Optional. Excludes resources from restoration. If specified, a resource will not be restored if it matches any `ResourceSelector` of the `exclusion_filters`. |

### getInclusionFilters

Optional. Selects resources for restoration. If specified, only resources
which match `inclusion_filters` will be selected for restoration. A
resource will be selected if it matches any `ResourceSelector` of the
`inclusion_filters`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` |   |

### setInclusionFilters

Optional. Selects resources for restoration. If specified, only resources
which match `inclusion_filters` will be selected for restoration. A
resource will be selected if it matches any `ResourceSelector` of the
`inclusion_filters`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getExclusionFilters

Optional. Excludes resources from restoration. If specified,
a resource will not be restored if it matches
any `ResourceSelector` of the `exclusion_filters`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` |   |

### setExclusionFilters

Optional. Excludes resources from restoration. If specified,
a resource will not be restored if it matches
any `ResourceSelector` of the `exclusion_filters`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-gke-backup/latest/V1.ResourceSelector>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |