# Google Cloud OsConfig V1 Client - Class ExecutePatchJobRequest (2.2.3)

2.2.3 (latest) 2.2.2 2.1.0 2.0.5 1.3.5 1.2.2 1.1.1 1.0.5 Reference documentation and code samples for the Google Cloud OsConfig V1 Client class ExecutePatchJobRequest.

A request message to initiate patching across Compute Engine
instances.

Generated from protobuf message `google.cloud.osconfig.v1.ExecutePatchJobRequest`

## Namespace

Google \\ Cloud \\ OsConfig \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ parent` | `string` Required. The project in which to run this patch in the form `projects/*` |
| `↳ description` | `string` Description of the patch job. Length of the description is limited to 1024 characters. |
| `↳ instance_filter` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchInstanceFilter` Required. Instances to patch, either explicitly or filtered by some criteria such as zone or labels. |
| `↳ patch_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchConfig` Patch configuration being applied. If omitted, instances are patched using the default configurations. |
| `↳ duration` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Duration` Duration of the patch job. After the duration ends, the patch job times out. |
| `↳ dry_run` | `bool` If this patch is a dry-run only, instances are contacted but will do nothing. |
| `↳ display_name` | `string` Display name for this patch job. This does not have to be unique. |
| `↳ rollout` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchRollout` Rollout strategy of the patch job. |

### getParent

Required. The project in which to run this patch in the form `projects/*`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setParent

Required. The project in which to run this patch in the form `projects/*`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

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

### getDescription

Description of the patch job. Length of the description is limited
to 1024 characters.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setDescription

Description of the patch job. Length of the description is limited
to 1024 characters.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

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

### getInstanceFilter

Required. Instances to patch, either explicitly or filtered by some
criteria such as zone or labels.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchInstanceFilter|null` |   |

### hasInstanceFilter

### clearInstanceFilter

### setInstanceFilter

Required. Instances to patch, either explicitly or filtered by some
criteria such as zone or labels.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchInstanceFilter` |

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

### getPatchConfig

Patch configuration being applied. If omitted, instances are
patched using the default configurations.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchConfig|null` |   |

### hasPatchConfig

### clearPatchConfig

### setPatchConfig

Patch configuration being applied. If omitted, instances are
patched using the default configurations.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchConfig` |

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

### getDuration

Duration of the patch job. After the duration ends, the patch job
times out.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Duration|null` |   |

### hasDuration

### clearDuration

### setDuration

Duration of the patch job. After the duration ends, the patch job
times out.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Duration` |

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

### getDryRun

If this patch is a dry-run only, instances are contacted but
will do nothing.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setDryRun

If this patch is a dry-run only, instances are contacted but
will do nothing.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

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

### getDisplayName

Display name for this patch job. This does not have to be unique.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setDisplayName

Display name for this patch job. This does not have to be unique.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

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

### getRollout

Rollout strategy of the patch job.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchRollout|null` |   |

### hasRollout

### clearRollout

### setRollout

Rollout strategy of the patch job.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-osconfig/latest/V1.PatchRollout` |

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