# Google Cloud Net App V1 Client - Class Backup (1.12.0)

1.12.0 (latest) 1.11.0 1.10.2 1.9.0 1.8.1 1.7.0 1.6.1 1.4.0 1.3.1 1.2.1 1.1.1 1.0.1 0.3.1 0.2.6 0.1.1 Reference documentation and code samples for the Google Cloud Net App V1 Client class Backup.

A NetApp Backup.

Generated from protobuf message `google.cloud.netapp.v1.Backup`

## Namespace

Google \\ Cloud \\ NetApp \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. The resource name of the backup. Format: `projects/{project_id}/locations/{location}/backupVaults/{backup_vault_id}/backups/{backup_id}`. |
| `↳ state` | `int` Output only. The backup state. |
| `↳ description` | `string` A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected. |
| `↳ volume_usage_bytes` | `int|string` Output only. Size of the file system when the backup was created. When creating a new volume from the backup, the volume capacity will have to be at least as big. |
| `↳ backup_type` | `int` Output only. Type of backup, manually created or created by a backup policy. |
| `↳ source_volume` | `string` Volume full name of this backup belongs to. Either source_volume or ontap_source should be provided. Format: `projects/{projects_id}/locations/{location}/volumes/{volume_id}` |
| `↳ source_snapshot` | `string` If specified, backup will be created from the given snapshot. If not specified, there will be a new snapshot taken to initiate the backup creation. Format: `projects/{project_id}/locations/{location}/volumes/{volume_id}/snapshots/{snapshot_id}` |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The time when the backup was created. |
| `↳ labels` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Resource labels to represent user provided metadata. |
| `↳ chain_storage_bytes` | `int|string` Output only. Total size of all backups in a chain in bytes = baseline backup size + sum(incremental backup size) |
| `↳ satisfies_pzs` | `bool` Output only. Reserved for future use |
| `↳ satisfies_pzi` | `bool` Output only. Reserved for future use |
| `↳ volume_region` | `string` Output only. Region of the volume from which the backup was created. Format: `projects/{project_id}/locations/{location}` |
| `↳ backup_region` | `string` Output only. Region in which backup is stored. Format: `projects/{project_id}/locations/{location}` |
| `↳ enforced_retention_end_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The time until which the backup is not deletable. |

### getName

Identifier. The resource name of the backup.

Format:
`projects/{project_id}/locations/{location}/backupVaults/{backup_vault_id}/backups/{backup_id}`.

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

### setName

Identifier. The resource name of the backup.

Format:
`projects/{project_id}/locations/{location}/backupVaults/{backup_vault_id}/backups/{backup_id}`.

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

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

### getState

Output only. The backup state.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-netapp/latest/V1.Backup.State). |

### setState

Output only. The backup state.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-netapp/latest/V1.Backup.State). |

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

### getDescription

A description of the backup with 2048 characters or less.

Requests with longer descriptions will be rejected.

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

### setDescription

A description of the backup with 2048 characters or less.

Requests with longer descriptions will be rejected.

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

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

### getVolumeUsageBytes

Output only. Size of the file system when the backup was created. When
creating a new volume from the backup, the volume capacity will have to be
at least as big.

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

### setVolumeUsageBytes

Output only. Size of the file system when the backup was created. When
creating a new volume from the backup, the volume capacity will have to be
at least as big.

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

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

### getBackupType

Output only. Type of backup, manually created or created by a backup
policy.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [Type](https://docs.cloud.google.com/php/docs/reference/cloud-netapp/latest/V1.Backup.Type). |

### setBackupType

Output only. Type of backup, manually created or created by a backup
policy.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [Type](https://docs.cloud.google.com/php/docs/reference/cloud-netapp/latest/V1.Backup.Type). |

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

### getSourceVolume

Volume full name of this backup belongs to.

Either source_volume or ontap_source should be provided.
Format:
`projects/{projects_id}/locations/{location}/volumes/{volume_id}`

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

### setSourceVolume

Volume full name of this backup belongs to.

Either source_volume or ontap_source should be provided.
Format:
`projects/{projects_id}/locations/{location}/volumes/{volume_id}`

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

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

### getSourceSnapshot

If specified, backup will be created from the given snapshot.

If not specified, there will be a new snapshot taken to initiate the backup
creation. Format:
`projects/{project_id}/locations/{location}/volumes/{volume_id}/snapshots/{snapshot_id}`

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

### hasSourceSnapshot

### clearSourceSnapshot

### setSourceSnapshot

If specified, backup will be created from the given snapshot.

If not specified, there will be a new snapshot taken to initiate the backup
creation. Format:
`projects/{project_id}/locations/{location}/volumes/{volume_id}/snapshots/{snapshot_id}`

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

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

### getCreateTime

Output only. The time when the backup was created.

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. The time when the backup was created.

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

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

### getLabels

Resource labels to represent user provided metadata.

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

### setLabels

Resource labels to represent user provided metadata.

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

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

### getChainStorageBytes

Output only. Total size of all backups in a chain in bytes = baseline
backup size + sum(incremental backup size)

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

### setChainStorageBytes

Output only. Total size of all backups in a chain in bytes = baseline
backup size + sum(incremental backup size)

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

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

### getSatisfiesPzs

Output only. Reserved for future use

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

### setSatisfiesPzs

Output only. Reserved for future use

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

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

### getSatisfiesPzi

Output only. Reserved for future use

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

### setSatisfiesPzi

Output only. Reserved for future use

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

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

### getVolumeRegion

Output only. Region of the volume from which the backup was created.

Format: `projects/{project_id}/locations/{location}`

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

### setVolumeRegion

Output only. Region of the volume from which the backup was created.

Format: `projects/{project_id}/locations/{location}`

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

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

### getBackupRegion

Output only. Region in which backup is stored.

Format: `projects/{project_id}/locations/{location}`

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

### setBackupRegion

Output only. Region in which backup is stored.

Format: `projects/{project_id}/locations/{location}`

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

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

### getEnforcedRetentionEndTime

Output only. The time until which the backup is not deletable.

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

### hasEnforcedRetentionEndTime

### clearEnforcedRetentionEndTime

### setEnforcedRetentionEndTime

Output only. The time until which the backup is not deletable.

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

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