Class DiskUpdateKmsKeyRequest.Builder (1.105.0)

public static final class DiskUpdateKmsKeyRequest.Builder extends GeneratedMessage.Builder<DiskUpdateKmsKeyRequest.Builder> implements DiskUpdateKmsKeyRequestOrBuilder

Protobuf type google.cloud.compute.v1.DiskUpdateKmsKeyRequest

Static Methods

getDescriptor()

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

Methods

build()

public DiskUpdateKmsKeyRequest build()
Returns
Type Description
DiskUpdateKmsKeyRequest

buildPartial()

public DiskUpdateKmsKeyRequest buildPartial()
Returns
Type Description
DiskUpdateKmsKeyRequest

clear()

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

clearKmsKeyName()

public DiskUpdateKmsKeyRequest.Builder clearKmsKeyName()

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Returns
Type Description
DiskUpdateKmsKeyRequest.Builder

This builder for chaining.

getDefaultInstanceForType()

public DiskUpdateKmsKeyRequest getDefaultInstanceForType()
Returns
Type Description
DiskUpdateKmsKeyRequest

getDescriptorForType()

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

getKmsKeyName()

public String getKmsKeyName()

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Returns
Type Description
String

The kmsKeyName.

getKmsKeyNameBytes()

public ByteString getKmsKeyNameBytes()

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Returns
Type Description
ByteString

The bytes for kmsKeyName.

hasKmsKeyName()

public boolean hasKmsKeyName()

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Returns
Type Description
boolean

Whether the kmsKeyName field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DiskUpdateKmsKeyRequest other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setKmsKeyName(String value)

public DiskUpdateKmsKeyRequest.Builder setKmsKeyName(String value)

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Parameter
Name Description
value String

The kmsKeyName to set.

Returns
Type Description
DiskUpdateKmsKeyRequest.Builder

This builder for chaining.

setKmsKeyNameBytes(ByteString value)

public DiskUpdateKmsKeyRequest.Builder setKmsKeyNameBytes(ByteString value)

Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key.

The KMS key can be provided in the following formats:

  • projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key

Where project is the project ID or project number.

optional string kms_key_name = 484373913;

Parameter
Name Description
value ByteString

The bytes for kmsKeyName to set.

Returns
Type Description
DiskUpdateKmsKeyRequest.Builder

This builder for chaining.