Class WorkstationConfig.Container.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
com.google.cloud.workstations.v1beta.WorkstationConfig.Container.Builder
- All Implemented Interfaces:
WorkstationConfig.ContainerOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- WorkstationConfig.Container
public static final class WorkstationConfig.Container.Builder
extends com.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
implements WorkstationConfig.ContainerOrBuilder
A Docker container.Protobuf type
google.cloud.workstations.v1beta.WorkstationConfig.Container-
Method Summary
Modifier and TypeMethodDescriptionaddAllArgs(Iterable<String> values) Optional.addAllCommand(Iterable<String> values) Optional.Optional.addArgsBytes(com.google.protobuf.ByteString value) Optional.addCommand(String value) Optional.addCommandBytes(com.google.protobuf.ByteString value) Optional.build()clear()Optional.Optional.clearEnv()Optional.Optional.Optional.booleancontainsEnv(String key) Optional.getArgs(int index) Optional.com.google.protobuf.ByteStringgetArgsBytes(int index) Optional.intOptional.com.google.protobuf.ProtocolStringListOptional.getCommand(int index) Optional.com.google.protobuf.ByteStringgetCommandBytes(int index) Optional.intOptional.com.google.protobuf.ProtocolStringListOptional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorgetEnv()Deprecated.intOptional.Optional.getEnvOrDefault(String key, String defaultValue) Optional.getEnvOrThrow(String key) Optional.getImage()Optional.com.google.protobuf.ByteStringOptional.Deprecated.intOptional.Optional.com.google.protobuf.ByteStringOptional.protected com.google.protobuf.GeneratedMessage.FieldAccessorTableprotected com.google.protobuf.MapFieldReflectionAccessorinternalGetMapFieldReflection(int number) protected com.google.protobuf.MapFieldReflectionAccessorinternalGetMutableMapFieldReflection(int number) final booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) Optional.Optional.Optional.Optional.setCommand(int index, String value) Optional.Optional.setImageBytes(com.google.protobuf.ByteString value) Optional.setRunAsUser(int value) Optional.setWorkingDir(String value) Optional.setWorkingDirBytes(com.google.protobuf.ByteString value) Optional.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetMapFieldReflection
protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number) - Overrides:
internalGetMapFieldReflectionin classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
internalGetMutableMapFieldReflection
protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number) - Overrides:
internalGetMutableMapFieldReflectionin classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<WorkstationConfig.Container.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.Container.Builder>
-
mergeFrom
public WorkstationConfig.Container.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<WorkstationConfig.Container.Builder>- Throws:
IOException
-
getImage
Optional. A Docker container image that defines a custom environment. Cloud Workstations provides a number of [preconfigured images](https://cloud.google.com/workstations/docs/preconfigured-base-images), but you can create your own [custom container images](https://cloud.google.com/workstations/docs/custom-container-images). If using a private image, the `host.gceInstance.serviceAccount` field must be specified in the workstation configuration and must have permission to pull the specified image. Otherwise, the image must be publicly accessible.
string image = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getImagein interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The image.
-
getImageBytes
public com.google.protobuf.ByteString getImageBytes()Optional. A Docker container image that defines a custom environment. Cloud Workstations provides a number of [preconfigured images](https://cloud.google.com/workstations/docs/preconfigured-base-images), but you can create your own [custom container images](https://cloud.google.com/workstations/docs/custom-container-images). If using a private image, the `host.gceInstance.serviceAccount` field must be specified in the workstation configuration and must have permission to pull the specified image. Otherwise, the image must be publicly accessible.
string image = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getImageBytesin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The bytes for image.
-
setImage
Optional. A Docker container image that defines a custom environment. Cloud Workstations provides a number of [preconfigured images](https://cloud.google.com/workstations/docs/preconfigured-base-images), but you can create your own [custom container images](https://cloud.google.com/workstations/docs/custom-container-images). If using a private image, the `host.gceInstance.serviceAccount` field must be specified in the workstation configuration and must have permission to pull the specified image. Otherwise, the image must be publicly accessible.
string image = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The image to set.- Returns:
- This builder for chaining.
-
clearImage
Optional. A Docker container image that defines a custom environment. Cloud Workstations provides a number of [preconfigured images](https://cloud.google.com/workstations/docs/preconfigured-base-images), but you can create your own [custom container images](https://cloud.google.com/workstations/docs/custom-container-images). If using a private image, the `host.gceInstance.serviceAccount` field must be specified in the workstation configuration and must have permission to pull the specified image. Otherwise, the image must be publicly accessible.
string image = 1 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setImageBytes
Optional. A Docker container image that defines a custom environment. Cloud Workstations provides a number of [preconfigured images](https://cloud.google.com/workstations/docs/preconfigured-base-images), but you can create your own [custom container images](https://cloud.google.com/workstations/docs/custom-container-images). If using a private image, the `host.gceInstance.serviceAccount` field must be specified in the workstation configuration and must have permission to pull the specified image. Otherwise, the image must be publicly accessible.
string image = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for image to set.- Returns:
- This builder for chaining.
-
getCommandList
public com.google.protobuf.ProtocolStringList getCommandList()Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getCommandListin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- A list containing the command.
-
getCommandCount
public int getCommandCount()Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getCommandCountin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The count of command.
-
getCommand
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getCommandin interfaceWorkstationConfig.ContainerOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The command at the given index.
-
getCommandBytes
public com.google.protobuf.ByteString getCommandBytes(int index) Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getCommandBytesin interfaceWorkstationConfig.ContainerOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the command at the given index.
-
setCommand
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
index- The index to set the value at.value- The command to set.- Returns:
- This builder for chaining.
-
addCommand
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The command to add.- Returns:
- This builder for chaining.
-
addAllCommand
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
values- The command to add.- Returns:
- This builder for chaining.
-
clearCommand
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
addCommandBytes
Optional. If set, overrides the default ENTRYPOINT specified by the image.
repeated string command = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes of the command to add.- Returns:
- This builder for chaining.
-
getArgsList
public com.google.protobuf.ProtocolStringList getArgsList()Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getArgsListin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- A list containing the args.
-
getArgsCount
public int getArgsCount()Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getArgsCountin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The count of args.
-
getArgs
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getArgsin interfaceWorkstationConfig.ContainerOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The args at the given index.
-
getArgsBytes
public com.google.protobuf.ByteString getArgsBytes(int index) Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getArgsBytesin interfaceWorkstationConfig.ContainerOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the args at the given index.
-
setArgs
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
index- The index to set the value at.value- The args to set.- Returns:
- This builder for chaining.
-
addArgs
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The args to add.- Returns:
- This builder for chaining.
-
addAllArgs
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
values- The args to add.- Returns:
- This builder for chaining.
-
clearArgs
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
addArgsBytes
Optional. Arguments passed to the entrypoint.
repeated string args = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes of the args to add.- Returns:
- This builder for chaining.
-
getEnvCount
public int getEnvCount()Description copied from interface:WorkstationConfig.ContainerOrBuilderOptional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getEnvCountin interfaceWorkstationConfig.ContainerOrBuilder
-
containsEnv
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
containsEnvin interfaceWorkstationConfig.ContainerOrBuilder
-
getEnv
Deprecated.UsegetEnvMap()instead.- Specified by:
getEnvin interfaceWorkstationConfig.ContainerOrBuilder
-
getEnvMap
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getEnvMapin interfaceWorkstationConfig.ContainerOrBuilder
-
getEnvOrDefault
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getEnvOrDefaultin interfaceWorkstationConfig.ContainerOrBuilder
-
getEnvOrThrow
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getEnvOrThrowin interfaceWorkstationConfig.ContainerOrBuilder
-
clearEnv
-
removeEnv
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL]; -
getMutableEnv
Deprecated.Use alternate mutation accessors instead. -
putEnv
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL]; -
putAllEnv
Optional. Environment variables passed to the container's entrypoint.
map<string, string> env = 4 [(.google.api.field_behavior) = OPTIONAL]; -
getWorkingDir
Optional. If set, overrides the default DIR specified by the image.
string working_dir = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getWorkingDirin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The workingDir.
-
getWorkingDirBytes
public com.google.protobuf.ByteString getWorkingDirBytes()Optional. If set, overrides the default DIR specified by the image.
string working_dir = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getWorkingDirBytesin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The bytes for workingDir.
-
setWorkingDir
Optional. If set, overrides the default DIR specified by the image.
string working_dir = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The workingDir to set.- Returns:
- This builder for chaining.
-
clearWorkingDir
Optional. If set, overrides the default DIR specified by the image.
string working_dir = 5 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setWorkingDirBytes
Optional. If set, overrides the default DIR specified by the image.
string working_dir = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for workingDir to set.- Returns:
- This builder for chaining.
-
getRunAsUser
public int getRunAsUser()Optional. If set, overrides the USER specified in the image with the given uid.
int32 run_as_user = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getRunAsUserin interfaceWorkstationConfig.ContainerOrBuilder- Returns:
- The runAsUser.
-
setRunAsUser
Optional. If set, overrides the USER specified in the image with the given uid.
int32 run_as_user = 6 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The runAsUser to set.- Returns:
- This builder for chaining.
-
clearRunAsUser
Optional. If set, overrides the USER specified in the image with the given uid.
int32 run_as_user = 6 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-