Class MachineSpec.Builder (0.1.0)

publicstaticfinalclass MachineSpec.BuilderextendsGeneratedMessageV3.Builder<MachineSpec.Builder>implementsMachineSpecOrBuilder

Specification of a single machine.

Protobuf type google.cloud.vertexai.v1beta1.MachineSpec

Inherited Members

com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)

Static Methods

getDescriptor()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

publicMachineSpec.BuilderaddRepeatedField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
MachineSpec.Builder
Overrides

build()

publicMachineSpecbuild()
Returns
Type Description
MachineSpec

buildPartial()

publicMachineSpecbuildPartial()
Returns
Type Description
MachineSpec

clear()

publicMachineSpec.Builderclear()
Returns
Type Description
MachineSpec.Builder
Overrides

clearAcceleratorCount()

publicMachineSpec.BuilderclearAcceleratorCount()

The number of accelerators to attach to the machine.

int32 accelerator_count = 3;

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

clearAcceleratorType()

publicMachineSpec.BuilderclearAcceleratorType()

Immutable. The type of accelerator(s) that may be attached to the machine as per accelerator_count.

.google.cloud.vertexai.v1beta1.AcceleratorType accelerator_type = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

publicMachineSpec.BuilderclearField(Descriptors.FieldDescriptorfield)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
MachineSpec.Builder
Overrides

clearMachineType()

publicMachineSpec.BuilderclearMachineType()

Immutable. The type of the machine.

See the list of machine types supported for prediction

See the list of machine types supported for custom training.

For DeployedModel this field is optional, and the default value is n1-standard-2. For BatchPredictionJob or as part of WorkerPoolSpec this field is required.

string machine_type = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

publicMachineSpec.BuilderclearOneof(Descriptors.OneofDescriptoroneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
MachineSpec.Builder
Overrides

clearTpuTopology()

publicMachineSpec.BuilderclearTpuTopology()

Immutable. The topology of the TPUs. Corresponds to the TPU topologies available from GKE. (Example: tpu_topology: "2x2x1").

string tpu_topology = 4 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

clone()

publicMachineSpec.Builderclone()
Returns
Type Description
MachineSpec.Builder
Overrides

getAcceleratorCount()

publicintgetAcceleratorCount()

The number of accelerators to attach to the machine.

int32 accelerator_count = 3;

Returns
Type Description
int

The acceleratorCount.

getAcceleratorType()

publicAcceleratorTypegetAcceleratorType()

Immutable. The type of accelerator(s) that may be attached to the machine as per accelerator_count.

.google.cloud.vertexai.v1beta1.AcceleratorType accelerator_type = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
AcceleratorType

The acceleratorType.

getAcceleratorTypeValue()

publicintgetAcceleratorTypeValue()

Immutable. The type of accelerator(s) that may be attached to the machine as per accelerator_count.

.google.cloud.vertexai.v1beta1.AcceleratorType accelerator_type = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
int

The enum numeric value on the wire for acceleratorType.

getDefaultInstanceForType()

publicMachineSpecgetDefaultInstanceForType()
Returns
Type Description
MachineSpec

getDescriptorForType()

publicDescriptors.DescriptorgetDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMachineType()

publicStringgetMachineType()

Immutable. The type of the machine.

See the list of machine types supported for prediction

See the list of machine types supported for custom training.

For DeployedModel this field is optional, and the default value is n1-standard-2. For BatchPredictionJob or as part of WorkerPoolSpec this field is required.

string machine_type = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
String

The machineType.

getMachineTypeBytes()

publicByteStringgetMachineTypeBytes()

Immutable. The type of the machine.

See the list of machine types supported for prediction

See the list of machine types supported for custom training.

For DeployedModel this field is optional, and the default value is n1-standard-2. For BatchPredictionJob or as part of WorkerPoolSpec this field is required.

string machine_type = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
ByteString

The bytes for machineType.

getTpuTopology()

publicStringgetTpuTopology()

Immutable. The topology of the TPUs. Corresponds to the TPU topologies available from GKE. (Example: tpu_topology: "2x2x1").

string tpu_topology = 4 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
String

The tpuTopology.

getTpuTopologyBytes()

publicByteStringgetTpuTopologyBytes()

Immutable. The topology of the TPUs. Corresponds to the TPU topologies available from GKE. (Example: tpu_topology: "2x2x1").

string tpu_topology = 4 [(.google.api.field_behavior) = IMMUTABLE];

Returns
Type Description
ByteString

The bytes for tpuTopology.

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(MachineSpec other)

publicMachineSpec.BuildermergeFrom(MachineSpecother)
Parameter
Name Description
other MachineSpec
Returns
Type Description
MachineSpec.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicMachineSpec.BuildermergeFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MachineSpec.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

publicMachineSpec.BuildermergeFrom(Messageother)
Parameter
Name Description
other Message
Returns
Type Description
MachineSpec.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

publicfinalMachineSpec.BuildermergeUnknownFields(UnknownFieldSetunknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
MachineSpec.Builder
Overrides

setAcceleratorCount(int value)

publicMachineSpec.BuildersetAcceleratorCount(intvalue)

The number of accelerators to attach to the machine.

int32 accelerator_count = 3;

Parameter
Name Description
value int

The acceleratorCount to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setAcceleratorType(AcceleratorType value)

publicMachineSpec.BuildersetAcceleratorType(AcceleratorTypevalue)

Immutable. The type of accelerator(s) that may be attached to the machine as per accelerator_count.

.google.cloud.vertexai.v1beta1.AcceleratorType accelerator_type = 2 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value AcceleratorType

The acceleratorType to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setAcceleratorTypeValue(int value)

publicMachineSpec.BuildersetAcceleratorTypeValue(intvalue)

Immutable. The type of accelerator(s) that may be attached to the machine as per accelerator_count.

.google.cloud.vertexai.v1beta1.AcceleratorType accelerator_type = 2 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value int

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

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

publicMachineSpec.BuildersetField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
MachineSpec.Builder
Overrides

setMachineType(String value)

publicMachineSpec.BuildersetMachineType(Stringvalue)

Immutable. The type of the machine.

See the list of machine types supported for prediction

See the list of machine types supported for custom training.

For DeployedModel this field is optional, and the default value is n1-standard-2. For BatchPredictionJob or as part of WorkerPoolSpec this field is required.

string machine_type = 1 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value String

The machineType to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setMachineTypeBytes(ByteString value)

publicMachineSpec.BuildersetMachineTypeBytes(ByteStringvalue)

Immutable. The type of the machine.

See the list of machine types supported for prediction

See the list of machine types supported for custom training.

For DeployedModel this field is optional, and the default value is n1-standard-2. For BatchPredictionJob or as part of WorkerPoolSpec this field is required.

string machine_type = 1 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value ByteString

The bytes for machineType to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

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

publicMachineSpec.BuildersetRepeatedField(Descriptors.FieldDescriptorfield,intindex,Objectvalue)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
MachineSpec.Builder
Overrides

setTpuTopology(String value)

publicMachineSpec.BuildersetTpuTopology(Stringvalue)

Immutable. The topology of the TPUs. Corresponds to the TPU topologies available from GKE. (Example: tpu_topology: "2x2x1").

string tpu_topology = 4 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value String

The tpuTopology to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setTpuTopologyBytes(ByteString value)

publicMachineSpec.BuildersetTpuTopologyBytes(ByteStringvalue)

Immutable. The topology of the TPUs. Corresponds to the TPU topologies available from GKE. (Example: tpu_topology: "2x2x1").

string tpu_topology = 4 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
Name Description
value ByteString

The bytes for tpuTopology to set.

Returns
Type Description
MachineSpec.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

publicfinalMachineSpec.BuildersetUnknownFields(UnknownFieldSetunknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
MachineSpec.Builder
Overrides

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年11月19日 UTC.