Google Cloud Backup Dr V1 Client - Class CreateAutoProtectionPolicyRequest (0.17.0)

Reference documentation and code samples for the Google Cloud Backup Dr V1 Client class CreateAutoProtectionPolicyRequest.

Request message for creating an AutoProtectionPolicy.

Generated from protobuf message google.cloud.backupdr.v1.CreateAutoProtectionPolicyRequest

Namespace

Google \ Cloud \ BackupDR \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ parent string

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

↳ auto_protection_policy_id string

Required. The ID to use for the policy. This will become the final component of the policy's resource name. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.

↳ auto_protection_policy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

↳ request_id string

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

getParent

Required. The parent resource where this policy will be created.

Format: projects/{project}/locations/{location}

Returns
Type Description
string

setParent

Required. The parent resource where this policy will be created.

Format: projects/{project}/locations/{location}

Parameter
Name Description
var string
Returns
Type Description
$this

getAutoProtectionPolicyId

Required. The ID to use for the policy.

This will become the final component of the policy's resource name. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.

Returns
Type Description
string

setAutoProtectionPolicyId

Required. The ID to use for the policy.

This will become the final component of the policy's resource name. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.

Parameter
Name Description
var string
Returns
Type Description
$this

getAutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

Returns
Type Description
AutoProtectionPolicy|null

hasAutoProtectionPolicy

clearAutoProtectionPolicy

setAutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

Parameter
Name Description
var AutoProtectionPolicy
Returns
Type Description
$this

getRequestId

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

Returns
Type Description
string

setRequestId

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

Parameter
Name Description
var string
Returns
Type Description
$this

static::build

Parameters
Name Description
parent string

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location} Please see BackupDRClient::locationName() for help formatting this field.

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.

Returns
Type Description
CreateAutoProtectionPolicyRequest