Class WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder>
com.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
- All Implemented Interfaces:
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk
public static final class WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
extends com.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder>
implements WorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder
A PersistentDirectory backed by a Compute Engine regional persistent disk. The [persistent_directories][google.cloud.workstations.v1beta.WorkstationConfig.persistent_directories] field is repeated, but it may contain only one entry. It creates a [persistent disk](https://cloud.google.com/compute/docs/disks/persistent-disks) that mounts to the workstation VM at `/home` when the session starts and detaches when the session ends. If this field is empty, workstations created with this configuration do not have a persistent home directory.Protobuf type
google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Optional.Optional.Optional.Optional.Optional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorOptional.com.google.protobuf.ByteStringOptional.Optional.com.google.protobuf.ByteStringOptional.Optional.intOptional.intOptional.Optional.com.google.protobuf.ByteStringOptional.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setDiskType(String value) Optional.setDiskTypeBytes(com.google.protobuf.ByteString value) Optional.Optional.setFsTypeBytes(com.google.protobuf.ByteString value) Optional.setReclaimPolicy(WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy value) Optional.setReclaimPolicyValue(int value) Optional.setSizeGb(int value) Optional.setSourceSnapshot(String value) Optional.setSourceSnapshotBytes(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, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, 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() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.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.PersistentDirectory.GceRegionalPersistentDisk.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.PersistentDirectory.GceRegionalPersistentDisk.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
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder mergeFrom(com.google.protobuf.Message other) - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder>
-
mergeFrom
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.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.PersistentDirectory.GceRegionalPersistentDisk.Builder>- Throws:
IOException
-
getSizeGb
public int getSizeGb()Optional. The GB capacity of a persistent home directory for each workstation created with this configuration. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Valid values are `10`, `50`, `100`, `200`, `500`, or `1000`. Defaults to `200`. If less than `200` GB, the [disk_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.disk_type] must be `"pd-balanced"` or `"pd-ssd"`.
int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getSizeGbin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The sizeGb.
-
setSizeGb
Optional. The GB capacity of a persistent home directory for each workstation created with this configuration. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Valid values are `10`, `50`, `100`, `200`, `500`, or `1000`. Defaults to `200`. If less than `200` GB, the [disk_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.disk_type] must be `"pd-balanced"` or `"pd-ssd"`.
int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The sizeGb to set.- Returns:
- This builder for chaining.
-
clearSizeGb
Optional. The GB capacity of a persistent home directory for each workstation created with this configuration. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Valid values are `10`, `50`, `100`, `200`, `500`, or `1000`. Defaults to `200`. If less than `200` GB, the [disk_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.disk_type] must be `"pd-balanced"` or `"pd-ssd"`.
int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
getFsType
Optional. Type of file system that the disk should be formatted with. The workstation image must support this file system type. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Defaults to `"ext4"`.
string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getFsTypein interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The fsType.
-
getFsTypeBytes
public com.google.protobuf.ByteString getFsTypeBytes()Optional. Type of file system that the disk should be formatted with. The workstation image must support this file system type. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Defaults to `"ext4"`.
string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getFsTypeBytesin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The bytes for fsType.
-
setFsType
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setFsType(String value) Optional. Type of file system that the disk should be formatted with. The workstation image must support this file system type. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Defaults to `"ext4"`.
string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The fsType to set.- Returns:
- This builder for chaining.
-
clearFsType
Optional. Type of file system that the disk should be formatted with. The workstation image must support this file system type. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Defaults to `"ext4"`.
string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setFsTypeBytes
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setFsTypeBytes(com.google.protobuf.ByteString value) Optional. Type of file system that the disk should be formatted with. The workstation image must support this file system type. Must be empty if [source_snapshot][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.source_snapshot] is set. Defaults to `"ext4"`.
string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for fsType to set.- Returns:
- This builder for chaining.
-
getDiskType
Optional. The [type of the persistent disk](https://cloud.google.com/compute/docs/disks#disk-types) for the home directory. Defaults to `"pd-standard"`.
string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDiskTypein interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The diskType.
-
getDiskTypeBytes
public com.google.protobuf.ByteString getDiskTypeBytes()Optional. The [type of the persistent disk](https://cloud.google.com/compute/docs/disks#disk-types) for the home directory. Defaults to `"pd-standard"`.
string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDiskTypeBytesin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The bytes for diskType.
-
setDiskType
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setDiskType(String value) Optional. The [type of the persistent disk](https://cloud.google.com/compute/docs/disks#disk-types) for the home directory. Defaults to `"pd-standard"`.
string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The diskType to set.- Returns:
- This builder for chaining.
-
clearDiskType
Optional. The [type of the persistent disk](https://cloud.google.com/compute/docs/disks#disk-types) for the home directory. Defaults to `"pd-standard"`.
string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setDiskTypeBytes
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setDiskTypeBytes(com.google.protobuf.ByteString value) Optional. The [type of the persistent disk](https://cloud.google.com/compute/docs/disks#disk-types) for the home directory. Defaults to `"pd-standard"`.
string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for diskType to set.- Returns:
- This builder for chaining.
-
getSourceSnapshot
Optional. Name of the snapshot to use as the source for the disk. If set, [size_gb][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.size_gb] and [fs_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.fs_type] must be empty.
string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getSourceSnapshotin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The sourceSnapshot.
-
getSourceSnapshotBytes
public com.google.protobuf.ByteString getSourceSnapshotBytes()Optional. Name of the snapshot to use as the source for the disk. If set, [size_gb][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.size_gb] and [fs_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.fs_type] must be empty.
string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getSourceSnapshotBytesin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The bytes for sourceSnapshot.
-
setSourceSnapshot
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setSourceSnapshot(String value) Optional. Name of the snapshot to use as the source for the disk. If set, [size_gb][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.size_gb] and [fs_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.fs_type] must be empty.
string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The sourceSnapshot to set.- Returns:
- This builder for chaining.
-
clearSourceSnapshot
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clearSourceSnapshot()Optional. Name of the snapshot to use as the source for the disk. If set, [size_gb][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.size_gb] and [fs_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.fs_type] must be empty.
string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setSourceSnapshotBytes
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setSourceSnapshotBytes(com.google.protobuf.ByteString value) Optional. Name of the snapshot to use as the source for the disk. If set, [size_gb][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.size_gb] and [fs_type][google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.fs_type] must be empty.
string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for sourceSnapshot to set.- Returns:
- This builder for chaining.
-
getReclaimPolicyValue
public int getReclaimPolicyValue()Optional. Whether the persistent disk should be deleted when the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults to `DELETE`.
.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getReclaimPolicyValuein interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The enum numeric value on the wire for reclaimPolicy.
-
setReclaimPolicyValue
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setReclaimPolicyValue(int value) Optional. Whether the persistent disk should be deleted when the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults to `DELETE`.
.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The enum numeric value on the wire for reclaimPolicy to set.- Returns:
- This builder for chaining.
-
getReclaimPolicy
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy getReclaimPolicy()Optional. Whether the persistent disk should be deleted when the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults to `DELETE`.
.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getReclaimPolicyin interfaceWorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder- Returns:
- The reclaimPolicy.
-
setReclaimPolicy
public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setReclaimPolicy(WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy value) Optional. Whether the persistent disk should be deleted when the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults to `DELETE`.
.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The reclaimPolicy to set.- Returns:
- This builder for chaining.
-
clearReclaimPolicy
Optional. Whether the persistent disk should be deleted when the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults to `DELETE`.
.google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-