Package ru.moysklad.remap_1_2.entities
Enum CompanySettings.DiscountStrategy
- java.lang.Object
-
- java.lang.Enum<CompanySettings.DiscountStrategy>
-
- ru.moysklad.remap_1_2.entities.CompanySettings.DiscountStrategy
-
- All Implemented Interfaces:
Serializable,Comparable<CompanySettings.DiscountStrategy>
- Enclosing class:
- CompanySettings
public static enum CompanySettings.DiscountStrategy extends Enum<CompanySettings.DiscountStrategy>
Стратегия совместного применения скидок
-
-
Enum Constant Summary
Enum Constants Enum Constant Description byPriorityПриоритетная (должна действовать одна, наиболее выгодная для покупателя скидка)bySumСумма скидок (должна действовать сумма скидок)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static CompanySettings.DiscountStrategyvalueOf(String name)Returns the enum constant of this type with the specified name.static CompanySettings.DiscountStrategy[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
bySum
public static final CompanySettings.DiscountStrategy bySum
Сумма скидок (должна действовать сумма скидок)
-
byPriority
public static final CompanySettings.DiscountStrategy byPriority
Приоритетная (должна действовать одна, наиболее выгодная для покупателя скидка)
-
-
Method Detail
-
values
public static CompanySettings.DiscountStrategy[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (CompanySettings.DiscountStrategy c : CompanySettings.DiscountStrategy.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static CompanySettings.DiscountStrategy valueOf(String name)
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
-
-