Class InlineSecret.Builder (3.50.0)

public static final class InlineSecret.Builder extends GeneratedMessageV3.Builder<InlineSecret.Builder> implements InlineSecretOrBuilder

Pairs a set of secret environment variables mapped to encrypted values with the Cloud KMS key to use to decrypt the value.

Protobuf type google.devtools.cloudbuild.v1.InlineSecret

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public InlineSecret build()
Returns
Type Description
InlineSecret

buildPartial()

public InlineSecret buildPartial()
Returns
Type Description
InlineSecret

clear()

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

clearEnvMap()

public InlineSecret.Builder clearEnvMap()
Returns
Type Description
InlineSecret.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearKmsKeyName()

public InlineSecret.Builder clearKmsKeyName()

Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*

string kms_key_name = 1 [(.google.api.resource_reference) = { ... }

Returns
Type Description
InlineSecret.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

containsEnvMap(String key)

public boolean containsEnvMap(String key)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Parameter
Name Description
key String
Returns
Type Description
boolean

getDefaultInstanceForType()

public InlineSecret getDefaultInstanceForType()
Returns
Type Description
InlineSecret

getDescriptorForType()

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

getEnvMap() (deprecated)

public Map<String,ByteString> getEnvMap()

Use #getEnvMapMap() instead.

Returns
Type Description
Map<String,ByteString>

getEnvMapCount()

public int getEnvMapCount()

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Returns
Type Description
int

getEnvMapMap()

public Map<String,ByteString> getEnvMapMap()

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Returns
Type Description
Map<String,ByteString>

getEnvMapOrDefault(String key, ByteString defaultValue)

public ByteString getEnvMapOrDefault(String key, ByteString defaultValue)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Parameters
Name Description
key String
defaultValue ByteString
Returns
Type Description
ByteString

getEnvMapOrThrow(String key)

public ByteString getEnvMapOrThrow(String key)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Parameter
Name Description
key String
Returns
Type Description
ByteString

getKmsKeyName()

public String getKmsKeyName()

Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*

string kms_key_name = 1 [(.google.api.resource_reference) = { ... }

Returns
Type Description
String

The kmsKeyName.

getKmsKeyNameBytes()

public ByteString getKmsKeyNameBytes()

Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*

string kms_key_name = 1 [(.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for kmsKeyName.

getMutableEnvMap() (deprecated)

public Map<String,ByteString> getMutableEnvMap()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,ByteString>

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

mergeFrom(InlineSecret other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

putAllEnvMap(Map<String,ByteString> values)

public InlineSecret.Builder putAllEnvMap(Map<String,ByteString> values)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

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

putEnvMap(String key, ByteString value)

public InlineSecret.Builder putEnvMap(String key, ByteString value)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Parameters
Name Description
key String
value ByteString
Returns
Type Description
InlineSecret.Builder

removeEnvMap(String key)

public InlineSecret.Builder removeEnvMap(String key)

Map of environment variable name to its encrypted value.

Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.

map<string, bytes> env_map = 2;

Parameter
Name Description
key String
Returns
Type Description
InlineSecret.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setKmsKeyName(String value)

public InlineSecret.Builder setKmsKeyName(String value)

Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*

string kms_key_name = 1 [(.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The kmsKeyName to set.

Returns
Type Description
InlineSecret.Builder

This builder for chaining.

setKmsKeyNameBytes(ByteString value)

public InlineSecret.Builder setKmsKeyNameBytes(ByteString value)

Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*

string kms_key_name = 1 [(.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for kmsKeyName to set.

Returns
Type Description
InlineSecret.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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