public enum DiscountCodeState extends Enum<DiscountCodeState> implements SphereEnumeration
SphereEnumeration
.Enum Constant and Description |
---|
APPLICATION_STOPPED_BY_PREVIOUS_DISCOUNT
The discount code is active and none of the discounts were applied and at least one of them was not applied because it was stopped by a previous discount that had the
StackingMode |
DOES_NOT_MATCH_CART
The discount code is active and it contains at least one active and valid cart discount.
|
MATCHES_CART
The discount code is active and it contains at least one active and valid cart discount.
|
MAX_APPLICATION_REACHED
maxApplications or maxApplicationsPerCustomer for discountCode has been reached.
|
NOT_ACTIVE
The discount code is not active or it does not contain any active and valid cart discounts.
|
NOT_VALID
The discount code is not valid or it does not contain any valid cart discounts.
|
Modifier and Type | Method and Description |
---|---|
static DiscountCodeState |
ofSphereValue(String value) |
static DiscountCodeState |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static DiscountCodeState[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
findBySphereName, name, toSphereName
public static final DiscountCodeState NOT_ACTIVE
public static final DiscountCodeState DOES_NOT_MATCH_CART
public static final DiscountCodeState MATCHES_CART
public static final DiscountCodeState MAX_APPLICATION_REACHED
public static final DiscountCodeState APPLICATION_STOPPED_BY_PREVIOUS_DISCOUNT
StackingMode
public static final DiscountCodeState NOT_VALID
'validFrom'
and 'validUntil'
dates.public static DiscountCodeState[] values()
for (DiscountCodeState c : DiscountCodeState.values()) System.out.println(c);
public static DiscountCodeState valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static DiscountCodeState ofSphereValue(String value)