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 boolean
boolean
Defines 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.MonetaryAmount
getPrice()
Price for thePriceInfo.getTarget()
for a particularPriceList
.Id of the specific PriceData that this price came from.PriceDataTiers
for 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.int
hashCode()
boolean
Whether this price is limited by quantity.void
setActiveEndDate
(Instant activeEndDate) Defines the ending time for which this price is activevoid
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) void
setPriceDataId
(String priceDataId) Id of the specific PriceData that this price came from.void
setPriceDataTierList
(List<PriceDataTierRef> priceDataTierList) PriceDataTiers
for thePriceInfo.getTarget()
.void
setPriceList
(PriceListRef priceList) void
setPriceListPriority
(Integer priceListPriority) void
setPriceSource
(String priceSource) The source of this price within the price list, e.g.void
setPriceType
(String priceType) The originating type of this corresponding price.void
setPriority
(Integer priority) void
setRecurringPriceDetail
(RecurringPriceDetail recurringPriceDetail) void
setStartingQuantity
(Integer startingQuantity) Defines the initial quantity available for this price data before a pricing event such as a flash sale.void
setUsagePriceDetail
(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:PriceDetailComparable
Price for thePriceInfo.getTarget()
for a particularPriceList
.- Specified by:
getPrice
in 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
priceSource
isDefaultPriceListPriceSources.BLC_PRICE_LIST_PRICE_DATA
.- Since:
- Pricing Client 2.0.3
-
getRecurringPriceDetail
Description copied from interface:PriceDetailComparable
Represents the details related to a recurring (or subscription) price include the terms.- Specified by:
getRecurringPriceDetail
in 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:PriceDetailComparable
Represents the details related to a usage price including the units.- Specified by:
getUsagePriceDetail
in 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_DATA
may 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
PriceDataTiers
for thePriceInfo.getTarget()
.- See Also:
-
getPriority
Description copied from interface:PriceDetailComparable
The relative priority of this price detail vs others that might apply to the same target.- Specified by:
getPriority
in 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:PriceDetailComparable
The relative priority of the parent price list vs other price lists that may have price details with the same target.- Specified by:
getPriceListPriority
in 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
priceSource
isDefaultPriceListPriceSources.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_DATA
may 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
PriceDataTiers
for 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
-