|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.broadleafcommerce.core.offer.service.processor.AbstractBaseProcessor
public abstract class AbstractBaseProcessor
| Field Summary | |
|---|---|
protected OfferTimeZoneProcessor |
offerTimeZoneProcessor
|
| Constructor Summary | |
|---|---|
AbstractBaseProcessor()
|
|
| Method Summary | |
|---|---|
protected void |
checkForItemRequirements(CandidatePromotionItems candidates,
OfferItemCriteria criteria,
List<PromotableOrderItem> promotableOrderItems,
boolean isQualifier)
|
protected void |
clearAllNonFinalizedQuantities(List<PromotableOrderItemPriceDetail> priceDetails)
We were not able to meet all of the ItemCriteria for a promotion, but some of the items were marked as qualifiers or targets. |
protected boolean |
couldOfferApplyToCustomer(Offer offer,
Customer customer)
Private method which executes the appliesToCustomerRules in the Offer to determine if this Offer can be applied to the Customer. |
protected CandidatePromotionItems |
couldOfferApplyToOrderItems(Offer offer,
List<PromotableOrderItem> promotableOrderItems)
|
protected boolean |
couldOfferApplyToRequestDTO(Offer offer,
RequestDTO requestDTO)
|
protected boolean |
couldOfferApplyToTimePeriod(Offer offer)
|
protected boolean |
couldOrderItemMeetOfferRequirement(OfferItemCriteria criteria,
PromotableOrderItem orderItem)
|
Boolean |
executeExpression(String expression,
Map<String,Object> vars)
Private method used by couldOfferApplyToOrder to execute the MVEL expression in the appliesToOrderRules to determine if this offer can be applied. |
List<Offer> |
filterOffers(List<Offer> offers,
Customer customer)
|
protected void |
finalizeQuantities(List<PromotableOrderItemPriceDetail> priceDetails)
Updates the finalQuanties for the PromotionDiscounts and PromotionQualifiers. |
OfferTimeZoneProcessor |
getOfferTimeZoneProcessor()
|
protected boolean |
meetsItemQualifierSubtotal(Offer offer,
CandidatePromotionItems candidateItem)
|
protected List<Offer> |
removeInvalidCustomerOffers(List<Offer> offers,
Customer customer)
Private method that takes in a list of Offers and removes all Offers from the list that does not apply to this customer. |
protected List<Offer> |
removeInvalidRequestOffers(List<Offer> offers)
|
protected List<Offer> |
removeOutOfDateOffers(List<Offer> offers)
Removes all out of date offers. |
protected List<Offer> |
removeTimePeriodOffers(List<Offer> offers)
Removes all offers that are not within the timezone and timeperiod of the offer. |
void |
setOfferTimeZoneProcessor(OfferTimeZoneProcessor offerTimeZoneProcessor)
|
protected void |
splitDetailsIfNecessary(List<PromotableOrderItemPriceDetail> priceDetails)
Checks to see if the discountQty matches the detailQty. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected OfferTimeZoneProcessor offerTimeZoneProcessor
| Constructor Detail |
|---|
public AbstractBaseProcessor()
| Method Detail |
|---|
protected CandidatePromotionItems couldOfferApplyToOrderItems(Offer offer,
List<PromotableOrderItem> promotableOrderItems)
protected boolean meetsItemQualifierSubtotal(Offer offer,
CandidatePromotionItems candidateItem)
protected void checkForItemRequirements(CandidatePromotionItems candidates,
OfferItemCriteria criteria,
List<PromotableOrderItem> promotableOrderItems,
boolean isQualifier)
protected boolean couldOrderItemMeetOfferRequirement(OfferItemCriteria criteria,
PromotableOrderItem orderItem)
public Boolean executeExpression(String expression,
Map<String,Object> vars)
expression - vars -
protected void clearAllNonFinalizedQuantities(List<PromotableOrderItemPriceDetail> priceDetails)
priceDetails - protected void finalizeQuantities(List<PromotableOrderItemPriceDetail> priceDetails)
priceDetails - protected void splitDetailsIfNecessary(List<PromotableOrderItemPriceDetail> priceDetails)
priceDetails -
public List<Offer> filterOffers(List<Offer> offers,
Customer customer)
filterOffers in interface BaseProcessorprotected List<Offer> removeInvalidRequestOffers(List<Offer> offers)
protected boolean couldOfferApplyToRequestDTO(Offer offer,
RequestDTO requestDTO)
protected List<Offer> removeTimePeriodOffers(List<Offer> offers)
offers -
protected boolean couldOfferApplyToTimePeriod(Offer offer)
protected List<Offer> removeOutOfDateOffers(List<Offer> offers)
offers -
protected List<Offer> removeInvalidCustomerOffers(List<Offer> offers,
Customer customer)
offers - customer -
protected boolean couldOfferApplyToCustomer(Offer offer,
Customer customer)
offer - customer -
public OfferTimeZoneProcessor getOfferTimeZoneProcessor()
public void setOfferTimeZoneProcessor(OfferTimeZoneProcessor offerTimeZoneProcessor)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||