Class AllocationPolicy.InstancePolicy.Builder (0.5.0)

public static final class AllocationPolicy.InstancePolicy.Builder extends GeneratedMessageV3.Builder<AllocationPolicy.InstancePolicy.Builder> implements AllocationPolicy.InstancePolicyOrBuilder

InstancePolicy describes an instance type and resources attached to each VM created by this InstancePolicy.

Protobuf type google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy

Static Methods

getDescriptor()

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

Methods

addAccelerators(AllocationPolicy.Accelerator value)

public AllocationPolicy.InstancePolicy.Builder addAccelerators(AllocationPolicy.Accelerator value)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
value AllocationPolicy.Accelerator
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAccelerators(AllocationPolicy.Accelerator.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder addAccelerators(AllocationPolicy.Accelerator.Builder builderForValue)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
builderForValue AllocationPolicy.Accelerator.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAccelerators(int index, AllocationPolicy.Accelerator value)

public AllocationPolicy.InstancePolicy.Builder addAccelerators(int index, AllocationPolicy.Accelerator value)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameters
Name Description
index int
value AllocationPolicy.Accelerator
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAccelerators(int index, AllocationPolicy.Accelerator.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder addAccelerators(int index, AllocationPolicy.Accelerator.Builder builderForValue)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameters
Name Description
index int
builderForValue AllocationPolicy.Accelerator.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAcceleratorsBuilder()

public AllocationPolicy.Accelerator.Builder addAcceleratorsBuilder()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
AllocationPolicy.Accelerator.Builder

addAcceleratorsBuilder(int index)

public AllocationPolicy.Accelerator.Builder addAcceleratorsBuilder(int index)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.Accelerator.Builder

addAllAccelerators(Iterable<? extends AllocationPolicy.Accelerator> values)

public AllocationPolicy.InstancePolicy.Builder addAllAccelerators(Iterable<? extends AllocationPolicy.Accelerator> values)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
values Iterable<? extends com.google.cloud.batch.v1alpha.AllocationPolicy.Accelerator>
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAllAllowedMachineTypes(Iterable<String> values) (deprecated)

public AllocationPolicy.InstancePolicy.Builder addAllAllowedMachineTypes(Iterable<String> values)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameter
Name Description
values Iterable<String>

The allowedMachineTypes to add.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

addAllDisks(Iterable<? extends AllocationPolicy.AttachedDisk> values)

public AllocationPolicy.InstancePolicy.Builder addAllDisks(Iterable<? extends AllocationPolicy.AttachedDisk> values)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
values Iterable<? extends com.google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk>
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addAllowedMachineTypes(String value) (deprecated)

public AllocationPolicy.InstancePolicy.Builder addAllowedMachineTypes(String value)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameter
Name Description
value String

The allowedMachineTypes to add.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

addAllowedMachineTypesBytes(ByteString value) (deprecated)

public AllocationPolicy.InstancePolicy.Builder addAllowedMachineTypesBytes(ByteString value)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameter
Name Description
value ByteString

The bytes of the allowedMachineTypes to add.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

addDisks(AllocationPolicy.AttachedDisk value)

public AllocationPolicy.InstancePolicy.Builder addDisks(AllocationPolicy.AttachedDisk value)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
value AllocationPolicy.AttachedDisk
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addDisks(AllocationPolicy.AttachedDisk.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder addDisks(AllocationPolicy.AttachedDisk.Builder builderForValue)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
builderForValue AllocationPolicy.AttachedDisk.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addDisks(int index, AllocationPolicy.AttachedDisk value)

public AllocationPolicy.InstancePolicy.Builder addDisks(int index, AllocationPolicy.AttachedDisk value)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameters
Name Description
index int
value AllocationPolicy.AttachedDisk
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addDisks(int index, AllocationPolicy.AttachedDisk.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder addDisks(int index, AllocationPolicy.AttachedDisk.Builder builderForValue)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameters
Name Description
index int
builderForValue AllocationPolicy.AttachedDisk.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

addDisksBuilder()

public AllocationPolicy.AttachedDisk.Builder addDisksBuilder()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
AllocationPolicy.AttachedDisk.Builder

addDisksBuilder(int index)

public AllocationPolicy.AttachedDisk.Builder addDisksBuilder(int index)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.AttachedDisk.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public AllocationPolicy.InstancePolicy build()
Returns
Type Description
AllocationPolicy.InstancePolicy

buildPartial()

public AllocationPolicy.InstancePolicy buildPartial()
Returns
Type Description
AllocationPolicy.InstancePolicy

clear()

public AllocationPolicy.InstancePolicy.Builder clear()
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder
Overrides

clearAccelerators()

public AllocationPolicy.InstancePolicy.Builder clearAccelerators()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

clearAllowedMachineTypes() (deprecated)

public AllocationPolicy.InstancePolicy.Builder clearAllowedMachineTypes()

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

clearDisks()

public AllocationPolicy.InstancePolicy.Builder clearDisks()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearMachineType()

public AllocationPolicy.InstancePolicy.Builder clearMachineType()

The Compute Engine machine type.

string machine_type = 2;

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

clearMinCpuPlatform()

public AllocationPolicy.InstancePolicy.Builder clearMinCpuPlatform()

The minimum CPU platform. See https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform. Not yet implemented.

string min_cpu_platform = 3;

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearProvisioningModel()

public AllocationPolicy.InstancePolicy.Builder clearProvisioningModel()

The provisioning model.

.google.cloud.batch.v1alpha.AllocationPolicy.ProvisioningModel provisioning_model = 4;

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

clone()

public AllocationPolicy.InstancePolicy.Builder clone()
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder
Overrides

getAccelerators(int index)

public AllocationPolicy.Accelerator getAccelerators(int index)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.Accelerator

getAcceleratorsBuilder(int index)

public AllocationPolicy.Accelerator.Builder getAcceleratorsBuilder(int index)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.Accelerator.Builder

getAcceleratorsBuilderList()

public List<AllocationPolicy.Accelerator.Builder> getAcceleratorsBuilderList()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
List<Builder>

getAcceleratorsCount()

public int getAcceleratorsCount()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
int

getAcceleratorsList()

public List<AllocationPolicy.Accelerator> getAcceleratorsList()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
List<Accelerator>

getAcceleratorsOrBuilder(int index)

public AllocationPolicy.AcceleratorOrBuilder getAcceleratorsOrBuilder(int index)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.AcceleratorOrBuilder

getAcceleratorsOrBuilderList()

public List<? extends AllocationPolicy.AcceleratorOrBuilder> getAcceleratorsOrBuilderList()

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Returns
Type Description
List<? extends com.google.cloud.batch.v1alpha.AllocationPolicy.AcceleratorOrBuilder>

getAllowedMachineTypes(int index) (deprecated)

public String getAllowedMachineTypes(int index)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The allowedMachineTypes at the given index.

getAllowedMachineTypesBytes(int index) (deprecated)

public ByteString getAllowedMachineTypesBytes(int index)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the allowedMachineTypes at the given index.

getAllowedMachineTypesCount() (deprecated)

public int getAllowedMachineTypesCount()

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Returns
Type Description
int

The count of allowedMachineTypes.

getAllowedMachineTypesList() (deprecated)

public ProtocolStringList getAllowedMachineTypesList()

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Returns
Type Description
ProtocolStringList

A list containing the allowedMachineTypes.

getDefaultInstanceForType()

public AllocationPolicy.InstancePolicy getDefaultInstanceForType()
Returns
Type Description
AllocationPolicy.InstancePolicy

getDescriptorForType()

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

getDisks(int index)

public AllocationPolicy.AttachedDisk getDisks(int index)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.AttachedDisk

getDisksBuilder(int index)

public AllocationPolicy.AttachedDisk.Builder getDisksBuilder(int index)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.AttachedDisk.Builder

getDisksBuilderList()

public List<AllocationPolicy.AttachedDisk.Builder> getDisksBuilderList()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
List<Builder>

getDisksCount()

public int getDisksCount()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
int

getDisksList()

public List<AllocationPolicy.AttachedDisk> getDisksList()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
List<AttachedDisk>

getDisksOrBuilder(int index)

public AllocationPolicy.AttachedDiskOrBuilder getDisksOrBuilder(int index)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.AttachedDiskOrBuilder

getDisksOrBuilderList()

public List<? extends AllocationPolicy.AttachedDiskOrBuilder> getDisksOrBuilderList()

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Returns
Type Description
List<? extends com.google.cloud.batch.v1alpha.AllocationPolicy.AttachedDiskOrBuilder>

getMachineType()

public String getMachineType()

The Compute Engine machine type.

string machine_type = 2;

Returns
Type Description
String

The machineType.

getMachineTypeBytes()

public ByteString getMachineTypeBytes()

The Compute Engine machine type.

string machine_type = 2;

Returns
Type Description
ByteString

The bytes for machineType.

getMinCpuPlatform()

public String getMinCpuPlatform()

The minimum CPU platform. See https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform. Not yet implemented.

string min_cpu_platform = 3;

Returns
Type Description
String

The minCpuPlatform.

getMinCpuPlatformBytes()

public ByteString getMinCpuPlatformBytes()

The minimum CPU platform. See https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform. Not yet implemented.

string min_cpu_platform = 3;

Returns
Type Description
ByteString

The bytes for minCpuPlatform.

getProvisioningModel()

public AllocationPolicy.ProvisioningModel getProvisioningModel()

The provisioning model.

.google.cloud.batch.v1alpha.AllocationPolicy.ProvisioningModel provisioning_model = 4;

Returns
Type Description
AllocationPolicy.ProvisioningModel

The provisioningModel.

getProvisioningModelValue()

public int getProvisioningModelValue()

The provisioning model.

.google.cloud.batch.v1alpha.AllocationPolicy.ProvisioningModel provisioning_model = 4;

Returns
Type Description
int

The enum numeric value on the wire for provisioningModel.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(AllocationPolicy.InstancePolicy other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeAccelerators(int index)

public AllocationPolicy.InstancePolicy.Builder removeAccelerators(int index)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

removeDisks(int index)

public AllocationPolicy.InstancePolicy.Builder removeDisks(int index)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameter
Name Description
index int
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

setAccelerators(int index, AllocationPolicy.Accelerator value)

public AllocationPolicy.InstancePolicy.Builder setAccelerators(int index, AllocationPolicy.Accelerator value)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameters
Name Description
index int
value AllocationPolicy.Accelerator
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

setAccelerators(int index, AllocationPolicy.Accelerator.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder setAccelerators(int index, AllocationPolicy.Accelerator.Builder builderForValue)

The accelerators attached to each VM instance. Not yet implemented.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.Accelerator accelerators = 5;

Parameters
Name Description
index int
builderForValue AllocationPolicy.Accelerator.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

setAllowedMachineTypes(int index, String value) (deprecated)

public AllocationPolicy.InstancePolicy.Builder setAllowedMachineTypes(int index, String value)

Deprecated. google.cloud.batch.v1alpha.AllocationPolicy.InstancePolicy.allowed_machine_types is deprecated. See google/cloud/batch/v1alpha/job.proto;l=354

Deprecated: please use machine_type instead.

repeated string allowed_machine_types = 1 [deprecated = true];

Parameters
Name Description
index int

The index to set the value at.

value String

The allowedMachineTypes to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setDisks(int index, AllocationPolicy.AttachedDisk value)

public AllocationPolicy.InstancePolicy.Builder setDisks(int index, AllocationPolicy.AttachedDisk value)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameters
Name Description
index int
value AllocationPolicy.AttachedDisk
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

setDisks(int index, AllocationPolicy.AttachedDisk.Builder builderForValue)

public AllocationPolicy.InstancePolicy.Builder setDisks(int index, AllocationPolicy.AttachedDisk.Builder builderForValue)

Non-boot disks to be attached for each VM created by this InstancePolicy. New disks will be deleted when the attached VM is deleted.

repeated .google.cloud.batch.v1alpha.AllocationPolicy.AttachedDisk disks = 6;

Parameters
Name Description
index int
builderForValue AllocationPolicy.AttachedDisk.Builder
Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setMachineType(String value)

public AllocationPolicy.InstancePolicy.Builder setMachineType(String value)

The Compute Engine machine type.

string machine_type = 2;

Parameter
Name Description
value String

The machineType to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setMachineTypeBytes(ByteString value)

public AllocationPolicy.InstancePolicy.Builder setMachineTypeBytes(ByteString value)

The Compute Engine machine type.

string machine_type = 2;

Parameter
Name Description
value ByteString

The bytes for machineType to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setMinCpuPlatform(String value)

public AllocationPolicy.InstancePolicy.Builder setMinCpuPlatform(String value)

The minimum CPU platform. See https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform. Not yet implemented.

string min_cpu_platform = 3;

Parameter
Name Description
value String

The minCpuPlatform to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setMinCpuPlatformBytes(ByteString value)

public AllocationPolicy.InstancePolicy.Builder setMinCpuPlatformBytes(ByteString value)

The minimum CPU platform. See https://cloud.google.com/compute/docs/instances/specify-min-cpu-platform. Not yet implemented.

string min_cpu_platform = 3;

Parameter
Name Description
value ByteString

The bytes for minCpuPlatform to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setProvisioningModel(AllocationPolicy.ProvisioningModel value)

public AllocationPolicy.InstancePolicy.Builder setProvisioningModel(AllocationPolicy.ProvisioningModel value)

The provisioning model.

.google.cloud.batch.v1alpha.AllocationPolicy.ProvisioningModel provisioning_model = 4;

Parameter
Name Description
value AllocationPolicy.ProvisioningModel

The provisioningModel to set.

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

setProvisioningModelValue(int value)

public AllocationPolicy.InstancePolicy.Builder setProvisioningModelValue(int value)

The provisioning model.

.google.cloud.batch.v1alpha.AllocationPolicy.ProvisioningModel provisioning_model = 4;

Parameter
Name Description
value int

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

Returns
Type Description
AllocationPolicy.InstancePolicy.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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