Class MediaMigrationStrategy
- java.lang.Object
-
- de.hybris.platform.jobs.maintenance.impl.MediaMigrationStrategy
-
- All Implemented Interfaces:
MaintenanceCleanupStrategy<MediaModel,MediaFolderStructureMigrationCronJobModel>
public class MediaMigrationStrategy extends java.lang.Object implements MaintenanceCleanupStrategy<MediaModel,MediaFolderStructureMigrationCronJobModel>
Strategy which migrates structure of files forMediaFolderconfigured inMediaFolderStructureMigrationCronJobModelafter changing folder configuration.
-
-
Constructor Summary
Constructors Constructor Description MediaMigrationStrategy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FlexibleSearchQuerycreateFetchQuery(MediaFolderStructureMigrationCronJobModel cjm)Implement and return aFlexibleSearchQueryobject here which searches for the items to be removed.voidprocess(java.util.List<MediaModel> elements)Based on the givenFlexibleSearchQueryofMaintenanceCleanupStrategy.createFetchQuery(CronJobModel)the job pages through the results and with each sublist (contains the concrete instances of the items) of the large result this method is called.voidrelocateMediaData(MediaModel media)voidsetMediaService(MediaService mediaService)
-
-
-
Method Detail
-
createFetchQuery
public FlexibleSearchQuery createFetchQuery(MediaFolderStructureMigrationCronJobModel cjm)
Description copied from interface:MaintenanceCleanupStrategyImplement and return aFlexibleSearchQueryobject here which searches for the items to be removed.- Specified by:
createFetchQueryin interfaceMaintenanceCleanupStrategy<MediaModel,MediaFolderStructureMigrationCronJobModel>
-
process
public void process(java.util.List<MediaModel> elements)
Description copied from interface:MaintenanceCleanupStrategyBased on the givenFlexibleSearchQueryofMaintenanceCleanupStrategy.createFetchQuery(CronJobModel)the job pages through the results and with each sublist (contains the concrete instances of the items) of the large result this method is called. Implement here the remove logic for each item element.- Specified by:
processin interfaceMaintenanceCleanupStrategy<MediaModel,MediaFolderStructureMigrationCronJobModel>
-
relocateMediaData
public void relocateMediaData(MediaModel media)
-
setMediaService
public void setMediaService(MediaService mediaService)
-
-