Class FulfillmentPriceResultHolder

java.lang.Object
com.broadleafcommerce.fulfillment.service.dto.FulfillmentPriceResultHolder

public class FulfillmentPriceResultHolder extends Object
Holds the result of a single calculator's price execution.
  • Field Details

    • context

      protected FulfillmentPricingContext context
    • group

    • items

      Items from the EnhancedFulfillmentPricingGroup that are eligible for the FulfillmentCalculator.
    • handlingAllItems

      protected boolean handlingAllItems
    • calculator

      protected FulfillmentCalculator calculator
    • itemPriceResults

    • eligibleItemsSubtotal

      protected javax.money.MonetaryAmount eligibleItemsSubtotal
    • eligibleItemsWeight

      protected com.broadleafcommerce.fulfillment.common.domain.Weight eligibleItemsWeight
      The normalized combined weight of the eligible items. Should be initialized before calculations are made. However, Weight.getValue() can be null even if eligibleItemsWeight is initialized if the bandField is not BandField.WEIGHT.
    • eligibleItemsQuantity

      protected int eligibleItemsQuantity
    • fulfillmentPrice

      protected javax.money.MonetaryAmount fulfillmentPrice
    • priceExistingServiceLevelsOnly

      protected boolean priceExistingServiceLevelsOnly
    • bandField

      protected BandField bandField
      The BandField used to calculate the fulfillment price. This is recorded for business logic like prorating the fulfillment price to items to ensure that proration uses the same field to determine the proportion of the price that is applicable to the item.
  • Constructor Details

    • FulfillmentPriceResultHolder

      public FulfillmentPriceResultHolder()
  • Method Details

    • addItemPriceResult

      public void addItemPriceResult(EnhancedFulfillmentPricingItem item, FulfillmentItemPriceResult result)
    • getServiceLevel

      public String getServiceLevel()
    • getContext

      public FulfillmentPricingContext getContext()
    • setContext

      public void setContext(FulfillmentPricingContext context)
    • getGroup

    • setGroup

      public void setGroup(EnhancedFulfillmentPricingGroup group)
    • getItems

      Items from the EnhancedFulfillmentPricingGroup that are eligible for the FulfillmentCalculator.
    • setItems

      public void setItems(List<EnhancedFulfillmentPricingItem> items)
      Items from the EnhancedFulfillmentPricingGroup that are eligible for the FulfillmentCalculator.
    • isHandlingAllItems

      public boolean isHandlingAllItems()
    • setHandlingAllItems

      public void setHandlingAllItems(boolean handlingAllItems)
    • getCalculator

      public FulfillmentCalculator getCalculator()
    • setCalculator

      public void setCalculator(FulfillmentCalculator calculator)
    • getEligibleItemsSubtotal

      public javax.money.MonetaryAmount getEligibleItemsSubtotal()
    • setEligibleItemsSubtotal

      public void setEligibleItemsSubtotal(javax.money.MonetaryAmount eligibleItemsSubtotal)
    • getEligibleItemsWeight

      public com.broadleafcommerce.fulfillment.common.domain.Weight getEligibleItemsWeight()
      The normalized combined weight of the eligible items. Should be initialized before calculations are made. However, Weight.getValue() can be null even if eligibleItemsWeight is initialized if the bandField is not BandField.WEIGHT.
    • setEligibleItemsWeight

      public void setEligibleItemsWeight(com.broadleafcommerce.fulfillment.common.domain.Weight eligibleItemsWeight)
      The normalized combined weight of the eligible items. Should be initialized before calculations are made. However, Weight.getValue() can be null even if eligibleItemsWeight is initialized if the bandField is not BandField.WEIGHT.
    • getEligibleItemsQuantity

      public int getEligibleItemsQuantity()
    • setEligibleItemsQuantity

      public void setEligibleItemsQuantity(int eligibleItemsQuantity)
    • getFulfillmentPrice

      public javax.money.MonetaryAmount getFulfillmentPrice()
    • setFulfillmentPrice

      public void setFulfillmentPrice(javax.money.MonetaryAmount fulfillmentPrice)
    • getAttributes

      public Map<String,String> getAttributes()
    • isPriceExistingServiceLevelsOnly

      public boolean isPriceExistingServiceLevelsOnly()
    • setPriceExistingServiceLevelsOnly

      public void setPriceExistingServiceLevelsOnly(boolean priceExistingServiceLevelsOnly)
    • getBandField

      public BandField getBandField()
      The BandField used to calculate the fulfillment price. This is recorded for business logic like prorating the fulfillment price to items to ensure that proration uses the same field to determine the proportion of the price that is applicable to the item.
    • setBandField

      public void setBandField(BandField bandField)
      The BandField used to calculate the fulfillment price. This is recorded for business logic like prorating the fulfillment price to items to ensure that proration uses the same field to determine the proportion of the price that is applicable to the item.