Class EncryptionSpec.Builder (0.12.0)

public static final class EncryptionSpec.Builder extends GeneratedMessage.Builder<EncryptionSpec.Builder> implements EncryptionSpecOrBuilder

Represents a customer-managed encryption key specification that can be applied to a Vector Search collection.

Protobuf type google.cloud.vectorsearch.v1.EncryptionSpec

Static Methods

getDescriptor()

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

Methods

build()

public EncryptionSpec build()
Returns
Type Description
EncryptionSpec

buildPartial()

public EncryptionSpec buildPartial()
Returns
Type Description
EncryptionSpec

clear()

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

clearCryptoKeyName()

public EncryptionSpec.Builder clearCryptoKeyName()

Required. Resource name of the Cloud KMS key used to protect the resource.

The Cloud KMS key must be in the same region as the resource. It must have the format projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.

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

Returns
Type Description
EncryptionSpec.Builder

This builder for chaining.

getCryptoKeyName()

public String getCryptoKeyName()

Required. Resource name of the Cloud KMS key used to protect the resource.

The Cloud KMS key must be in the same region as the resource. It must have the format projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.

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

Returns
Type Description
String

The cryptoKeyName.

getCryptoKeyNameBytes()

public ByteString getCryptoKeyNameBytes()

Required. Resource name of the Cloud KMS key used to protect the resource.

The Cloud KMS key must be in the same region as the resource. It must have the format projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.

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

Returns
Type Description
ByteString

The bytes for cryptoKeyName.

getDefaultInstanceForType()

public EncryptionSpec getDefaultInstanceForType()
Returns
Type Description
EncryptionSpec

getDescriptorForType()

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

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(EncryptionSpec other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setCryptoKeyName(String value)

public EncryptionSpec.Builder setCryptoKeyName(String value)

Required. Resource name of the Cloud KMS key used to protect the resource.

The Cloud KMS key must be in the same region as the resource. It must have the format projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.

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

Parameter
Name Description
value String

The cryptoKeyName to set.

Returns
Type Description
EncryptionSpec.Builder

This builder for chaining.

setCryptoKeyNameBytes(ByteString value)

public EncryptionSpec.Builder setCryptoKeyNameBytes(ByteString value)

Required. Resource name of the Cloud KMS key used to protect the resource.

The Cloud KMS key must be in the same region as the resource. It must have the format projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}.

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

Parameter
Name Description
value ByteString

The bytes for cryptoKeyName to set.

Returns
Type Description
EncryptionSpec.Builder

This builder for chaining.