Interface DiscountTypeCombination

All Known Subinterfaces:
BestDeal, Stacking

public interface DiscountTypeCombination
DiscountTypeCombination
Example to create a subtype instance using the builder pattern

     DiscountTypeCombination discountTypeCombination = DiscountTypeCombination.bestDealBuilder()
             chosenDiscountType("{chosenDiscountType}")
             .build()
 
  • Method Details

    • getType

      @NotNull @NotNull String getType()
      Returns:
      type
    • deepCopy

      factory method to create a deep copy of DiscountTypeCombination
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • bestDealBuilder

      static BestDealBuilder bestDealBuilder()
      builder for bestDeal subtype
      Returns:
      builder
    • stackingBuilder

      static StackingBuilder stackingBuilder()
      builder for stacking subtype
      Returns:
      builder
    • withDiscountTypeCombination

      default <T> T withDiscountTypeCombination(Function<DiscountTypeCombination,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<DiscountTypeCombination> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference