Class Environment.Builder (0.41.0)

public static final class Environment.Builder extends GeneratedMessageV3.Builder<Environment.Builder> implements EnvironmentOrBuilder

An Environment describes a collection of environment variables to set when executing Tasks.

Protobuf type google.cloud.batch.v1alpha.Environment

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Environment.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Environment.Builder
Overrides

build()

public Environment build()
Returns
TypeDescription
Environment

buildPartial()

public Environment buildPartial()
Returns
TypeDescription
Environment

clear()

public Environment.Builder clear()
Returns
TypeDescription
Environment.Builder
Overrides

clearEncryptedVariables()

public Environment.Builder clearEncryptedVariables()

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Returns
TypeDescription
Environment.Builder

clearField(Descriptors.FieldDescriptor field)

public Environment.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Environment.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public Environment.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Environment.Builder
Overrides

clearSecretVariables()

public Environment.Builder clearSecretVariables()
Returns
TypeDescription
Environment.Builder

clearVariables()

public Environment.Builder clearVariables()
Returns
TypeDescription
Environment.Builder

clone()

public Environment.Builder clone()
Returns
TypeDescription
Environment.Builder
Overrides

containsSecretVariables(String key)

public boolean containsSecretVariables(String key)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

containsVariables(String key)

public boolean containsVariables(String key)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getDefaultInstanceForType()

public Environment getDefaultInstanceForType()
Returns
TypeDescription
Environment

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEncryptedVariables()

public Environment.KMSEnvMap getEncryptedVariables()

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Returns
TypeDescription
Environment.KMSEnvMap

The encryptedVariables.

getEncryptedVariablesBuilder()

public Environment.KMSEnvMap.Builder getEncryptedVariablesBuilder()

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Returns
TypeDescription
Environment.KMSEnvMap.Builder

getEncryptedVariablesOrBuilder()

public Environment.KMSEnvMapOrBuilder getEncryptedVariablesOrBuilder()

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Returns
TypeDescription
Environment.KMSEnvMapOrBuilder

getMutableSecretVariables() (deprecated)

public Map<String,String> getMutableSecretVariables()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,String>

getMutableVariables() (deprecated)

public Map<String,String> getMutableVariables()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,String>

getSecretVariables() (deprecated)

public Map<String,String> getSecretVariables()
Returns
TypeDescription
Map<String,String>

getSecretVariablesCount()

public int getSecretVariablesCount()

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Returns
TypeDescription
int

getSecretVariablesMap()

public Map<String,String> getSecretVariablesMap()

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Returns
TypeDescription
Map<String,String>

getSecretVariablesOrDefault(String key, String defaultValue)

public String getSecretVariablesOrDefault(String key, String defaultValue)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getSecretVariablesOrThrow(String key)

public String getSecretVariablesOrThrow(String key)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

getVariables() (deprecated)

public Map<String,String> getVariables()

Use #getVariablesMap() instead.

Returns
TypeDescription
Map<String,String>

getVariablesCount()

public int getVariablesCount()

A map of environment variable names to values.

map<string, string> variables = 1;

Returns
TypeDescription
int

getVariablesMap()

public Map<String,String> getVariablesMap()

A map of environment variable names to values.

map<string, string> variables = 1;

Returns
TypeDescription
Map<String,String>

getVariablesOrDefault(String key, String defaultValue)

public String getVariablesOrDefault(String key, String defaultValue)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getVariablesOrThrow(String key)

public String getVariablesOrThrow(String key)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

hasEncryptedVariables()

public boolean hasEncryptedVariables()

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Returns
TypeDescription
boolean

Whether the encryptedVariables field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeEncryptedVariables(Environment.KMSEnvMap value)

public Environment.Builder mergeEncryptedVariables(Environment.KMSEnvMap value)

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Parameter
NameDescription
valueEnvironment.KMSEnvMap
Returns
TypeDescription
Environment.Builder

mergeFrom(Environment other)

public Environment.Builder mergeFrom(Environment other)
Parameter
NameDescription
otherEnvironment
Returns
TypeDescription
Environment.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Environment.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Environment.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Environment.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Environment.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Environment.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Environment.Builder
Overrides

putAllSecretVariables(Map<String,String> values)

public Environment.Builder putAllSecretVariables(Map<String,String> values)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameter
NameDescription
valuesMap<String,String>
Returns
TypeDescription
Environment.Builder

putAllVariables(Map<String,String> values)

public Environment.Builder putAllVariables(Map<String,String> values)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameter
NameDescription
valuesMap<String,String>
Returns
TypeDescription
Environment.Builder

putSecretVariables(String key, String value)

public Environment.Builder putSecretVariables(String key, String value)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameters
NameDescription
keyString
valueString
Returns
TypeDescription
Environment.Builder

putVariables(String key, String value)

public Environment.Builder putVariables(String key, String value)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameters
NameDescription
keyString
valueString
Returns
TypeDescription
Environment.Builder

removeSecretVariables(String key)

public Environment.Builder removeSecretVariables(String key)

A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.

map<string, string> secret_variables = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
Environment.Builder

removeVariables(String key)

public Environment.Builder removeVariables(String key)

A map of environment variable names to values.

map<string, string> variables = 1;

Parameter
NameDescription
keyString
Returns
TypeDescription
Environment.Builder

setEncryptedVariables(Environment.KMSEnvMap value)

public Environment.Builder setEncryptedVariables(Environment.KMSEnvMap value)

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Parameter
NameDescription
valueEnvironment.KMSEnvMap
Returns
TypeDescription
Environment.Builder

setEncryptedVariables(Environment.KMSEnvMap.Builder builderForValue)

public Environment.Builder setEncryptedVariables(Environment.KMSEnvMap.Builder builderForValue)

An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values.

.google.cloud.batch.v1alpha.Environment.KMSEnvMap encrypted_variables = 3;

Parameter
NameDescription
builderForValueEnvironment.KMSEnvMap.Builder
Returns
TypeDescription
Environment.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public Environment.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Environment.Builder
Overrides

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

public Environment.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Environment.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Environment.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Environment.Builder
Overrides