Class AbstractSourcingStrategy
java.lang.Object
de.hybris.platform.warehousing.sourcing.strategy.AbstractSourcingStrategy
- All Implemented Interfaces:
SourcingStrategy
- Direct Known Subclasses:
NoRestrictionsStrategy,NoSplittingStrategy,PickupStrategy
Abstract sourcing strategy. This will delegate the post-processing.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleancheckSourceCompleted(SourcingContext sourcingContext) Check if the order was sourced.protected LonggetAvailabilityForProduct(ProductModel productModel, SourcingLocation sourcingLocation) Retrieve the stock available from a sourcing locationprotected longgetQuantitySourced(Set<SourcingResult> sourcingResults, AbstractOrderEntryModel orderEntry) Retrieve the quantity already sourcedprotected SourcingResultFactoryIndicates whether this sourcing strategy will allow other sourcing strategies to attempt to source the same order entries.voidsetSourcingResultFactory(SourcingResultFactory sourcingResultFactory) voidsetTerminal(Boolean terminal) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.platform.warehousing.sourcing.strategy.SourcingStrategy
source
-
Constructor Details
-
AbstractSourcingStrategy
public AbstractSourcingStrategy()
-
-
Method Details
-
getAvailabilityForProduct
protected Long getAvailabilityForProduct(ProductModel productModel, SourcingLocation sourcingLocation) Retrieve the stock available from a sourcing location- Parameters:
productModel- theProductModelsourcingLocation- theSourcingLocation- Returns:
- the stock available
-
getQuantitySourced
protected long getQuantitySourced(Set<SourcingResult> sourcingResults, AbstractOrderEntryModel orderEntry) Retrieve the quantity already sourced- Parameters:
sourcingResults-SourcingContextorderEntry- theAbstractOrderEntryModel- Returns:
-
checkSourceCompleted
Check if the order was sourced.- Parameters:
sourcingContext-SourcingContext- Returns:
- true if the all order entries was fully sourced
-
isTerminal
Description copied from interface:SourcingStrategyIndicates whether this sourcing strategy will allow other sourcing strategies to attempt to source the same order entries.- Specified by:
isTerminalin interfaceSourcingStrategy- Returns:
- true if the strategy is terminal; false otherwise
-
getSourcingResultFactory
-
setSourcingResultFactory
-
setTerminal
-