atg.commerce.csr.pricing.calculators
Class ExchangePromotionEvaluationUpdateCalculator

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.commerce.pricing.ItemPriceCalculator
              extended by atg.commerce.csr.pricing.calculators.ExchangePromotionEvaluationUpdateCalculator
All Implemented Interfaces:
atg.commerce.pricing.ItemPriceSourceHandler, atg.commerce.pricing.ItemPricingCalculator, atg.naming.NameContextBindingListener, atg.naming.NameContextElement, atg.naming.NameResolver, atg.nucleus.AdminableService, atg.nucleus.logging.ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, atg.nucleus.logging.VariableArgumentApplicationLogging, atg.nucleus.naming.ComponentNameResolver, atg.nucleus.Service, atg.nucleus.ServiceListener, java.util.EventListener

public class ExchangePromotionEvaluationUpdateCalculator
extends atg.commerce.pricing.ItemPriceCalculator

This calculator is used by CSC to perform processing against the promotion evaluation order whenever the exchange order is being priced.

The promotion evaluation process provides the calculations and data structures in the ReturnRequest to determine which promotions, along with their value, should be applied to the exchange order by the ExchangeItemAdjustmentCalculator and ExchangeOrderAdjustmentCalculator calculators.

This calculator doesn't perform any actual pricing of the items, it is just used as an entry point to process the promotion evaluation order during pricing operations. It overrides priceItems to trigger this processing whenever the exchange order is being priced.


Field Summary
static java.lang.String CLASS_VERSION
          Class version string
protected  ReturnManager mReturnManager
           
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
ExchangePromotionEvaluationUpdateCalculator()
           
 
Method Summary
 ReturnManager getReturnManager()
           
protected  void priceItem(double pPrice, atg.commerce.pricing.ItemPriceInfo pPriceQuote, atg.commerce.order.CommerceItem pItem, atg.repository.RepositoryItem pPricingModel, java.util.Locale pLocale, atg.repository.RepositoryItem pProfile, java.util.Map pExtraParameters)
          Noop impl.
 void priceItem(atg.commerce.pricing.ItemPriceInfo pPriceQuote, atg.commerce.order.CommerceItem pItem, atg.repository.RepositoryItem pPricingModel, java.util.Locale pLocale, atg.repository.RepositoryItem pProfile, java.util.Map pExtraParameters)
          Noop impl.
 void priceItems(java.util.List pPriceQuotes, java.util.List pItems, atg.repository.RepositoryItem pPricingModel, java.util.Locale pLocale, atg.repository.RepositoryItem pProfile, atg.commerce.order.Order pOrder, java.util.Map pExtraParameters)
          Executes processing against the Promotion Evaluation Order whenever the order being priced is the exchange order for the current return.
 void setReturnManager(ReturnManager pReturnManager)
          Sets the return manager
 
Methods inherited from class atg.commerce.pricing.ItemPriceCalculator
getItemPriceSource, getLoggingIdentifier, getPrice, getPricePropertyName, getPriceSource, getPriceSource, getPricingTools, isPriceFromCatalogRef, isRequirePriceValue, populateItemPriceSource, priceEachItem, setLoggingIdentifier, setPriceFromCatalogRef, setPricePropertyName, setPricingTools, setRequirePriceValue, shouldConsumeSource
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static final java.lang.String CLASS_VERSION
Class version string

See Also:
Constant Field Values

mReturnManager

protected ReturnManager mReturnManager
Constructor Detail

ExchangePromotionEvaluationUpdateCalculator

public ExchangePromotionEvaluationUpdateCalculator()
Method Detail

setReturnManager

public void setReturnManager(ReturnManager pReturnManager)
Sets the return manager

Parameters:
pReturnManager - the return manager

getReturnManager

public ReturnManager getReturnManager()
Returns:
the ReturnManager

priceItem

protected void priceItem(double pPrice,
                         atg.commerce.pricing.ItemPriceInfo pPriceQuote,
                         atg.commerce.order.CommerceItem pItem,
                         atg.repository.RepositoryItem pPricingModel,
                         java.util.Locale pLocale,
                         atg.repository.RepositoryItem pProfile,
                         java.util.Map pExtraParameters)
                  throws atg.commerce.pricing.PricingException
Noop impl.

Specified by:
priceItem in class atg.commerce.pricing.ItemPriceCalculator
Throws:
atg.commerce.pricing.PricingException

priceItem

public void priceItem(atg.commerce.pricing.ItemPriceInfo pPriceQuote,
                      atg.commerce.order.CommerceItem pItem,
                      atg.repository.RepositoryItem pPricingModel,
                      java.util.Locale pLocale,
                      atg.repository.RepositoryItem pProfile,
                      java.util.Map pExtraParameters)
               throws atg.commerce.pricing.PricingException
Noop impl. not supported by this calculator

Specified by:
priceItem in interface atg.commerce.pricing.ItemPricingCalculator
Overrides:
priceItem in class atg.commerce.pricing.ItemPriceCalculator
Throws:
atg.commerce.pricing.PricingException

priceItems

public void priceItems(java.util.List pPriceQuotes,
                       java.util.List pItems,
                       atg.repository.RepositoryItem pPricingModel,
                       java.util.Locale pLocale,
                       atg.repository.RepositoryItem pProfile,
                       atg.commerce.order.Order pOrder,
                       java.util.Map pExtraParameters)
                throws atg.commerce.pricing.PricingException
Executes processing against the Promotion Evaluation Order whenever the order being priced is the exchange order for the current return.

Specified by:
priceItems in interface atg.commerce.pricing.ItemPricingCalculator
Overrides:
priceItems in class atg.commerce.pricing.ItemPriceCalculator
Throws:
atg.commerce.pricing.PricingException
See Also:
ReturnTools#processPromotionEvaluationOrder(ReturnRequest)