Class WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder (0.15.0)

public static final class WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder extends GeneratedMessageV3.Builder<WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder> implements WorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder

A PersistentDirectory backed by a Compute Engine regional persistent disk. The persistent_directories field is repeated, but it may contain only one entry. It creates a persistent disk 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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

Inheritance

Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk build()
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

buildPartial()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk buildPartial()
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

clear()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clear()
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

clearDiskType()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clearDiskType()

Optional. The type of the persistent disk for the home directory. Defaults to "pd-standard".

string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

clearFsType()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder 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 is set. Defaults to "ext4".

string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

clearReclaimPolicy()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder 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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

clearSizeGb()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clearSizeGb()

Optional. The GB capacity of a persistent home directory for each workstation created with this configuration. Must be empty if 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 must be "pd-balanced" or "pd-ssd".

int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

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 and fs_type must be empty.

string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

clone()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder clone()
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

getDefaultInstanceForType()

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk getDefaultInstanceForType()
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDiskType()

public String getDiskType()

Optional. The type of the persistent disk for the home directory. Defaults to "pd-standard".

string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The diskType.

getDiskTypeBytes()

public ByteString getDiskTypeBytes()

Optional. The type of the persistent disk for the home directory. Defaults to "pd-standard".

string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for diskType.

getFsType()

public String 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 is set. Defaults to "ext4".

string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The fsType.

getFsTypeBytes()

public 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 is set. Defaults to "ext4".

string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for fsType.

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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy

The reclaimPolicy.

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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The enum numeric value on the wire for reclaimPolicy.

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 is set.

Valid values are 10, 50, 100, 200, 500, or 1000. Defaults to 200. If less than 200 GB, the disk_type must be "pd-balanced" or "pd-ssd".

int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The sizeGb.

getSourceSnapshot()

public String getSourceSnapshot()

Optional. Name of the snapshot to use as the source for the disk. If set, size_gb and fs_type must be empty.

string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The sourceSnapshot.

getSourceSnapshotBytes()

public ByteString getSourceSnapshotBytes()

Optional. Name of the snapshot to use as the source for the disk. If set, size_gb and fs_type must be empty.

string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for sourceSnapshot.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk other)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder mergeFrom(WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk other)
Parameter
NameDescription
otherWorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides

setDiskType(String value)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setDiskType(String value)

Optional. The type of the persistent disk for the home directory. Defaults to "pd-standard".

string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The diskType to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setDiskTypeBytes(ByteString value)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setDiskTypeBytes(ByteString value)

Optional. The type of the persistent disk for the home directory. Defaults to "pd-standard".

string disk_type = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for diskType to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setFsType(String value)

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 is set. Defaults to "ext4".

string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The fsType to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setFsTypeBytes(ByteString value)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setFsTypeBytes(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 is set. Defaults to "ext4".

string fs_type = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for fsType to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setReclaimPolicy(WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy value)

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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueWorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy

The reclaimPolicy to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setReclaimPolicyValue(int value)

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.v1.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy reclaim_policy = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueint

The enum numeric value on the wire for reclaimPolicy to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

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

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

setSizeGb(int value)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setSizeGb(int value)

Optional. The GB capacity of a persistent home directory for each workstation created with this configuration. Must be empty if 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 must be "pd-balanced" or "pd-ssd".

int32 size_gb = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueint

The sizeGb to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setSourceSnapshot(String value)

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 and fs_type must be empty.

string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The sourceSnapshot to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setSourceSnapshotBytes(ByteString value)

public WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setSourceSnapshotBytes(ByteString value)

Optional. Name of the snapshot to use as the source for the disk. If set, size_gb and fs_type must be empty.

string source_snapshot = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for sourceSnapshot to set.

Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder
Overrides