Class StructuredContentTypeCustomPersistenceHandler
java.lang.Object
org.broadleafcommerce.openadmin.server.service.handler.CustomPersistenceHandlerAdapter
org.broadleafcommerce.cms.admin.server.handler.StructuredContentTypeCustomPersistenceHandler
- All Implemented Interfaces:
CustomPersistenceHandler,DynamicEntityRetriever,org.springframework.core.Ordered
@Component("blStructuredContentTypeCustomPersistenceHandler")
public class StructuredContentTypeCustomPersistenceHandler
extends CustomPersistenceHandlerAdapter
implements DynamicEntityRetriever
Created by jfischer
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected DynamicFieldPersistenceHandlerHelperprotected jakarta.persistence.EntityManagerprotected AdminEntityServiceprotected StructuredContentServiceFields 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) Invoked whenStructuredContentis saved in order to fill out the dynamic form for the structured content typeprotected EntityaddOrUpdate(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) canHandleAdd(PersistencePackage persistencePackage) canHandleFetch(PersistencePackage persistencePackage) canHandleInspect(PersistencePackage persistencePackage) canHandleRemove(PersistencePackage persistencePackage) canHandleUpdate(PersistencePackage persistencePackage) fetch(PersistencePackage persistencePackage, CriteriaTransferObject cto, DynamicEntityDao dynamicEntityDao, RecordHelper helper) fetchDynamicEntity(Serializable root, List<String> dirtyFields, boolean includeId) fetchEntityBasedOnId(String structuredContentId, List<String> dirtyFields) inspect(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, InspectHelper helper) update(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) Invoked whenStructuredContentis saved in order to fill out the dynamic form for the structured content typeMethods inherited from class org.broadleafcommerce.openadmin.server.service.handler.CustomPersistenceHandlerAdapter
getClassForName, getMetadata, getOrder, getPolymorphicClasses, getResultSet, isAdornedListOperation, isAssignableFrom, isBasicOperation, isMapOperation, meetsCustomCriteria, remove, willHandleSecurity
-
Field Details
-
structuredContentService
-
dynamicFieldUtil
-
em
protected jakarta.persistence.EntityManager em -
service
-
-
Constructor Details
-
StructuredContentTypeCustomPersistenceHandler
public StructuredContentTypeCustomPersistenceHandler()
-
-
Method Details
-
canHandleFetch
- Specified by:
canHandleFetchin interfaceCustomPersistenceHandler- Overrides:
canHandleFetchin classCustomPersistenceHandlerAdapter
-
canHandleAdd
- Specified by:
canHandleAddin interfaceCustomPersistenceHandler- Overrides:
canHandleAddin classCustomPersistenceHandlerAdapter
-
canHandleInspect
- Specified by:
canHandleInspectin interfaceCustomPersistenceHandler- Overrides:
canHandleInspectin classCustomPersistenceHandlerAdapter
-
canHandleRemove
- Specified by:
canHandleRemovein interfaceCustomPersistenceHandler- Overrides:
canHandleRemovein classCustomPersistenceHandlerAdapter
-
canHandleUpdate
- Specified by:
canHandleUpdatein interfaceCustomPersistenceHandler- Overrides:
canHandleUpdatein classCustomPersistenceHandlerAdapter
-
inspect
public DynamicResultSet inspect(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, InspectHelper helper) throws org.broadleafcommerce.common.exception.ServiceException - Specified by:
inspectin interfaceCustomPersistenceHandler- Overrides:
inspectin classCustomPersistenceHandlerAdapter- Throws:
org.broadleafcommerce.common.exception.ServiceException
-
fetch
public DynamicResultSet fetch(PersistencePackage persistencePackage, CriteriaTransferObject cto, DynamicEntityDao dynamicEntityDao, RecordHelper helper) throws org.broadleafcommerce.common.exception.ServiceException - Specified by:
fetchin interfaceCustomPersistenceHandler- Overrides:
fetchin classCustomPersistenceHandlerAdapter- Throws:
org.broadleafcommerce.common.exception.ServiceException
-
fetchEntityBasedOnId
public Entity fetchEntityBasedOnId(String structuredContentId, List<String> dirtyFields) throws Exception - Specified by:
fetchEntityBasedOnIdin interfaceDynamicEntityRetriever- Throws:
Exception
-
getFieldContainerClassName
- Specified by:
getFieldContainerClassNamein interfaceDynamicEntityRetriever
-
fetchDynamicEntity
public Entity fetchDynamicEntity(Serializable root, List<String> dirtyFields, boolean includeId) throws Exception - Specified by:
fetchDynamicEntityin interfaceDynamicEntityRetriever- Throws:
Exception
-
update
public Entity update(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) throws org.broadleafcommerce.common.exception.ServiceException Invoked whenStructuredContentis saved in order to fill out the dynamic form for the structured content type- Specified by:
updatein interfaceCustomPersistenceHandler- Overrides:
updatein classCustomPersistenceHandlerAdapter- Throws:
org.broadleafcommerce.common.exception.ServiceException
-
add
public Entity add(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) throws org.broadleafcommerce.common.exception.ServiceException Invoked whenStructuredContentis saved in order to fill out the dynamic form for the structured content type- Specified by:
addin interfaceCustomPersistenceHandler- Overrides:
addin classCustomPersistenceHandlerAdapter- Throws:
org.broadleafcommerce.common.exception.ServiceException
-
addOrUpdate
protected Entity addOrUpdate(PersistencePackage persistencePackage, DynamicEntityDao dynamicEntityDao, RecordHelper helper) throws org.broadleafcommerce.common.exception.ServiceException - Throws:
org.broadleafcommerce.common.exception.ServiceException
-