Class DefaultPDTProcessor<VALUE extends PDTValue,INFO extends PDTInformation,CRITERIA extends PDTCriteria>
java.lang.Object
de.hybris.platform.order.strategies.calculation.pdt.processor.impl.DefaultPDTProcessor<VALUE,INFO,CRITERIA>
- All Implemented Interfaces:
PDTProcessor
public class DefaultPDTProcessor<VALUE extends PDTValue,INFO extends PDTInformation,CRITERIA extends PDTCriteria>
extends Object
implements PDTProcessor
Default implementation of PDT processor (
PDTProcessor, that fill values/informations if current
values/informations are empty or NO_RESULT. This processor always calls method doProcess from PDTProcessorChain-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddoProcess(PDTContext context, PDTProcessorChain chain) ThedoProcessmethod of the PDTProcessor is called by the application if price/discount/tax information or values are needed to be resolved.voidsetFindPDTValueInfoStrategy(FindPDTValueInfoStrategy<VALUE, INFO, CRITERIA> findPDTValueInfoStrategy)
-
Field Details
-
NO_RESULT
-
-
Constructor Details
-
DefaultPDTProcessor
public DefaultPDTProcessor()
-
-
Method Details
-
doProcess
Description copied from interface:PDTProcessorThedoProcessmethod of the PDTProcessor is called by the application if price/discount/tax information or values are needed to be resolved. The PDTProcessorChain passed in to this method allows the PDTProcessor to pass on the context to the next entity in the chain.A typical implementation of this method would follow the following pattern:
1. Examine the PDTCriteriaTarget from the context (context.getPDTCriteriaTarget())
2. Examine the CRITERIA from the context (context.getCriteria())
2. Depending on the PDTCriteriaTarget and CRITERIA process to resolve values or information
3. Set up values or information
3. a) either invoke the next entity in the chain using the PDTProcessorChain object (chain.doProcess(PDTContext context)),
3. b) or not pass on context to the next entity in the process chain to block the context processing- Specified by:
doProcessin interfacePDTProcessor- Parameters:
context- contains criteria and values/information to processchain- provides access to the next processor in the chain for this processor to pass the context to for further processing- Throws:
CalculationException
-
setFindPDTValueInfoStrategy
public void setFindPDTValueInfoStrategy(FindPDTValueInfoStrategy<VALUE, INFO, CRITERIA> findPDTValueInfoStrategy)
-