Class AbstractSourcingStrategy

    • Constructor Detail

      • AbstractSourcingStrategy

        public AbstractSourcingStrategy()
    • Method Detail

      • getAvailabilityForProduct

        protected java.lang.Long getAvailabilityForProduct​(ProductModel productModel,
                                                           SourcingLocation sourcingLocation)
        Retrieve the stock available from a sourcing location
        Parameters:
        productModel - the ProductModel
        sourcingLocation - the SourcingLocation
        Returns:
        the stock available
      • checkSourceCompleted

        protected boolean checkSourceCompleted​(SourcingContext sourcingContext)
        Check if the order was sourced.
        Parameters:
        sourcingContext - SourcingContext
        Returns:
        true if the all order entries was fully sourced
      • isTerminal

        public java.lang.Boolean isTerminal()
        Description copied from interface: SourcingStrategy
        Indicates whether this sourcing strategy will allow other sourcing strategies to attempt to source the same order entries.
        Specified by:
        isTerminal in interface SourcingStrategy
        Returns:
        true if the strategy is terminal; false otherwise
      • setSourcingResultFactory

        public void setSourcingResultFactory​(SourcingResultFactory sourcingResultFactory)
      • setTerminal

        public void setTerminal​(java.lang.Boolean terminal)