Class ExternalCartProvider
java.lang.Object
com.broadleafcommerce.orderoperation.service.provider.external.AbstractExternalProvider
com.broadleafcommerce.orderoperation.service.provider.external.ExternalCartProvider
- All Implemented Interfaces:
CartProvider
-
Field Summary
Fields inherited from class com.broadleafcommerce.orderoperation.service.provider.external.AbstractExternalProvider
ENTITY_NOT_FOUND, RSQL_FILTER_PARAM
-
Constructor Summary
ConstructorDescriptionExternalCartProvider
(org.springframework.web.reactive.function.client.WebClient webClient, com.fasterxml.jackson.databind.ObjectMapper objectMapper, com.broadleafcommerce.common.extension.TypeFactory typeFactory) -
Method Summary
Modifier and TypeMethodDescriptionService client to use when interacting with the cart service.List<com.broadleafcommerce.cart.client.domain.CartItem>
readCartItemsForCart
(String cartItemLink, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Read cart items for a cart with the provided cart item linkList<com.broadleafcommerce.cart.client.domain.FulfillmentGroup>
readFulfillmentGroupsForCart
(String fulfillmentGroupLink, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Read fulfillment groups for a cart with the provided fulfillment group link.void
setServiceClient
(String serviceClient) Service client to use when interacting with the cart service.Methods inherited from class com.broadleafcommerce.orderoperation.service.provider.external.AbstractExternalProvider
buildNotFoundException, executeRequest, getHeaders, getObjectMapper, getTypeFactory, getWebClient, isEntityNotFound, pageableToParams
-
Field Details
-
CART_CLIENT_ID
Deprecated.- See Also:
-
-
Constructor Details
-
ExternalCartProvider
public ExternalCartProvider(org.springframework.web.reactive.function.client.WebClient webClient, com.fasterxml.jackson.databind.ObjectMapper objectMapper, com.broadleafcommerce.common.extension.TypeFactory typeFactory)
-
-
Method Details
-
readCartItemsForCart
public List<com.broadleafcommerce.cart.client.domain.CartItem> readCartItemsForCart(String cartItemLink, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Description copied from interface:CartProvider
Read cart items for a cart with the provided cart item link- Specified by:
readCartItemsForCart
in interfaceCartProvider
- Parameters:
cartItemLink
- The cart item linkcontextInfo
- The context- Returns:
- A list of cart items
-
readFulfillmentGroupsForCart
public List<com.broadleafcommerce.cart.client.domain.FulfillmentGroup> readFulfillmentGroupsForCart(String fulfillmentGroupLink, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Description copied from interface:CartProvider
Read fulfillment groups for a cart with the provided fulfillment group link.- Specified by:
readFulfillmentGroupsForCart
in interfaceCartProvider
- Parameters:
fulfillmentGroupLink
- The fulfillment group linkcontextInfo
- The context- Returns:
- A list of fulfillment groups
-
getServiceClient
Service client to use when interacting with the cart service. Default is "orderopsclient" -
setServiceClient
Service client to use when interacting with the cart service. Default is "orderopsclient"
-
getServiceClient()