Interface OptionGenerationService<P extends Product>

All Known Implementing Classes:
DefaultOptionGenerationService

public interface OptionGenerationService<P extends Product>
Service responsible for generation a Product's options from an OptionTemplate or OptionTemplateGroup.

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: