Class AbstractStructuredContentServiceExtensionHandler
java.lang.Object
org.broadleafcommerce.common.extension.AbstractExtensionHandler
org.broadleafcommerce.cms.structure.service.AbstractStructuredContentServiceExtensionHandler
- All Implemented Interfaces:
StructuredContentServiceExtensionHandler
,ExtensionHandler
public class AbstractStructuredContentServiceExtensionHandler
extends AbstractExtensionHandler
implements StructuredContentServiceExtensionHandler
Extension handler for the
StructuredContentService
- Author:
- bpolster
-
Field Summary
Fields inherited from class org.broadleafcommerce.common.extension.AbstractExtensionHandler
enabled, priority
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionmodifyStructuredContentDtoList
(List<StructuredContentDTO> structuredContentList, ExtensionResultHolder resultHolder) Allows an extension handler to modify the list of structured content items.populateAdditionalStructuredContentFields
(StructuredContent sc, StructuredContentDTO dto, boolean secure) Further modifies the fields when parsing aStructuredContent
into aStructuredContentDTO
.Methods inherited from class org.broadleafcommerce.common.extension.AbstractExtensionHandler
getPriority, isEnabled, setEnabled, setPriority
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.broadleafcommerce.common.extension.ExtensionHandler
getPriority, isEnabled
-
Constructor Details
-
AbstractStructuredContentServiceExtensionHandler
public AbstractStructuredContentServiceExtensionHandler()
-
-
Method Details
-
populateAdditionalStructuredContentFields
public ExtensionResultStatusType populateAdditionalStructuredContentFields(StructuredContent sc, StructuredContentDTO dto, boolean secure) Description copied from interface:StructuredContentServiceExtensionHandler
Further modifies the fields when parsing aStructuredContent
into aStructuredContentDTO
. This method will be invoked at the end ofStructuredContentServiceImpl.buildFieldValues(StructuredContent, StructuredContentDTO, boolean)
.Note that even though this method should return an
ExtensionResultStatusType
, modifications should be made to theStructuredContentDTO
by using information from theStructuredContent
.- Specified by:
populateAdditionalStructuredContentFields
in interfaceStructuredContentServiceExtensionHandler
- Parameters:
sc
- theStructuredContent
that should further be wrapped into the dtodto
- the DTO that has already been mostly populated by Broadleaf. At this stage, this parameter will have all of the properties from the defaultStructuredContentDTO
already parsedsecure
- whether or not the request is secure- Returns:
- the result of executing this extension handler
-
modifyStructuredContentDtoList
public ExtensionResultStatusType modifyStructuredContentDtoList(List<StructuredContentDTO> structuredContentList, ExtensionResultHolder resultHolder) Description copied from interface:StructuredContentServiceExtensionHandler
Allows an extension handler to modify the list of structured content items. For example to alter the order of the passed in list.The
ExtensionResultHolder
if non null should contain a replacement list to use.- Specified by:
modifyStructuredContentDtoList
in interfaceStructuredContentServiceExtensionHandler
- Returns:
-