public interface PricingModelEvaluationVetoer
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
prepareForVetoing(PricingEngineService pPricingEngine,
PricingContext pPricingContext,
java.util.Map pExtraParametersMap)
Prepares a vetoer for vetoing promotions.
|
java.lang.String |
vetoPromotion(PricingEngineService pPricingEngine,
PricingContext pPricingContext,
java.util.Map pExtraParametersMap,
java.lang.Object pVetoParam)
Allows the promotion in pPricingContext to be vetoed.
|
static final java.lang.String CLASS_VERSION
java.lang.Object prepareForVetoing(PricingEngineService pPricingEngine, PricingContext pPricingContext, java.util.Map pExtraParametersMap)
Prepares a vetoer for vetoing promotions.
This allows a vetoer to inspect the pricing context and extract any information needed to do it's vetoing. e.g. a sku vetoer might extract the skus from the order. This information can be returned from this method as an Object which will subsequently be passed into the vetoPromotion method for vetoing each promotion.
An implementation should only return null if it's vetoPromotion method should not be subsequently called for each promotion.
pPricingEngine
- PricingEngineService that called this vetoerpPricingContext
- PricingContext for this pricing operationpExtraParametersMap
- Map of extra parameters if neededvetoPromotion(PricingEngineService, PricingContext, Map, Object)
java.lang.String vetoPromotion(PricingEngineService pPricingEngine, PricingContext pPricingContext, java.util.Map pExtraParametersMap, java.lang.Object pVetoParam)
Allows the promotion in pPricingContext to be vetoed.
A vetoer could inspect the pricing context or use the passed in pVetoParam Object to decide whether the promotion should be vetoed.
pPricingEngine
- PricingEngineService that called this vetoerpPricingContext
- PricingContext including the promotion to be checkedpExtraParametersMap
- Map of extra parameters if neededpVetoParam
- Object returned by prepareForVetoing method,
guaranteed to not be null.prepareForVetoing(PricingEngineService, PricingContext, Map)