Class CandidateFulfillmentGroup
java.lang.Object
com.broadleafcommerce.promotion.offer.service.dto.CandidateFulfillmentGroup
- All Implemented Interfaces:
Serializable
Represents a candidate fulfillment group for which an
Offer has been applied. Used as a
list of items in CandidateFulfillmentGroupOffer to represent applying the corresponding
offer to all of an order's fulfillment groups.- Author:
- Chad Harchar (charchar)
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjavax.money.MonetaryAmountCalculate and return the price for thisEnhancedFulfillmentGroupwithout any adjustments added.protected booleanbooleanMap ofItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.javax.money.MonetaryAmountThe amount off this fulfillment group would get if thecandidate offerwas applied.javax.money.MonetaryAmountThe adjusted discounted price for this candidate fulfillment group if thecandidate offerwas applied.TheEnhancedFulfillmentGroupthat is decorated for consideration as part of aCandidateFulfillmentGroupOffer.inthashCode()voidBetween permutation runs, we need to reset the state of intermediate valuesvoidsetCandidateQualifiersMap(Map<ItemCriteriaRule, Collection<EnhancedFulfillmentLineItem>> candidateQualifiersMap) Map ofItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.voidsetDiscountedAmount(javax.money.MonetaryAmount discountedAmount) The amount off this fulfillment group would get if thecandidate offerwas applied.voidsetDiscountedTotal(javax.money.MonetaryAmount discountedTotal) The adjusted discounted price for this candidate fulfillment group if thecandidate offerwas applied.voidsetFulfillmentGroup(EnhancedFulfillmentGroup fulfillmentGroup) TheEnhancedFulfillmentGroupthat is decorated for consideration as part of aCandidateFulfillmentGroupOffer.toString()
-
Constructor Details
-
CandidateFulfillmentGroup
public CandidateFulfillmentGroup()
-
-
Method Details
-
calculatePriceWithoutAdjustments
public javax.money.MonetaryAmount calculatePriceWithoutAdjustments()Calculate and return the price for thisEnhancedFulfillmentGroupwithout any adjustments added.- Returns:
- Calculate and return the price for this
EnhancedFulfillmentGroupwithout any adjustments added.
-
resetState
public void resetState()Between permutation runs, we need to reset the state of intermediate values -
getFulfillmentGroup
TheEnhancedFulfillmentGroupthat is decorated for consideration as part of aCandidateFulfillmentGroupOffer. -
getCandidateQualifiersMap
Map ofItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.- Returns:
- Map of
ItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.
-
getDiscountedAmount
public javax.money.MonetaryAmount getDiscountedAmount()The amount off this fulfillment group would get if thecandidate offerwas applied.- Returns:
- The amount off this fulfillment group would get if the
candidate offerwas applied.
-
getDiscountedTotal
public javax.money.MonetaryAmount getDiscountedTotal()The adjusted discounted price for this candidate fulfillment group if thecandidate offerwas applied.- Returns:
- The adjusted discounted price for this candidate fulfillment group if the
candidate offerwas applied.
-
setFulfillmentGroup
TheEnhancedFulfillmentGroupthat is decorated for consideration as part of aCandidateFulfillmentGroupOffer. -
setCandidateQualifiersMap
public void setCandidateQualifiersMap(Map<ItemCriteriaRule, Collection<EnhancedFulfillmentLineItem>> candidateQualifiersMap) Map ofItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.- Parameters:
candidateQualifiersMap- Map ofItemCriteriaRulefrom anoffer's item qualifier criteriato aCollectionofEnhancedFulfillmentLineItemthat meet that criteria for thisfulfillmentGroup.
-
setDiscountedAmount
public void setDiscountedAmount(javax.money.MonetaryAmount discountedAmount) The amount off this fulfillment group would get if thecandidate offerwas applied.- Parameters:
discountedAmount- The amount off this fulfillment group would get if thecandidate offerwas applied.
-
setDiscountedTotal
public void setDiscountedTotal(javax.money.MonetaryAmount discountedTotal) The adjusted discounted price for this candidate fulfillment group if thecandidate offerwas applied.- Parameters:
discountedTotal- The adjusted discounted price for this candidate fulfillment group if thecandidate offerwas applied.
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-