Class PriceSummary

java.lang.Object
com.broadleafcommerce.pricing.domain.PriceSummary
All Implemented Interfaces:
Serializable

public class PriceSummary extends Object implements Serializable
Summarizes price information from a PriceData for a PriceableTarget. This is a DTO used in the PriceInfoService and is not intended to be returned or supplied via APIs.
Since:
Pricing Service 2.1.0, Release Train 2.2.0
Author:
Nathan Moore (nathandmoore)
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
     
    boolean
     
    Defines the ending time for which this price is active
    Defines the beginning time for which this price is active.
    The available quantity that can use this price data.
    javax.money.MonetaryAmount
    The one-time price.
    Id of the specific PriceData that this price came from.
    The relative priority of this price detail vs others that might apply to the same target.
    com.broadleafcommerce.pricing.client.domain.RecurringPriceDetail
    Represents the details related to a recurring (or subscription) price include the terms.
    Defines the initial quantity available for this price data before a pricing event such as a flash sale.
    com.broadleafcommerce.pricing.client.domain.UsagePriceDetail
    Represents the details related to a usage price including the units.
    int
     
    void
    setActiveEndDate(Instant activeEndDate)
    Defines the ending time for which this price is active
    void
    setActiveStartDate(Instant activeStartDate)
    Defines the beginning time for which this price is active.
    void
    setAvailableQuantity(Integer availableQuantity)
    The available quantity that can use this price data.
    void
    setPrice(javax.money.MonetaryAmount price)
    The one-time price.
    void
    setPriceDataId(String priceDataId)
    Id of the specific PriceData that this price came from.
    void
    setPriority(Integer priority)
    The relative priority of this price detail vs others that might apply to the same target.
    void
    setRecurringPriceDetail(com.broadleafcommerce.pricing.client.domain.RecurringPriceDetail recurringPriceDetail)
    Represents the details related to a recurring (or subscription) price include the terms.
    void
    setStartingQuantity(Integer startingQuantity)
    Defines the initial quantity available for this price data before a pricing event such as a flash sale.
    void
    setUsagePriceDetail(com.broadleafcommerce.pricing.client.domain.UsagePriceDetail usagePriceDetail)
    Represents the details related to a usage price including the units.
     

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • PriceSummary

      public PriceSummary()
  • Method Details

    • getPrice

      public javax.money.MonetaryAmount getPrice()
      The one-time price. This is typically used during checkout.
    • getPriceDataId

      public String getPriceDataId()
      Id of the specific PriceData that this price came from.

      Only applicable if the price was from a PriceData.

    • getActiveStartDate

      public Instant getActiveStartDate()
      Defines the beginning time for which this price is active.
    • getActiveEndDate

      public Instant getActiveEndDate()
      Defines the ending time for which this price is active
    • getStartingQuantity

      public Integer getStartingQuantity()
      Defines the initial quantity available for this price data before a pricing event such as a flash sale. It only serves an informational purpose.
    • getAvailableQuantity

      public Integer getAvailableQuantity()
      The available quantity that can use this price data. This is used for events such as a flash sale where the sale price is limited to a certain amount of quantity.
    • getRecurringPriceDetail

      public com.broadleafcommerce.pricing.client.domain.RecurringPriceDetail getRecurringPriceDetail()
      Represents the details related to a recurring (or subscription) price include the terms.
    • getUsagePriceDetail

      public com.broadleafcommerce.pricing.client.domain.UsagePriceDetail getUsagePriceDetail()
      Represents the details related to a usage price including the units.
    • getPriority

      public Integer getPriority()
      The relative priority of this price detail vs others that might apply to the same target.
    • setPrice

      public void setPrice(javax.money.MonetaryAmount price)
      The one-time price. This is typically used during checkout.
    • setPriceDataId

      public void setPriceDataId(String priceDataId)
      Id of the specific PriceData that this price came from.

      Only applicable if the price was from a PriceData.

    • setActiveStartDate

      public void setActiveStartDate(Instant activeStartDate)
      Defines the beginning time for which this price is active.
    • setActiveEndDate

      public void setActiveEndDate(Instant activeEndDate)
      Defines the ending time for which this price is active
    • setStartingQuantity

      public void setStartingQuantity(Integer startingQuantity)
      Defines the initial quantity available for this price data before a pricing event such as a flash sale. It only serves an informational purpose.
    • setAvailableQuantity

      public void setAvailableQuantity(Integer availableQuantity)
      The available quantity that can use this price data. This is used for events such as a flash sale where the sale price is limited to a certain amount of quantity.
    • setRecurringPriceDetail

      public void setRecurringPriceDetail(com.broadleafcommerce.pricing.client.domain.RecurringPriceDetail recurringPriceDetail)
      Represents the details related to a recurring (or subscription) price include the terms.
    • setUsagePriceDetail

      public void setUsagePriceDetail(com.broadleafcommerce.pricing.client.domain.UsagePriceDetail usagePriceDetail)
      Represents the details related to a usage price including the units.
    • setPriority

      public void setPriority(Integer priority)
      The relative priority of this price detail vs others that might apply to the same target.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object