# Google Cloud Backup Dr V1 Client - Class BackupLock (0.13.0)

0.13.0 (latest) 0.12.1 0.11.1 0.10.0 0.9.0 0.8.1 0.7.0 0.6.2 0.5.1 0.4.2 0.3.0 0.2.0 0.1.0 Reference documentation and code samples for the Google Cloud Backup Dr V1 Client class BackupLock.

BackupLock represents a single lock on a Backup resource. An unexpired
lock on a Backup prevents the Backup from being deleted.

Generated from protobuf message `google.cloud.backupdr.v1.BackupLock`

## Namespace

Google \\ Cloud \\ BackupDR \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ lock_until_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Required. The time after which this lock is not considered valid and will no longer protect the Backup from deletion. |
| `↳ backup_appliance_lock_info` | `https://docs.cloud.google.com/php/docs/reference/cloud-backupdr/latest/V1.BackupApplianceLockInfo` If the client is a backup and recovery appliance, this contains metadata about why the lock exists. |
| `↳ service_lock_info` | `https://docs.cloud.google.com/php/docs/reference/cloud-backupdr/latest/V1.ServiceLockInfo` Output only. Contains metadata about the lock exist for Google Cloud native backups. |

### getLockUntilTime

Required. The time after which this lock is not considered valid and will
no longer protect the Backup from deletion.

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

### hasLockUntilTime

### clearLockUntilTime

### setLockUntilTime

Required. The time after which this lock is not considered valid and will
no longer protect the Backup from deletion.

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

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

### getBackupApplianceLockInfo

If the client is a backup and recovery appliance, this
contains metadata about why the lock exists.

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

### hasBackupApplianceLockInfo

### setBackupApplianceLockInfo

If the client is a backup and recovery appliance, this
contains metadata about why the lock exists.

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

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

### getServiceLockInfo

Output only. Contains metadata about the lock exist for Google Cloud
native backups.

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

### hasServiceLockInfo

### setServiceLockInfo

Output only. Contains metadata about the lock exist for Google Cloud
native backups.

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

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

### getClientLockInfo

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