Class BackupInstanceRequest.Builder (0.29.0)

public static final class BackupInstanceRequest.Builder extends GeneratedMessage.Builder<BackupInstanceRequest.Builder> implements BackupInstanceRequestOrBuilder

Request for [BackupInstance].

Protobuf type google.cloud.memorystore.v1.BackupInstanceRequest

Static Methods

getDescriptor()

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

Methods

build()

public BackupInstanceRequest build()
Returns
Type Description
BackupInstanceRequest

buildPartial()

public BackupInstanceRequest buildPartial()
Returns
Type Description
BackupInstanceRequest

clear()

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

clearBackupId()

public BackupInstanceRequest.Builder clearBackupId()

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

clearName()

public BackupInstanceRequest.Builder clearName()

Required. Instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a Google Cloud region.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

clearTtl()

public BackupInstanceRequest.Builder clearTtl()

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupInstanceRequest.Builder

getBackupId()

public String getBackupId()

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The backupId.

getBackupIdBytes()

public ByteString getBackupIdBytes()

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for backupId.

getDefaultInstanceForType()

public BackupInstanceRequest getDefaultInstanceForType()
Returns
Type Description
BackupInstanceRequest

getDescriptorForType()

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

getName()

public String getName()

Required. Instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a Google Cloud region.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Required. Instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a Google Cloud region.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for name.

getTtl()

public Duration getTtl()

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Duration

The ttl.

getTtlBuilder()

public Duration.Builder getTtlBuilder()

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getTtlOrBuilder()

public DurationOrBuilder getTtlOrBuilder()

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DurationOrBuilder

hasBackupId()

public boolean hasBackupId()

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the backupId field is set.

hasTtl()

public boolean hasTtl()

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the ttl field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(BackupInstanceRequest other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeTtl(Duration value)

public BackupInstanceRequest.Builder mergeTtl(Duration value)

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
BackupInstanceRequest.Builder

setBackupId(String value)

public BackupInstanceRequest.Builder setBackupId(String value)

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The backupId to set.

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

setBackupIdBytes(ByteString value)

public BackupInstanceRequest.Builder setBackupIdBytes(ByteString value)

Optional. The id of the backup to be created. If not specified, the default value ([YYYYMMDDHHMMSS]_[Shortened Instance UID] is used.

optional string backup_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for backupId to set.

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

setName(String value)

public BackupInstanceRequest.Builder setName(String value)

Required. Instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a Google Cloud region.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The name to set.

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

setNameBytes(ByteString value)

public BackupInstanceRequest.Builder setNameBytes(ByteString value)

Required. Instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a Google Cloud region.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
BackupInstanceRequest.Builder

This builder for chaining.

setTtl(Duration value)

public BackupInstanceRequest.Builder setTtl(Duration value)

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
BackupInstanceRequest.Builder

setTtl(Duration.Builder builderForValue)

public BackupInstanceRequest.Builder setTtl(Duration.Builder builderForValue)

Optional. TTL for the backup to expire. Value range is 1 day to 100 years. If not specified, the default value is 100 years.

.google.protobuf.Duration ttl = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
BackupInstanceRequest.Builder