Enum Class OptionGenerationType

java.lang.Object
java.lang.Enum<OptionGenerationType>
com.broadleafcommerce.catalog.web.endpoint.dto.type.OptionGenerationType
All Implemented Interfaces:
Serializable, Comparable<OptionGenerationType>, Constable

public enum OptionGenerationType extends Enum<OptionGenerationType>
Defines the types of generations that can be used to generate Product.getOptions() from an admin tool or programmatically.

ProductOptions may be used across many products; in such cases, Broadleaf provides an OptionTemplate as a means to share options. Moreover, some options are frequently used in combination with each other; thus, there are also OptionTemplateGroups that can group multiple templates together.

"Option generation", then, is the process of adding a template or group to a product. By default, this is done by copying the template(s) to Product.getOptions(). This allows each set of options to be customized per product while still eliminating redundancy for users reusing the same or similar options across many products.

Author:
Nathan Moore (nathandmoore)
See Also:
  • Enum Constant Details

  • Method Details

    • values

      public static OptionGenerationType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static OptionGenerationType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null