Interface InventoryProvider
- All Known Implementing Classes:
ExternalInventoryProvider
public interface InventoryProvider
Provider for interfacing with operations involving inventory. Typically utilizes
WebClient
to make requests to an external REST API.- Since:
- Order Operation Service 2.1.0, Release Train 2.2.0
-
Method Summary
Modifier and TypeMethodDescriptionboolean
reserveInventory
(@NonNull com.broadleafcommerce.order.client.domain.Order order, @NonNull com.broadleafcommerce.order.client.domain.OrderFulfillment fulfillment, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Reserves inventory for the givenOrderFulfillment
.
-
Method Details
-
reserveInventory
boolean reserveInventory(@NonNull @NonNull com.broadleafcommerce.order.client.domain.Order order, @NonNull @NonNull com.broadleafcommerce.order.client.domain.OrderFulfillment fulfillment, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Reserves inventory for the givenOrderFulfillment
.- Parameters:
order
- the order associated to the fulfillmentfulfillment
- the fulfillment to reserve inventory forcontextInfo
- context information around sandbox and multitenant state.- Returns:
- true, if the inventory was successfully reserved
-