@Component public final class WebCmsPageImporter extends AbstractWebCmsAssetImporter<WebCmsPage>
LOG| Constructor and Description |
|---|
WebCmsPageImporter() |
| Modifier and Type | Method and Description |
|---|---|
protected WebCmsPage |
createDto(WebCmsDataEntry data,
WebCmsPage itemToUpdate,
WebCmsDataAction action,
Map<String,Object> dataValues)
Create a DTO object for either a new instance or an existing instance.
|
protected WebCmsPage |
getExistingEntity(String entryKey,
WebCmsDataEntry data,
WebCmsDomain domain)
If no asset has been found by the unique asset key and domain combination (or no asset key was defined), this method will be called with the entry key.
|
protected WebCmsPage |
prepareForSaving(WebCmsPage itemToBeSaved,
WebCmsDataEntry data)
Override if you want to post process an item before saving.
|
protected void |
validate(WebCmsPage itemToBeSaved,
org.springframework.validation.Errors errors)
Perform some custom validation on the item to be saved.
|
deleteInstance, retrieveExistingInstance, saveDto, setAssetRepository, supports, validateObjectIdaddForceUpdateProperty, applyDataValues, importData, resolveAction, retrieveDomainForDataEntry, setPropertyDataImportService, validateForSavingprotected WebCmsPage createDto(WebCmsDataEntry data, WebCmsPage itemToUpdate, WebCmsDataAction action, Map<String,Object> dataValues)
AbstractWebCmsDataImporternull a new instance should be created.
Note that the DTO should not apply the data entry values yet, but the data entry
can be used to determine the initial type of instance that needs to be created.
If the DTO is null, the import will be skipped but properties will still be called.createDto in class AbstractWebCmsDataImporter<WebCmsPage,WebCmsPage>data - entryitemToUpdate - instance or null if a new instance should be createdaction - purpose for which the DTO should be created (create, delete or replace)dataValues - modifiable collection of the data values that will be applied afterwardsprotected WebCmsPage prepareForSaving(WebCmsPage itemToBeSaved, WebCmsDataEntry data)
AbstractWebCmsDataImporterprepareForSaving in class AbstractWebCmsDataImporter<WebCmsPage,WebCmsPage>itemToBeSaved - original item to be saveddata - that was used to build the itemprotected WebCmsPage getExistingEntity(String entryKey, WebCmsDataEntry data, WebCmsDomain domain)
AbstractWebCmsAssetImportergetExistingEntity in class AbstractWebCmsAssetImporter<WebCmsPage>entryKey - for the assetdata - for he assetdomain - for the assetprotected void validate(WebCmsPage itemToBeSaved, org.springframework.validation.Errors errors)
AbstractWebCmsDataImportervalidate in class AbstractWebCmsDataImporter<WebCmsPage,WebCmsPage>itemToBeSaved - item to be savederrors - collection to add validation errors toCopyright © 2020. All rights reserved.