Class DefaultAbstractBundleComponentEditableChecker<O extends AbstractOrderModel>
java.lang.Object
de.hybris.platform.configurablebundleservices.bundle.impl.DefaultAbstractBundleComponentEditableChecker<O>
- All Implemented Interfaces:
AbstractBundleComponentEditableChecker<O>
- Direct Known Subclasses:
AutoPickBundleComponentEditableChecker,DefaultCartBundleComponentEditableChecker
public abstract class DefaultAbstractBundleComponentEditableChecker<O extends AbstractOrderModel>
extends Object
implements AbstractBundleComponentEditableChecker<O>
Default implementation of the
AbstractBundleComponentEditableChecker-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbundleTemplatesToGroupNumbers(EntryGroup rootGroup, Collection<BundleTemplateModel> components) protected voidcheckComponentIsLeaf(BundleTemplateModel bundleTemplate) protected EntryGroupServicebooleanisAutoPickComponent(BundleTemplateModel bundleTemplate) Checks ifBundleTemplateModelhas a selection criteria of auto pick type.booleanisRequiredDependencyMet(O order, BundleTemplateModel bundleTemplate, Integer entryGroupNumber) Checks if the selection dependency of the given componentbundleTemplatein given bundlebundleTemplateandorderis fulfilled.voidsetEntryGroupService(EntryGroupService entryGroupService)
-
Constructor Details
-
DefaultAbstractBundleComponentEditableChecker
public DefaultAbstractBundleComponentEditableChecker()
-
-
Method Details
-
isAutoPickComponent
Description copied from interface:AbstractBundleComponentEditableCheckerChecks ifBundleTemplateModelhas a selection criteria of auto pick type.- Specified by:
isAutoPickComponentin interfaceAbstractBundleComponentEditableChecker<O extends AbstractOrderModel>- Returns:
trueif selection criteria has auto pick type, otherwisefalse
-
isRequiredDependencyMet
public boolean isRequiredDependencyMet(@Nonnull O order, @Nonnull BundleTemplateModel bundleTemplate, @Nonnull Integer entryGroupNumber) Description copied from interface:AbstractBundleComponentEditableCheckerChecks if the selection dependency of the given componentbundleTemplatein given bundlebundleTemplateandorderis fulfilled. Returns the result of that check instead of throwing an exception.- Specified by:
isRequiredDependencyMetin interfaceAbstractBundleComponentEditableChecker<O extends AbstractOrderModel>- Parameters:
order- the order specified bundle is a part ofbundleTemplate- the component to check selection dependency forentryGroupNumber- number of the entry group created from bundle template
-
bundleTemplatesToGroupNumbers
@Nonnull protected Set<Integer> bundleTemplatesToGroupNumbers(@Nonnull EntryGroup rootGroup, @Nonnull Collection<BundleTemplateModel> components) -
getPopulatedGroupNumbers
-
checkComponentIsLeaf
protected void checkComponentIsLeaf(@Nonnull BundleTemplateModel bundleTemplate) throws CommerceCartModificationException -
getEntryGroupService
-
setEntryGroupService
-