Class BundleSelectionCriteriaAddToCartMethodHook
java.lang.Object
de.hybris.platform.configurablebundleservices.order.hook.BundleSelectionCriteriaAddToCartMethodHook
- All Implemented Interfaces:
CommerceAddToCartMethodHook
public class BundleSelectionCriteriaAddToCartMethodHook
extends Object
implements CommerceAddToCartMethodHook
A hook that limits amount of particular products in single bundle.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidafterAddToCart(CommerceCartParameter parameters, CommerceCartModification result) Execute custom logic after adding product to cartvoidbeforeAddToCart(CommerceCartParameter parameter) Execute custom logic before adding product to cartprotected BundleTemplateServiceprotected L10NServiceprotected longgetTotalQuantityInBundle(CartModel cart, Integer entryGroupNumber) voidsetBundleTemplateService(BundleTemplateService bundleTemplateService) voidsetL10NService(L10NService l10NService)
-
Constructor Details
-
BundleSelectionCriteriaAddToCartMethodHook
public BundleSelectionCriteriaAddToCartMethodHook()
-
-
Method Details
-
beforeAddToCart
public void beforeAddToCart(CommerceCartParameter parameter) throws CommerceCartModificationException Description copied from interface:CommerceAddToCartMethodHookExecute custom logic before adding product to cart- Specified by:
beforeAddToCartin interfaceCommerceAddToCartMethodHook- Parameters:
parameter- A parameter object- Throws:
CommerceCartModificationException
-
getTotalQuantityInBundle
-
afterAddToCart
public void afterAddToCart(CommerceCartParameter parameters, CommerceCartModification result) throws CommerceCartModificationException Description copied from interface:CommerceAddToCartMethodHookExecute custom logic after adding product to cart- Specified by:
afterAddToCartin interfaceCommerceAddToCartMethodHook- Parameters:
parameters- A parameter objectresult- A return value of addToCart method- Throws:
CommerceCartModificationException
-
getL10NService
-
setL10NService
-
getBundleTemplateService
-
setBundleTemplateService
-