|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface FulfillmentPricingProvider
Main extension interface to allow third-party integrations to respond to fulfillment pricing
FulfillmentPricingService}, {@link FulfillmentGroupPricingActivity}| Method Summary | |
|---|---|
FulfillmentGroup |
calculateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup)
Calculates the total cost for this FulfillmentGroup. |
boolean |
canCalculateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup,
FulfillmentOption option)
Whether or not this processor can provide a cost calculate for the given FulfillmentGroup and the given FulfillmentOption. |
FulfillmentEstimationResponse |
estimateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup,
Set<FulfillmentOption> options)
Estimates the cost for the fulfilling the given fulfillment group Estimates the cost for the fulfilling the given fulfillment group with the given options. |
| Method Detail |
|---|
FulfillmentGroup calculateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup)
throws FulfillmentPriceException
FulfillmentGroup.getFulfillmentOption(). This method is invoked
during the pricing workflow and will only be called if canCalculateCostForFulfillmentGroup(FulfillmentGroup, FulfillmentOption)
returns true. This should call FulfillmentGroup.setShippingPrice(org.broadleafcommerce.common.money.Money) to
set the shipping price on fulfillmentGroup
fulfillmentGroup - - the FulfillmentGroup to calculate costs for
FulfillmentGroup with correct pricing. This is typically fulfillmentGroup after it
has been modified
FulfillmentPriceException
boolean canCalculateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup,
FulfillmentOption option)
fulfillmentGroup - option - - the candidate option a user might select based on the estimate
FulfillmentPricingService}, {@link FulfillmentOption}
FulfillmentEstimationResponse estimateCostForFulfillmentGroup(FulfillmentGroup fulfillmentGroup,
Set<FulfillmentOption> options)
throws FulfillmentPriceException
canCalculateCostForFulfillmentGroup(org.broadleafcommerce.core.order.domain.FulfillmentGroup, org.broadleafcommerce.core.order.domain.FulfillmentOption)
to return true. This method may return null or it may return a non-null response with an empty map, indicating that no price estimate was available for the options given. This
method SHOULD NOT throw an exception if it encounters a FulfillmentOption that it can not price. It should simply ignore that option.
fulfillmentGroup - - the group to estimate fulfillment costs foroptions - - the candidate options that a user might select
calculateCostForFulfillmentGroup(FulfillmentGroup) is invoked during the pricing workflow
FulfillmentPriceExceptionFulfillmentPricingService}, {@link FulfillmentOption}
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||