Class UsageResourceAllowanceSpec.Limit (0.41.0)

public static final class UsageResourceAllowanceSpec.Limit extends GeneratedMessageV3 implements UsageResourceAllowanceSpec.LimitOrBuilder

UsageResourceAllowance limitation.

Protobuf type google.cloud.batch.v1alpha.UsageResourceAllowanceSpec.Limit

Inheritance

Object > AbstractMessageLite<MessageType,BuilderType> > AbstractMessage > GeneratedMessageV3 > UsageResourceAllowanceSpec.Limit

Static Fields

CALENDAR_PERIOD_FIELD_NUMBER

public static final int CALENDAR_PERIOD_FIELD_NUMBER
Field Value
TypeDescription
int

LIMIT_FIELD_NUMBER

public static final int LIMIT_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static UsageResourceAllowanceSpec.Limit getDefaultInstance()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static UsageResourceAllowanceSpec.Limit.Builder newBuilder()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.Builder

newBuilder(UsageResourceAllowanceSpec.Limit prototype)

public static UsageResourceAllowanceSpec.Limit.Builder newBuilder(UsageResourceAllowanceSpec.Limit prototype)
Parameter
NameDescription
prototypeUsageResourceAllowanceSpec.Limit
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.Builder

parseDelimitedFrom(InputStream input)

public static UsageResourceAllowanceSpec.Limit parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static UsageResourceAllowanceSpec.Limit parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static UsageResourceAllowanceSpec.Limit parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static UsageResourceAllowanceSpec.Limit parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static UsageResourceAllowanceSpec.Limit parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static UsageResourceAllowanceSpec.Limit parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static UsageResourceAllowanceSpec.Limit parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<UsageResourceAllowanceSpec.Limit> parser()
Returns
TypeDescription
Parser<Limit>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getCalendarPeriod()

public CalendarPeriod getCalendarPeriod()

Optional. A CalendarPeriod represents the abstract concept of a time period that has a canonical start.

.google.cloud.batch.v1alpha.CalendarPeriod calendar_period = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
CalendarPeriod

The calendarPeriod.

getCalendarPeriodValue()

public int getCalendarPeriodValue()

Optional. A CalendarPeriod represents the abstract concept of a time period that has a canonical start.

.google.cloud.batch.v1alpha.CalendarPeriod calendar_period = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The enum numeric value on the wire for calendarPeriod.

getDefaultInstanceForType()

public UsageResourceAllowanceSpec.Limit getDefaultInstanceForType()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit

getDurationCase()

public UsageResourceAllowanceSpec.Limit.DurationCase getDurationCase()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.DurationCase

getLimit()

public double getLimit()

Required. Limit value of a UsageResourceAllowance within its one duration. Default is 0. For example, you can set limit as 10000.0 with duration of the current month by setting calendar_period field as monthly. That means in your current month, 10000.0 is the cour hour limitation that your resources are allowed to consume.

optional double limit = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
double

The limit.

getParserForType()

public Parser<UsageResourceAllowanceSpec.Limit> getParserForType()
Returns
TypeDescription
Parser<Limit>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

hasCalendarPeriod()

public boolean hasCalendarPeriod()

Optional. A CalendarPeriod represents the abstract concept of a time period that has a canonical start.

.google.cloud.batch.v1alpha.CalendarPeriod calendar_period = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the calendarPeriod field is set.

hasLimit()

public boolean hasLimit()

Required. Limit value of a UsageResourceAllowance within its one duration. Default is 0. For example, you can set limit as 10000.0 with duration of the current month by setting calendar_period field as monthly. That means in your current month, 10000.0 is the cour hour limitation that your resources are allowed to consume.

optional double limit = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the limit field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public UsageResourceAllowanceSpec.Limit.Builder newBuilderForType()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected UsageResourceAllowanceSpec.Limit.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public UsageResourceAllowanceSpec.Limit.Builder toBuilder()
Returns
TypeDescription
UsageResourceAllowanceSpec.Limit.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException