Class CPQDefaultCartService

  • All Implemented Interfaces:
    CartCheckoutBaseService, CartService, CPQCartService

    public class CPQDefaultCartService
    extends DefaultCartService
    implements CPQCartService
    Basic cart functions for SAP synchronous order management. In this case, the cart will be created in the back end session, it does not touch the hybris persistence.
    The class synchronizes accesses to the BOL object representing the cart, as this is not thread safe. Multi-threaded accesses can happen although we use request sequencing, since also filters might call cart facades.
    • Constructor Detail

      • CPQDefaultCartService

        public CPQDefaultCartService()
    • Method Detail

      • addConfigurationToCart

        public java.lang.String addConfigurationToCart​(ConfigModel configModel)
        Description copied from interface: CPQCartService
        Adds a new configuration to the cart. A new item will be created, based on the root instance of the config model
        Specified by:
        addConfigurationToCart in interface CPQCartService
        Parameters:
        configModel - Configutation model, which will be added to the cart
        Returns:
        Key of new item
      • updateConfigurationInCart

        public java.lang.String updateConfigurationInCart​(java.lang.String key,
                                                          ConfigModel configModel)
        Description copied from interface: CPQCartService
        Updates the configuration attached to an item
        Specified by:
        updateConfigurationInCart in interface CPQCartService
        Parameters:
        key - Key of existing item
        configModel - Configuration
        Returns:
        Key of updated item
      • getItemByKey

        public Item getItemByKey​(java.lang.String itemKey)
        Description copied from interface: CPQCartService
        Does an item exist with a given key?
        Specified by:
        getItemByKey in interface CPQCartService
        Parameters:
        itemKey - key for the item.
        Returns:
        Does item exist for the item key?