public static final class AllocationPolicy.Accelerator.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder> implements AllocationPolicy.AcceleratorOrBuilder
Accelerator describes Compute Engine accelerators to be attached to the VM.Protobuf type
google.cloud.batch.v1.AllocationPolicy.Accelerator| Modifier and Type | Method and Description |
|---|---|
AllocationPolicy.Accelerator.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
AllocationPolicy.Accelerator |
build() |
AllocationPolicy.Accelerator |
buildPartial() |
AllocationPolicy.Accelerator.Builder |
clear() |
AllocationPolicy.Accelerator.Builder |
clearCount()
The number of accelerators of this type.
|
AllocationPolicy.Accelerator.Builder |
clearDriverVersion()
Optional.
|
AllocationPolicy.Accelerator.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
AllocationPolicy.Accelerator.Builder |
clearInstallGpuDrivers()
Deprecated.
google.cloud.batch.v1.AllocationPolicy.Accelerator.install_gpu_drivers is
deprecated. See google/cloud/batch/v1/job.proto;l=386
|
AllocationPolicy.Accelerator.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
AllocationPolicy.Accelerator.Builder |
clearType()
The accelerator type.
|
AllocationPolicy.Accelerator.Builder |
clone() |
long |
getCount()
The number of accelerators of this type.
|
AllocationPolicy.Accelerator |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getDriverVersion()
Optional.
|
com.google.protobuf.ByteString |
getDriverVersionBytes()
Optional.
|
boolean |
getInstallGpuDrivers()
Deprecated.
google.cloud.batch.v1.AllocationPolicy.Accelerator.install_gpu_drivers is
deprecated. See google/cloud/batch/v1/job.proto;l=386
|
String |
getType()
The accelerator type.
|
com.google.protobuf.ByteString |
getTypeBytes()
The accelerator type.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
AllocationPolicy.Accelerator.Builder |
mergeFrom(AllocationPolicy.Accelerator other) |
AllocationPolicy.Accelerator.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
AllocationPolicy.Accelerator.Builder |
mergeFrom(com.google.protobuf.Message other) |
AllocationPolicy.Accelerator.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
AllocationPolicy.Accelerator.Builder |
setCount(long value)
The number of accelerators of this type.
|
AllocationPolicy.Accelerator.Builder |
setDriverVersion(String value)
Optional.
|
AllocationPolicy.Accelerator.Builder |
setDriverVersionBytes(com.google.protobuf.ByteString value)
Optional.
|
AllocationPolicy.Accelerator.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
AllocationPolicy.Accelerator.Builder |
setInstallGpuDrivers(boolean value)
Deprecated.
google.cloud.batch.v1.AllocationPolicy.Accelerator.install_gpu_drivers is
deprecated. See google/cloud/batch/v1/job.proto;l=386
|
AllocationPolicy.Accelerator.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
AllocationPolicy.Accelerator.Builder |
setType(String value)
The accelerator type.
|
AllocationPolicy.Accelerator.Builder |
setTypeBytes(com.google.protobuf.ByteString value)
The accelerator type.
|
AllocationPolicy.Accelerator.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic AllocationPolicy.Accelerator build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic AllocationPolicy.Accelerator buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic AllocationPolicy.Accelerator.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder mergeFrom(AllocationPolicy.Accelerator other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public AllocationPolicy.Accelerator.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<AllocationPolicy.Accelerator.Builder>IOExceptionpublic String getType()
The accelerator type. For example, "nvidia-tesla-t4". See `gcloud compute accelerator-types list`.
string type = 1;getType in interface AllocationPolicy.AcceleratorOrBuilderpublic com.google.protobuf.ByteString getTypeBytes()
The accelerator type. For example, "nvidia-tesla-t4". See `gcloud compute accelerator-types list`.
string type = 1;getTypeBytes in interface AllocationPolicy.AcceleratorOrBuilderpublic AllocationPolicy.Accelerator.Builder setType(String value)
The accelerator type. For example, "nvidia-tesla-t4". See `gcloud compute accelerator-types list`.
string type = 1;value - The type to set.public AllocationPolicy.Accelerator.Builder clearType()
The accelerator type. For example, "nvidia-tesla-t4". See `gcloud compute accelerator-types list`.
string type = 1;public AllocationPolicy.Accelerator.Builder setTypeBytes(com.google.protobuf.ByteString value)
The accelerator type. For example, "nvidia-tesla-t4". See `gcloud compute accelerator-types list`.
string type = 1;value - The bytes for type to set.public long getCount()
The number of accelerators of this type.
int64 count = 2;getCount in interface AllocationPolicy.AcceleratorOrBuilderpublic AllocationPolicy.Accelerator.Builder setCount(long value)
The number of accelerators of this type.
int64 count = 2;value - The count to set.public AllocationPolicy.Accelerator.Builder clearCount()
The number of accelerators of this type.
int64 count = 2;@Deprecated public boolean getInstallGpuDrivers()
Deprecated: please use instances[0].install_gpu_drivers instead.
bool install_gpu_drivers = 3 [deprecated = true];getInstallGpuDrivers in interface AllocationPolicy.AcceleratorOrBuilder@Deprecated public AllocationPolicy.Accelerator.Builder setInstallGpuDrivers(boolean value)
Deprecated: please use instances[0].install_gpu_drivers instead.
bool install_gpu_drivers = 3 [deprecated = true];value - The installGpuDrivers to set.@Deprecated public AllocationPolicy.Accelerator.Builder clearInstallGpuDrivers()
Deprecated: please use instances[0].install_gpu_drivers instead.
bool install_gpu_drivers = 3 [deprecated = true];public String getDriverVersion()
Optional. The NVIDIA GPU driver version that should be installed for this type. You can define the specific driver version such as "470.103.01", following the driver version requirements in https://cloud.google.com/compute/docs/gpus/install-drivers-gpu#minimum-driver. Batch will install the specific accelerator driver if qualified.
string driver_version = 4 [(.google.api.field_behavior) = OPTIONAL];getDriverVersion in interface AllocationPolicy.AcceleratorOrBuilderpublic com.google.protobuf.ByteString getDriverVersionBytes()
Optional. The NVIDIA GPU driver version that should be installed for this type. You can define the specific driver version such as "470.103.01", following the driver version requirements in https://cloud.google.com/compute/docs/gpus/install-drivers-gpu#minimum-driver. Batch will install the specific accelerator driver if qualified.
string driver_version = 4 [(.google.api.field_behavior) = OPTIONAL];getDriverVersionBytes in interface AllocationPolicy.AcceleratorOrBuilderpublic AllocationPolicy.Accelerator.Builder setDriverVersion(String value)
Optional. The NVIDIA GPU driver version that should be installed for this type. You can define the specific driver version such as "470.103.01", following the driver version requirements in https://cloud.google.com/compute/docs/gpus/install-drivers-gpu#minimum-driver. Batch will install the specific accelerator driver if qualified.
string driver_version = 4 [(.google.api.field_behavior) = OPTIONAL];value - The driverVersion to set.public AllocationPolicy.Accelerator.Builder clearDriverVersion()
Optional. The NVIDIA GPU driver version that should be installed for this type. You can define the specific driver version such as "470.103.01", following the driver version requirements in https://cloud.google.com/compute/docs/gpus/install-drivers-gpu#minimum-driver. Batch will install the specific accelerator driver if qualified.
string driver_version = 4 [(.google.api.field_behavior) = OPTIONAL];public AllocationPolicy.Accelerator.Builder setDriverVersionBytes(com.google.protobuf.ByteString value)
Optional. The NVIDIA GPU driver version that should be installed for this type. You can define the specific driver version such as "470.103.01", following the driver version requirements in https://cloud.google.com/compute/docs/gpus/install-drivers-gpu#minimum-driver. Batch will install the specific accelerator driver if qualified.
string driver_version = 4 [(.google.api.field_behavior) = OPTIONAL];value - The bytes for driverVersion to set.public final AllocationPolicy.Accelerator.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>public final AllocationPolicy.Accelerator.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AllocationPolicy.Accelerator.Builder>Copyright © 2025 Google LLC. All rights reserved.