Class BackupPlan.Builder (0.10.0)

public static final class BackupPlan.Builder extends GeneratedMessageV3.Builder<BackupPlan.Builder> implements BackupPlanOrBuilder

A BackupPlan specifies some common fields, such as description as well as one or more BackupRule messages. Each BackupRule has a retention policy and defines a schedule by which the system is to perform backup workloads.

Protobuf type google.cloud.backupdr.v1.BackupPlan

Implements

BackupPlanOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllBackupRules(Iterable<? extends BackupRule> values)

public BackupPlan.Builder addAllBackupRules(Iterable<? extends BackupRule> values)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
values Iterable<? extends com.google.cloud.backupdr.v1.BackupRule>
Returns
Type Description
BackupPlan.Builder

addBackupRules(BackupRule value)

public BackupPlan.Builder addBackupRules(BackupRule value)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value BackupRule
Returns
Type Description
BackupPlan.Builder

addBackupRules(BackupRule.Builder builderForValue)

public BackupPlan.Builder addBackupRules(BackupRule.Builder builderForValue)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
builderForValue BackupRule.Builder
Returns
Type Description
BackupPlan.Builder

addBackupRules(int index, BackupRule value)

public BackupPlan.Builder addBackupRules(int index, BackupRule value)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
index int
value BackupRule
Returns
Type Description
BackupPlan.Builder

addBackupRules(int index, BackupRule.Builder builderForValue)

public BackupPlan.Builder addBackupRules(int index, BackupRule.Builder builderForValue)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
index int
builderForValue BackupRule.Builder
Returns
Type Description
BackupPlan.Builder

addBackupRulesBuilder()

public BackupRule.Builder addBackupRulesBuilder()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
BackupRule.Builder

addBackupRulesBuilder(int index)

public BackupRule.Builder addBackupRulesBuilder(int index)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
index int
Returns
Type Description
BackupRule.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public BackupPlan.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

build()

public BackupPlan build()
Returns
Type Description
BackupPlan

buildPartial()

public BackupPlan buildPartial()
Returns
Type Description
BackupPlan

clear()

public BackupPlan.Builder clear()
Returns
Type Description
BackupPlan.Builder
Overrides

clearBackupRules()

public BackupPlan.Builder clearBackupRules()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
BackupPlan.Builder

clearBackupVault()

public BackupPlan.Builder clearBackupVault()

Required. Resource name of backup vault which will be used as storage location for backups. Format: projects/{project}/locations/{location}/backupVaults/{backupvault}

string backup_vault = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearBackupVaultServiceAccount()

public BackupPlan.Builder clearBackupVaultServiceAccount()

Output only. The Google Cloud Platform Service Account to be used by the BackupVault for taking backups. Specify the email address of the Backup Vault Service Account.

string backup_vault_service_account = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearCreateTime()

public BackupPlan.Builder clearCreateTime()

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

clearDescription()

public BackupPlan.Builder clearDescription()

Optional. The description of the BackupPlan resource.

The description allows for additional details about BackupPlan and its use cases to be provided. An example description is the following: "This is a backup plan that performs a daily backup at 6pm and retains data for 3 months". The description must be at most 2048 characters.

string description = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearEtag()

public BackupPlan.Builder clearEtag()

Optional. etag is returned from the service in the response. As a user of the service, you may provide an etag value in this field to prevent stale resources.

string etag = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public BackupPlan.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
BackupPlan.Builder
Overrides

clearLabels()

public BackupPlan.Builder clearLabels()
Returns
Type Description
BackupPlan.Builder

clearName()

public BackupPlan.Builder clearName()

Output only. Identifier. The resource name of the BackupPlan.

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

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public BackupPlan.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
BackupPlan.Builder
Overrides

clearResourceType()

public BackupPlan.Builder clearResourceType()

Required. The resource type to which the BackupPlan will be applied. Examples include, "compute.googleapis.com/Instance" and "storage.googleapis.com/Bucket".

string resource_type = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearState()

public BackupPlan.Builder clearState()

Output only. The State for the BackupPlan.

.google.cloud.backupdr.v1.BackupPlan.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearUpdateTime()

public BackupPlan.Builder clearUpdateTime()

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

clone()

public BackupPlan.Builder clone()
Returns
Type Description
BackupPlan.Builder
Overrides

containsLabels(String key)

public boolean containsLabels(String key)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
boolean

getBackupRules(int index)

public BackupRule getBackupRules(int index)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
index int
Returns
Type Description
BackupRule

getBackupRulesBuilder(int index)

public BackupRule.Builder getBackupRulesBuilder(int index)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
index int
Returns
Type Description
BackupRule.Builder

getBackupRulesBuilderList()

public List<BackupRule.Builder> getBackupRulesBuilderList()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
List<Builder>

getBackupRulesCount()

public int getBackupRulesCount()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
int

getBackupRulesList()

public List<BackupRule> getBackupRulesList()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
List<BackupRule>

getBackupRulesOrBuilder(int index)

public BackupRuleOrBuilder getBackupRulesOrBuilder(int index)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
index int
Returns
Type Description
BackupRuleOrBuilder

getBackupRulesOrBuilderList()

public List<? extends BackupRuleOrBuilder> getBackupRulesOrBuilderList()

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
List<? extends com.google.cloud.backupdr.v1.BackupRuleOrBuilder>

getBackupVault()

public String getBackupVault()

Required. Resource name of backup vault which will be used as storage location for backups. Format: projects/{project}/locations/{location}/backupVaults/{backupvault}

string backup_vault = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The backupVault.

getBackupVaultBytes()

public ByteString getBackupVaultBytes()

Required. Resource name of backup vault which will be used as storage location for backups. Format: projects/{project}/locations/{location}/backupVaults/{backupvault}

string backup_vault = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for backupVault.

getBackupVaultServiceAccount()

public String getBackupVaultServiceAccount()

Output only. The Google Cloud Platform Service Account to be used by the BackupVault for taking backups. Specify the email address of the Backup Vault Service Account.

string backup_vault_service_account = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The backupVaultServiceAccount.

getBackupVaultServiceAccountBytes()

public ByteString getBackupVaultServiceAccountBytes()

Output only. The Google Cloud Platform Service Account to be used by the BackupVault for taking backups. Specify the email address of the Backup Vault Service Account.

string backup_vault_service_account = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for backupVaultServiceAccount.

getCreateTime()

public Timestamp getCreateTime()

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

getDefaultInstanceForType()

public BackupPlan getDefaultInstanceForType()
Returns
Type Description
BackupPlan

getDescription()

public String getDescription()

Optional. The description of the BackupPlan resource.

The description allows for additional details about BackupPlan and its use cases to be provided. An example description is the following: "This is a backup plan that performs a daily backup at 6pm and retains data for 3 months". The description must be at most 2048 characters.

string description = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Optional. The description of the BackupPlan resource.

The description allows for additional details about BackupPlan and its use cases to be provided. An example description is the following: "This is a backup plan that performs a daily backup at 6pm and retains data for 3 months". The description must be at most 2048 characters.

string description = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getEtag()

public String getEtag()

Optional. etag is returned from the service in the response. As a user of the service, you may provide an etag value in this field to prevent stale resources.

string etag = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The etag.

getEtagBytes()

public ByteString getEtagBytes()

Optional. etag is returned from the service in the response. As a user of the service, you may provide an etag value in this field to prevent stale resources.

string etag = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for etag.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
Type Description
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
String

getMutableLabels() (deprecated)

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getName()

public String getName()

Output only. Identifier. The resource name of the BackupPlan.

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

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Output only. Identifier. The resource name of the BackupPlan.

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

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
ByteString

The bytes for name.

getResourceType()

public String getResourceType()

Required. The resource type to which the BackupPlan will be applied. Examples include, "compute.googleapis.com/Instance" and "storage.googleapis.com/Bucket".

string resource_type = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The resourceType.

getResourceTypeBytes()

public ByteString getResourceTypeBytes()

Required. The resource type to which the BackupPlan will be applied. Examples include, "compute.googleapis.com/Instance" and "storage.googleapis.com/Bucket".

string resource_type = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for resourceType.

getState()

public BackupPlan.State getState()

Output only. The State for the BackupPlan.

.google.cloud.backupdr.v1.BackupPlan.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.State

The state.

getStateValue()

public int getStateValue()

Output only. The State for the BackupPlan.

.google.cloud.backupdr.v1.BackupPlan.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The enum numeric value on the wire for state.

getUpdateTime()

public Timestamp getUpdateTime()

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The updateTime.

getUpdateTimeBuilder()

public Timestamp.Builder getUpdateTimeBuilder()

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

hasCreateTime()

public boolean hasCreateTime()

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the createTime field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the updateTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeCreateTime(Timestamp value)

public BackupPlan.Builder mergeCreateTime(Timestamp value)

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

mergeFrom(BackupPlan other)

public BackupPlan.Builder mergeFrom(BackupPlan other)
Parameter
Name Description
other BackupPlan
Returns
Type Description
BackupPlan.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public BackupPlan.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackupPlan.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public BackupPlan.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
BackupPlan.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final BackupPlan.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
BackupPlan.Builder
Overrides

mergeUpdateTime(Timestamp value)

public BackupPlan.Builder mergeUpdateTime(Timestamp value)

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

putAllLabels(Map<String,String> values)

public BackupPlan.Builder putAllLabels(Map<String,String> values)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Map<String,String>
Returns
Type Description
BackupPlan.Builder

putLabels(String key, String value)

public BackupPlan.Builder putLabels(String key, String value)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
value String
Returns
Type Description
BackupPlan.Builder

removeBackupRules(int index)

public BackupPlan.Builder removeBackupRules(int index)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
index int
Returns
Type Description
BackupPlan.Builder

removeLabels(String key)

public BackupPlan.Builder removeLabels(String key)

Optional. This collection of key/value pairs allows for custom labels to be supplied by the user. Example, {"tag": "Weekly"}.

map<string, string> labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
BackupPlan.Builder

setBackupRules(int index, BackupRule value)

public BackupPlan.Builder setBackupRules(int index, BackupRule value)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
index int
value BackupRule
Returns
Type Description
BackupPlan.Builder

setBackupRules(int index, BackupRule.Builder builderForValue)

public BackupPlan.Builder setBackupRules(int index, BackupRule.Builder builderForValue)

Required. The backup rules for this BackupPlan. There must be at least one BackupRule message.

repeated .google.cloud.backupdr.v1.BackupRule backup_rules = 6 [(.google.api.field_behavior) = REQUIRED];

Parameters
Name Description
index int
builderForValue BackupRule.Builder
Returns
Type Description
BackupPlan.Builder

setBackupVault(String value)

public BackupPlan.Builder setBackupVault(String value)

Required. Resource name of backup vault which will be used as storage location for backups. Format: projects/{project}/locations/{location}/backupVaults/{backupvault}

string backup_vault = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The backupVault to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setBackupVaultBytes(ByteString value)

public BackupPlan.Builder setBackupVaultBytes(ByteString value)

Required. Resource name of backup vault which will be used as storage location for backups. Format: projects/{project}/locations/{location}/backupVaults/{backupvault}

string backup_vault = 10 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for backupVault to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setBackupVaultServiceAccount(String value)

public BackupPlan.Builder setBackupVaultServiceAccount(String value)

Output only. The Google Cloud Platform Service Account to be used by the BackupVault for taking backups. Specify the email address of the Backup Vault Service Account.

string backup_vault_service_account = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The backupVaultServiceAccount to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setBackupVaultServiceAccountBytes(ByteString value)

public BackupPlan.Builder setBackupVaultServiceAccountBytes(ByteString value)

Output only. The Google Cloud Platform Service Account to be used by the BackupVault for taking backups. Specify the email address of the Backup Vault Service Account.

string backup_vault_service_account = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for backupVaultServiceAccount to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setCreateTime(Timestamp value)

public BackupPlan.Builder setCreateTime(Timestamp value)

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

setCreateTime(Timestamp.Builder builderForValue)

public BackupPlan.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. When the BackupPlan was created.

.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
BackupPlan.Builder

setDescription(String value)

public BackupPlan.Builder setDescription(String value)

Optional. The description of the BackupPlan resource.

The description allows for additional details about BackupPlan and its use cases to be provided. An example description is the following: "This is a backup plan that performs a daily backup at 6pm and retains data for 3 months". The description must be at most 2048 characters.

string description = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The description to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public BackupPlan.Builder setDescriptionBytes(ByteString value)

Optional. The description of the BackupPlan resource.

The description allows for additional details about BackupPlan and its use cases to be provided. An example description is the following: "This is a backup plan that performs a daily backup at 6pm and retains data for 3 months". The description must be at most 2048 characters.

string description = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for description to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setEtag(String value)

public BackupPlan.Builder setEtag(String value)

Optional. etag is returned from the service in the response. As a user of the service, you may provide an etag value in this field to prevent stale resources.

string etag = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The etag to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setEtagBytes(ByteString value)

public BackupPlan.Builder setEtagBytes(ByteString value)

Optional. etag is returned from the service in the response. As a user of the service, you may provide an etag value in this field to prevent stale resources.

string etag = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for etag to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public BackupPlan.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

setName(String value)

public BackupPlan.Builder setName(String value)

Output only. Identifier. The resource name of the BackupPlan.

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

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setNameBytes(ByteString value)

public BackupPlan.Builder setNameBytes(ByteString value)

Output only. Identifier. The resource name of the BackupPlan.

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

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public BackupPlan.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

setResourceType(String value)

public BackupPlan.Builder setResourceType(String value)

Required. The resource type to which the BackupPlan will be applied. Examples include, "compute.googleapis.com/Instance" and "storage.googleapis.com/Bucket".

string resource_type = 8 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The resourceType to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setResourceTypeBytes(ByteString value)

public BackupPlan.Builder setResourceTypeBytes(ByteString value)

Required. The resource type to which the BackupPlan will be applied. Examples include, "compute.googleapis.com/Instance" and "storage.googleapis.com/Bucket".

string resource_type = 8 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for resourceType to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setState(BackupPlan.State value)

public BackupPlan.Builder setState(BackupPlan.State value)

Output only. The State for the BackupPlan.

.google.cloud.backupdr.v1.BackupPlan.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value BackupPlan.State

The state to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setStateValue(int value)

public BackupPlan.Builder setStateValue(int value)

Output only. The State for the BackupPlan.

.google.cloud.backupdr.v1.BackupPlan.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The enum numeric value on the wire for state to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final BackupPlan.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
BackupPlan.Builder
Overrides

setUpdateTime(Timestamp value)

public BackupPlan.Builder setUpdateTime(Timestamp value)

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

setUpdateTime(Timestamp.Builder builderForValue)

public BackupPlan.Builder setUpdateTime(Timestamp.Builder builderForValue)

Output only. When the BackupPlan was last updated.

.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
BackupPlan.Builder