Class PriceDetail
java.lang.Object
com.broadleafcommerce.pricing.client.domain.PriceDetail
- All Implemented Interfaces:
PriceDetailComparable,Serializable
Details about the candidate prices and their originating
PriceListRef. These will be
aggregated on a PriceInfo.- Author:
- Chad Harchar (charchar)
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanDefines the ending time for which this price is activeDefines the beginning time for which this price is active.The available quantity that can use this price data.javax.money.MonetaryAmountgetPrice()Price for thePriceInfo.getTarget()for a particularPriceList.Id of the specific PriceData that this price came from.PriceDataTiersfor thePriceInfo.getTarget().The relative priority of the parent price list vs other price lists that may have price details with the same target.The source of this price within the price list, e.g.The originating type of this corresponding price.The relative priority of this price detail vs others that might apply to the same target.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.Represents the details related to a usage price including the units.inthashCode()booleanWhether this price is limited by quantity.voidsetActiveEndDate(Instant activeEndDate) Defines the ending time for which this price is activevoidsetActiveStartDate(Instant activeStartDate) Defines the beginning time for which this price is active.voidsetAvailableQuantity(Integer availableQuantity) The available quantity that can use this price data.voidsetPrice(javax.money.MonetaryAmount price) voidsetPriceDataId(String priceDataId) Id of the specific PriceData that this price came from.voidsetPriceDataTierList(List<PriceDataTierRef> priceDataTierList) PriceDataTiersfor thePriceInfo.getTarget().voidsetPriceList(PriceListRef priceList) voidsetPriceListPriority(Integer priceListPriority) voidsetPriceSource(String priceSource) The source of this price within the price list, e.g.voidsetPriceType(String priceType) The originating type of this corresponding price.voidsetPriority(Integer priority) voidsetRecurringPriceDetail(RecurringPriceDetail recurringPriceDetail) voidsetStartingQuantity(Integer startingQuantity) Defines the initial quantity available for this price data before a pricing event such as a flash sale.voidsetUsagePriceDetail(UsagePriceDetail usagePriceDetail) toString()
-
Constructor Details
-
PriceDetail
public PriceDetail()
-
-
Method Details
-
hasLimitedQuantity
public boolean hasLimitedQuantity()Whether this price is limited by quantity.- Since:
- Pricing Client 2.0.3
-
getPrice
public javax.money.MonetaryAmount getPrice()Description copied from interface:PriceDetailComparablePrice for thePriceInfo.getTarget()for a particularPriceList.- Specified by:
getPricein interfacePriceDetailComparable- Returns:
- the Price for the
PriceInfo.getTarget()for a particularPriceList. - See Also:
-
getPriceDataId
Id of the specific PriceData that this price came from.Only applicable if the
priceSourceisDefaultPriceListPriceSources.BLC_PRICE_LIST_PRICE_DATA.- Since:
- Pricing Client 2.0.3
-
getRecurringPriceDetail
Description copied from interface:PriceDetailComparableRepresents the details related to a recurring (or subscription) price include the terms.- Specified by:
getRecurringPriceDetailin interfacePriceDetailComparable- Returns:
- Represents the details related to a recurring (or subscription) price include the terms.
- Since:
- Pricing Client 2.0.3
- See Also:
-
getUsagePriceDetail
Description copied from interface:PriceDetailComparableRepresents the details related to a usage price including the units.- Specified by:
getUsagePriceDetailin interfacePriceDetailComparable- Returns:
- Represents the details related to a usage price including the units.
- Since:
- Pricing Client 2.0.3
- See Also:
-
getPriceList
- See Also:
-
getPriceSource
The source of this price within the price list, e.g. price list formula, price list price data, etc.This may be helpful for consuming services to determine the priority of the price. For example, a price from
DefaultPriceListPriceSources.BLC_PRICE_LIST_PRICE_DATAmay have a higher precedence overDefaultPriceListPriceSources.BLC_PRICE_LIST_FORMULA.- Since:
- 1.4.1, 2.0.1
- See Also:
-
getActiveStartDate
Defines the beginning time for which this price is active.- Since:
- Pricing Client 2.0.3
-
getActiveEndDate
Defines the ending time for which this price is active- Since:
- Pricing Client 2.0.3
-
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.- Since:
- Pricing Client 2.0.3
-
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.- Since:
- Pricing Client 2.0.3
-
getPriceType
The originating type of this corresponding price. -
getPriceDataTierList
PriceDataTiersfor thePriceInfo.getTarget().- See Also:
-
getPriority
Description copied from interface:PriceDetailComparableThe relative priority of this price detail vs others that might apply to the same target.- Specified by:
getPriorityin interfacePriceDetailComparable- Returns:
- The relative priority of this price detail vs others that might apply to the same target.
- Since:
- PricingService 2.0.3
- See Also:
-
getPriceListPriority
Description copied from interface:PriceDetailComparableThe relative priority of the parent price list vs other price lists that may have price details with the same target.- Specified by:
getPriceListPriorityin interfacePriceDetailComparable- Returns:
- The relative priority of the parent price list vs other price lists that may have price details with the same target.
- Since:
- Pricing Client 2.0.3
- See Also:
-
setPrice
public void setPrice(javax.money.MonetaryAmount price) - See Also:
-
setPriceDataId
Id of the specific PriceData that this price came from.Only applicable if the
priceSourceisDefaultPriceListPriceSources.BLC_PRICE_LIST_PRICE_DATA.- Since:
- Pricing Client 2.0.3
-
setRecurringPriceDetail
- Since:
- Pricing Client 2.0.3
- See Also:
-
setUsagePriceDetail
- Since:
- Pricing Client 2.0.3
- See Also:
-
setPriceList
- See Also:
-
setPriceSource
The source of this price within the price list, e.g. price list formula, price list price data, etc.This may be helpful for consuming services to determine the priority of the price. For example, a price from
DefaultPriceListPriceSources.BLC_PRICE_LIST_PRICE_DATAmay have a higher precedence overDefaultPriceListPriceSources.BLC_PRICE_LIST_FORMULA.- Since:
- 1.4.1, 2.0.1
- See Also:
-
setActiveStartDate
Defines the beginning time for which this price is active.- Since:
- Pricing Client 2.0.3
-
setActiveEndDate
Defines the ending time for which this price is active- Since:
- Pricing Client 2.0.3
-
setStartingQuantity
Defines the initial quantity available for this price data before a pricing event such as a flash sale. It only serves an informational purpose.- Since:
- Pricing Client 2.0.3
-
setAvailableQuantity
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.- Since:
- Pricing Client 2.0.3
-
setPriceType
The originating type of this corresponding price. -
setPriceDataTierList
PriceDataTiersfor thePriceInfo.getTarget().- See Also:
-
setPriority
- Since:
- PricingService 2.0.3
- See Also:
-
setPriceListPriority
- Since:
- Pricing Client 2.0.3
- See Also:
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-