Package com.google.api.servicecontrol.v1
Enum QuotaOperation.QuotaMode
- All Implemented Interfaces:
com.google.protobuf.Internal.EnumLite,com.google.protobuf.ProtocolMessageEnum,Serializable,Comparable<QuotaOperation.QuotaMode>
- Enclosing class:
- QuotaOperation
public static enum QuotaOperation.QuotaMode
extends Enum<QuotaOperation.QuotaMode>
implements com.google.protobuf.ProtocolMessageEnum
Supported quota modes.Protobuf enum
google.api.servicecontrol.v1.QuotaOperation.QuotaMode-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe operation allocates quota for the amount specified in the service configuration or specified using the quota metrics.The operation allocates quota for the amount specified in the service configuration or specified using the quota metrics.For AllocateQuota request, only checks if there is enough quota available and does not change the available quota.For AllocateQuota request, allocates quota for the amount specified in the service configuration or specified using the quota metrics.Unimplemented.Guard against implicit default. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe operation allocates quota for the amount specified in the service configuration or specified using the quota metrics.static final intThe operation allocates quota for the amount specified in the service configuration or specified using the quota metrics.static final intFor AllocateQuota request, only checks if there is enough quota available and does not change the available quota.static final intFor AllocateQuota request, allocates quota for the amount specified in the service configuration or specified using the quota metrics.static final intUnimplemented.static final intGuard against implicit default. -
Method Summary
Modifier and TypeMethodDescriptionstatic QuotaOperation.QuotaModeforNumber(int value) static com.google.protobuf.Descriptors.EnumDescriptorfinal com.google.protobuf.Descriptors.EnumDescriptorfinal intfinal com.google.protobuf.Descriptors.EnumValueDescriptorstatic com.google.protobuf.Internal.EnumLiteMap<QuotaOperation.QuotaMode>static QuotaOperation.QuotaModevalueOf(int value) Deprecated.static QuotaOperation.QuotaModevalueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) Returns the enum constant of this type with the specified name.static QuotaOperation.QuotaModeReturns the enum constant of this type with the specified name.static QuotaOperation.QuotaMode[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
UNSPECIFIED
Guard against implicit default. Must not be used.
UNSPECIFIED = 0; -
NORMAL
For AllocateQuota request, allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the amount is higher than the available quota, allocation error will be returned and no quota will be allocated. If multiple quotas are part of the request, and one fails, none of the quotas are allocated or released.
NORMAL = 1; -
BEST_EFFORT
The operation allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the amount is higher than the available quota, request does not fail but all available quota will be allocated. For rate quota, BEST_EFFORT will continue to deduct from other groups even if one does not have enough quota. For allocation, it will find the minimum available amount across all groups and deduct that amount from all the affected groups.
BEST_EFFORT = 2; -
CHECK_ONLY
For AllocateQuota request, only checks if there is enough quota available and does not change the available quota. No lock is placed on the available quota either.
CHECK_ONLY = 3; -
QUERY_ONLY
Unimplemented. When used in AllocateQuotaRequest, this returns the effective quota limit(s) in the response, and no quota check will be performed. Not supported for other requests, and even for AllocateQuotaRequest, this is currently supported only for allowlisted services.
QUERY_ONLY = 4; -
ADJUST_ONLY
The operation allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the requested amount is higher than the available quota, request does not fail and remaining quota would become negative (going over the limit). Not supported for Rate Quota.
ADJUST_ONLY = 5; -
UNRECOGNIZED
-
-
Field Details
-
UNSPECIFIED_VALUE
public static final int UNSPECIFIED_VALUEGuard against implicit default. Must not be used.
UNSPECIFIED = 0;- See Also:
-
NORMAL_VALUE
public static final int NORMAL_VALUEFor AllocateQuota request, allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the amount is higher than the available quota, allocation error will be returned and no quota will be allocated. If multiple quotas are part of the request, and one fails, none of the quotas are allocated or released.
NORMAL = 1;- See Also:
-
BEST_EFFORT_VALUE
public static final int BEST_EFFORT_VALUEThe operation allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the amount is higher than the available quota, request does not fail but all available quota will be allocated. For rate quota, BEST_EFFORT will continue to deduct from other groups even if one does not have enough quota. For allocation, it will find the minimum available amount across all groups and deduct that amount from all the affected groups.
BEST_EFFORT = 2;- See Also:
-
CHECK_ONLY_VALUE
public static final int CHECK_ONLY_VALUEFor AllocateQuota request, only checks if there is enough quota available and does not change the available quota. No lock is placed on the available quota either.
CHECK_ONLY = 3;- See Also:
-
QUERY_ONLY_VALUE
public static final int QUERY_ONLY_VALUEUnimplemented. When used in AllocateQuotaRequest, this returns the effective quota limit(s) in the response, and no quota check will be performed. Not supported for other requests, and even for AllocateQuotaRequest, this is currently supported only for allowlisted services.
QUERY_ONLY = 4;- See Also:
-
ADJUST_ONLY_VALUE
public static final int ADJUST_ONLY_VALUEThe operation allocates quota for the amount specified in the service configuration or specified using the quota metrics. If the requested amount is higher than the available quota, request does not fail and remaining quota would become negative (going over the limit). Not supported for Rate Quota.
ADJUST_ONLY = 5;- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getNumber
public final int getNumber()- Specified by:
getNumberin interfacecom.google.protobuf.Internal.EnumLite- Specified by:
getNumberin interfacecom.google.protobuf.ProtocolMessageEnum
-
valueOf
Deprecated.Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
value- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
forNumber
- Parameters:
value- The numeric wire value of the corresponding enum entry.- Returns:
- The enum associated with the given numeric wire value.
-
internalGetValueMap
public static com.google.protobuf.Internal.EnumLiteMap<QuotaOperation.QuotaMode> internalGetValueMap() -
getValueDescriptor
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()- Specified by:
getValueDescriptorin interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptorForType
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptor
public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() -
valueOf
public static QuotaOperation.QuotaMode valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
desc- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-