Class TaskResourceUsage.Builder (0.23.0)

public static final class TaskResourceUsage.Builder extends GeneratedMessageV3.Builder<TaskResourceUsage.Builder> implements TaskResourceUsageOrBuilder

TaskResourceUsage describes the resource usage of the task.

Protobuf type google.cloud.batch.v1alpha.TaskResourceUsage

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public TaskResourceUsage build()
Returns
Type Description
TaskResourceUsage

buildPartial()

public TaskResourceUsage buildPartial()
Returns
Type Description
TaskResourceUsage

clear()

public TaskResourceUsage.Builder clear()
Returns
Type Description
TaskResourceUsage.Builder
Overrides

clearCoreHours()

public TaskResourceUsage.Builder clearCoreHours()

The CPU core hours the task consumes based on task requirement and run time.

double core_hours = 1;

Returns
Type Description
TaskResourceUsage.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

public TaskResourceUsage.Builder clone()
Returns
Type Description
TaskResourceUsage.Builder
Overrides

getCoreHours()

public double getCoreHours()

The CPU core hours the task consumes based on task requirement and run time.

double core_hours = 1;

Returns
Type Description
double

The coreHours.

getDefaultInstanceForType()

public TaskResourceUsage getDefaultInstanceForType()
Returns
Type Description
TaskResourceUsage

getDescriptorForType()

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

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(TaskResourceUsage other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setCoreHours(double value)

public TaskResourceUsage.Builder setCoreHours(double value)

The CPU core hours the task consumes based on task requirement and run time.

double core_hours = 1;

Parameter
Name Description
value double

The coreHours to set.

Returns
Type Description
TaskResourceUsage.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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