public static enum QuotaOperation.QuotaMode extends java.lang.Enum<QuotaOperation.QuotaMode> implements com.google.protobuf.ProtocolMessageEnum
Supported quota modes. This can be specified only when the operation is associated with a AllocateQuota and ReleaseQuota request.Protobuf enum
google.api.servicecontrol.v1.QuotaOperation.QuotaMode| Enum Constant and Description |
|---|
BEST_EFFORT
For AllocateQuota request, this mode is supported only for imprecise
quota limits.
|
CHECK_ONLY
For AllocateQuota request, only checks if there is enough quota
available and does not change the available quota.
|
NORMAL
For AllocateQuota request, allocates quota for the amount specified in
the service configuration or specified using the quota metrics.
|
UNRECOGNIZED |
UNSPECIFIED
UNSPECIFIED = 0; |
| Modifier and Type | Field and Description |
|---|---|
static int |
BEST_EFFORT_VALUE
For AllocateQuota request, this mode is supported only for imprecise
quota limits.
|
static int |
CHECK_ONLY_VALUE
For AllocateQuota request, only checks if there is enough quota
available and does not change the available quota.
|
static int |
NORMAL_VALUE
For AllocateQuota request, allocates quota for the amount specified in
the service configuration or specified using the quota metrics.
|
static int |
UNSPECIFIED_VALUE
UNSPECIFIED = 0; |
| Modifier and Type | Method and Description |
|---|---|
static QuotaOperation.QuotaMode |
forNumber(int value) |
static com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptor() |
com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptorForType() |
int |
getNumber() |
com.google.protobuf.Descriptors.EnumValueDescriptor |
getValueDescriptor() |
static com.google.protobuf.Internal.EnumLiteMap<QuotaOperation.QuotaMode> |
internalGetValueMap() |
static QuotaOperation.QuotaMode |
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) |
static QuotaOperation.QuotaMode |
valueOf(int value)
Deprecated.
Use
forNumber(int) instead. |
static QuotaOperation.QuotaMode |
valueOf(java.lang.String name)
Returns 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.
|
public static final QuotaOperation.QuotaMode UNSPECIFIED
UNSPECIFIED = 0;public static final QuotaOperation.QuotaMode 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. For ReleaseQuota request, this mode is supported only for precise quota limits. In this case, this operation releases quota for the amount specified in the service configuration or specified using the quota metrics. If the release can make available quota negative, release error will be returned and no quota will be released.
NORMAL = 1;public static final QuotaOperation.QuotaMode BEST_EFFORT
For AllocateQuota request, this mode is supported only for imprecise quota limits. In this case, 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 ReleaseQuota request, this mode is supported for both precise quota limits and imprecise quota limits. In this case, this operation releases quota for the amount specified in the service configuration or specified using the quota metrics. If the release can make available quota negative, request does not fail but only the available quota will be released. After the ReleaseQuota request completes, the available quota will be 0, and never goes to negative.
BEST_EFFORT = 2;public static final QuotaOperation.QuotaMode 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. Not supported for ReleaseQuota request.
CHECK_ONLY = 3;public static final QuotaOperation.QuotaMode UNRECOGNIZED
public static final int UNSPECIFIED_VALUE
UNSPECIFIED = 0;public static final int NORMAL_VALUE
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. For ReleaseQuota request, this mode is supported only for precise quota limits. In this case, this operation releases quota for the amount specified in the service configuration or specified using the quota metrics. If the release can make available quota negative, release error will be returned and no quota will be released.
NORMAL = 1;public static final int BEST_EFFORT_VALUE
For AllocateQuota request, this mode is supported only for imprecise quota limits. In this case, 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 ReleaseQuota request, this mode is supported for both precise quota limits and imprecise quota limits. In this case, this operation releases quota for the amount specified in the service configuration or specified using the quota metrics. If the release can make available quota negative, request does not fail but only the available quota will be released. After the ReleaseQuota request completes, the available quota will be 0, and never goes to negative.
BEST_EFFORT = 2;public static final int CHECK_ONLY_VALUE
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. Not supported for ReleaseQuota request.
CHECK_ONLY = 3;public static QuotaOperation.QuotaMode[] values()
for (QuotaOperation.QuotaMode c : QuotaOperation.QuotaMode.values()) System.out.println(c);
public static QuotaOperation.QuotaMode valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic final int getNumber()
getNumber in interface com.google.protobuf.Internal.EnumLitegetNumber in interface com.google.protobuf.ProtocolMessageEnum@Deprecated public static QuotaOperation.QuotaMode valueOf(int value)
forNumber(int) instead.public static QuotaOperation.QuotaMode forNumber(int value)
public static com.google.protobuf.Internal.EnumLiteMap<QuotaOperation.QuotaMode> internalGetValueMap()
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
getValueDescriptor in interface com.google.protobuf.ProtocolMessageEnumpublic final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.ProtocolMessageEnumpublic static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
public static QuotaOperation.QuotaMode valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)