Class UsageSnapshot.Builder (4.80.0)

public static final class UsageSnapshot.Builder extends GeneratedMessage.Builder<UsageSnapshot.Builder> implements UsageSnapshotOrBuilder

The usage snapshot represents the resources consumed by a workload at a specified time.

Protobuf type google.cloud.dataproc.v1.UsageSnapshot

Static Methods

getDescriptor()

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

Methods

build()

public UsageSnapshot build()
Returns
Type Description
UsageSnapshot

buildPartial()

public UsageSnapshot buildPartial()
Returns
Type Description
UsageSnapshot

clear()

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

clearAcceleratorType()

public UsageSnapshot.Builder clearAcceleratorType()

Optional. Accelerator type being used, if any

string accelerator_type = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearMilliAccelerator()

public UsageSnapshot.Builder clearMilliAccelerator()

Optional. Milli (one-thousandth) accelerator. (see Dataproc Serverless pricing)

int64 milli_accelerator = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearMilliDcu()

public UsageSnapshot.Builder clearMilliDcu()

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) (see Dataproc Serverless pricing).

int64 milli_dcu = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearMilliDcuPremium()

public UsageSnapshot.Builder clearMilliDcuPremium()

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) charged at premium tier (see Dataproc Serverless pricing).

int64 milli_dcu_premium = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearShuffleStorageGb()

public UsageSnapshot.Builder clearShuffleStorageGb()

Optional. Shuffle Storage in gigabytes (GB). (see Dataproc Serverless pricing)

int64 shuffle_storage_gb = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearShuffleStorageGbPremium()

public UsageSnapshot.Builder clearShuffleStorageGbPremium()

Optional. Shuffle Storage in gigabytes (GB) charged at premium tier. (see Dataproc Serverless pricing)

int64 shuffle_storage_gb_premium = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

clearSnapshotTime()

public UsageSnapshot.Builder clearSnapshotTime()

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
UsageSnapshot.Builder

getAcceleratorType()

public String getAcceleratorType()

Optional. Accelerator type being used, if any

string accelerator_type = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The acceleratorType.

getAcceleratorTypeBytes()

public ByteString getAcceleratorTypeBytes()

Optional. Accelerator type being used, if any

string accelerator_type = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for acceleratorType.

getDefaultInstanceForType()

public UsageSnapshot getDefaultInstanceForType()
Returns
Type Description
UsageSnapshot

getDescriptorForType()

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

getMilliAccelerator()

public long getMilliAccelerator()

Optional. Milli (one-thousandth) accelerator. (see Dataproc Serverless pricing)

int64 milli_accelerator = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The milliAccelerator.

getMilliDcu()

public long getMilliDcu()

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) (see Dataproc Serverless pricing).

int64 milli_dcu = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The milliDcu.

getMilliDcuPremium()

public long getMilliDcuPremium()

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) charged at premium tier (see Dataproc Serverless pricing).

int64 milli_dcu_premium = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The milliDcuPremium.

getShuffleStorageGb()

public long getShuffleStorageGb()

Optional. Shuffle Storage in gigabytes (GB). (see Dataproc Serverless pricing)

int64 shuffle_storage_gb = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The shuffleStorageGb.

getShuffleStorageGbPremium()

public long getShuffleStorageGbPremium()

Optional. Shuffle Storage in gigabytes (GB) charged at premium tier. (see Dataproc Serverless pricing)

int64 shuffle_storage_gb_premium = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
long

The shuffleStorageGbPremium.

getSnapshotTime()

public Timestamp getSnapshotTime()

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Timestamp

The snapshotTime.

getSnapshotTimeBuilder()

public Timestamp.Builder getSnapshotTimeBuilder()

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getSnapshotTimeOrBuilder()

public TimestampOrBuilder getSnapshotTimeOrBuilder()

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
TimestampOrBuilder

hasSnapshotTime()

public boolean hasSnapshotTime()

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the snapshotTime field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(UsageSnapshot other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeSnapshotTime(Timestamp value)

public UsageSnapshot.Builder mergeSnapshotTime(Timestamp value)

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Timestamp
Returns
Type Description
UsageSnapshot.Builder

setAcceleratorType(String value)

public UsageSnapshot.Builder setAcceleratorType(String value)

Optional. Accelerator type being used, if any

string accelerator_type = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The acceleratorType to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setAcceleratorTypeBytes(ByteString value)

public UsageSnapshot.Builder setAcceleratorTypeBytes(ByteString value)

Optional. Accelerator type being used, if any

string accelerator_type = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for acceleratorType to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setMilliAccelerator(long value)

public UsageSnapshot.Builder setMilliAccelerator(long value)

Optional. Milli (one-thousandth) accelerator. (see Dataproc Serverless pricing)

int64 milli_accelerator = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value long

The milliAccelerator to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setMilliDcu(long value)

public UsageSnapshot.Builder setMilliDcu(long value)

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) (see Dataproc Serverless pricing).

int64 milli_dcu = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value long

The milliDcu to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setMilliDcuPremium(long value)

public UsageSnapshot.Builder setMilliDcuPremium(long value)

Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) charged at premium tier (see Dataproc Serverless pricing).

int64 milli_dcu_premium = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value long

The milliDcuPremium to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setShuffleStorageGb(long value)

public UsageSnapshot.Builder setShuffleStorageGb(long value)

Optional. Shuffle Storage in gigabytes (GB). (see Dataproc Serverless pricing)

int64 shuffle_storage_gb = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value long

The shuffleStorageGb to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setShuffleStorageGbPremium(long value)

public UsageSnapshot.Builder setShuffleStorageGbPremium(long value)

Optional. Shuffle Storage in gigabytes (GB) charged at premium tier. (see Dataproc Serverless pricing)

int64 shuffle_storage_gb_premium = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value long

The shuffleStorageGbPremium to set.

Returns
Type Description
UsageSnapshot.Builder

This builder for chaining.

setSnapshotTime(Timestamp value)

public UsageSnapshot.Builder setSnapshotTime(Timestamp value)

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Timestamp
Returns
Type Description
UsageSnapshot.Builder

setSnapshotTime(Timestamp.Builder builderForValue)

public UsageSnapshot.Builder setSnapshotTime(Timestamp.Builder builderForValue)

Optional. The timestamp of the usage snapshot.

.google.protobuf.Timestamp snapshot_time = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
UsageSnapshot.Builder