Class ChildCategoriesCustomPersistenceHandler
java.lang.Object
org.broadleafcommerce.openadmin.server.service.handler.CustomPersistenceHandlerAdapter
org.broadleafcommerce.admin.server.service.handler.ChildCategoriesCustomPersistenceHandler
- All Implemented Interfaces:
CustomPersistenceHandler,org.springframework.core.Ordered
@Component("blChildCategoriesCustomPersistenceHandler")
public class ChildCategoriesCustomPersistenceHandler
extends CustomPersistenceHandlerAdapter
- Author:
- Jeff Fischer
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected static final Stringprotected static final Stringprotected CategoryDaoprotected org.broadleafcommerce.common.sandbox.SandBoxHelperprotected static final StringFields inherited from interface org.broadleafcommerce.openadmin.server.service.handler.CustomPersistenceHandler
DEFAULT_ORDERFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadd(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) protected voidaddCategoryLink(StringBuilder productLinks, String categoryName) canHandleAdd(PersistencePackage persistencePackage) protected voidvalidateChildCategories(Entity entity, Category category, Long id, StringBuilder categoryLinks) protected voidvalidateChildCategory(Entity entity) protected voidvalidateDuplicateChild(Entity entity) protected voidvalidateRecursiveRelationship(Entity entity) protected voidvalidateSelfLink(Entity entity) Methods inherited from class org.broadleafcommerce.openadmin.server.service.handler.CustomPersistenceHandlerAdapter
canHandleFetch, canHandleInspect, canHandleRemove, canHandleUpdate, fetch, getClassForName, getMetadata, getOrder, getPolymorphicClasses, getResultSet, inspect, isAdornedListOperation, isAssignableFrom, isBasicOperation, isMapOperation, meetsCustomCriteria, remove, update, willHandleSecurity
-
Field Details
-
ALL_CHILD_CATEGORY_XREFS
- See Also:
-
CATEGORY_ID
- See Also:
-
SUB_CATEGORY_ID
- See Also:
-
CATEGORY_SEPARATOR
- See Also:
-
categoryDao
-
sandBoxHelper
protected org.broadleafcommerce.common.sandbox.SandBoxHelper sandBoxHelper
-
-
Constructor Details
-
ChildCategoriesCustomPersistenceHandler
public ChildCategoriesCustomPersistenceHandler()
-
-
Method Details
-
canHandleAdd
- Specified by:
canHandleAddin interfaceCustomPersistenceHandler- Overrides:
canHandleAddin classCustomPersistenceHandlerAdapter
-
add
public Entity add(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) throws org.broadleafcommerce.common.exception.ServiceException - Specified by:
addin interfaceCustomPersistenceHandler- Overrides:
addin classCustomPersistenceHandlerAdapter- Throws:
org.broadleafcommerce.common.exception.ServiceException
-
validateChildCategory
- Throws:
ValidationException
-
validateSelfLink
- Throws:
ValidationException
-
validateDuplicateChild
- Throws:
ValidationException
-
validateRecursiveRelationship
- Throws:
ValidationException
-
validateChildCategories
protected void validateChildCategories(Entity entity, Category category, Long id, StringBuilder categoryLinks) throws ValidationException - Throws:
ValidationException
-
addCategoryLink
-