Package org.ametys.odf.catalog
Class TranslationUpdater
- java.lang.Object
- 
- org.ametys.odf.catalog.TranslationUpdater
 
- 
- All Implemented Interfaces:
- CopyCatalogUpdater,- Serviceable
 
 public class TranslationUpdater extends Object implements CopyCatalogUpdater, Serviceable This updater updates the translations of created contents after the full catalog copy
- 
- 
Field SummaryFields Modifier and Type Field Description private AmetysObjectResolver_resolver
 - 
Constructor SummaryConstructors Constructor Description TranslationUpdater()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void_setTranslations(Map<String,String> copiedContents)Set the translationsvoidservice(ServiceManager manager)voidupdateContent(String initialCatalogName, String newCatalogName, Program initalContent, Program createdContent)Update content during copy of a catalog.voidupdateContents(String initialCatalogName, String newCatalogName, Map<String,String> copiedPrograms, Map<String,String> copiedSubPrograms, Map<String,String> copiedContainers, Map<String,String> copiedCourseLists, Map<String,String> copiedCourses, Map<String,String> copiedCourseParts)Update contents after the full copy of a catalog.
 
- 
- 
- 
Field Detail- 
_resolverprivate AmetysObjectResolver _resolver 
 
- 
 - 
Constructor Detail- 
TranslationUpdaterpublic TranslationUpdater() 
 
- 
 - 
Method Detail- 
servicepublic void service(ServiceManager manager) throws ServiceException - Specified by:
- servicein interface- Serviceable
- Throws:
- ServiceException
 
 - 
updateContentpublic void updateContent(String initialCatalogName, String newCatalogName, Program initalContent, Program createdContent) Description copied from interface:CopyCatalogUpdaterUpdate content during copy of a catalog. Implements this method when you do not need to wait for the full copy of the catalog.- Specified by:
- updateContentin interface- CopyCatalogUpdater
- Parameters:
- initialCatalogName- the name of initial catalog
- newCatalogName- the name of new catalog
- initalContent- the initial program
- createdContent- the created program
 
 - 
updateContentspublic void updateContents(String initialCatalogName, String newCatalogName, Map<String,String> copiedPrograms, Map<String,String> copiedSubPrograms, Map<String,String> copiedContainers, Map<String,String> copiedCourseLists, Map<String,String> copiedCourses, Map<String,String> copiedCourseParts) Description copied from interface:CopyCatalogUpdaterUpdate contents after the full copy of a catalog. Implements this method when you need to do some stuff when all contents have been copied.- Specified by:
- updateContentsin interface- CopyCatalogUpdater
- Parameters:
- initialCatalogName- the name of initial catalog
- newCatalogName- the name of new catalog
- copiedPrograms- the id of initial programs with their copied content
- copiedSubPrograms- the id of initial subprograms with their copied content
- copiedContainers- the id of initial containers with their copied content
- copiedCourseLists- the id of initial course lists with their copied content
- copiedCourses- the id of initial courses with their copied content
- copiedCourseParts- the id of initial course parts with their copied content
 
 - 
_setTranslationsprotected void _setTranslations(Map<String,String> copiedContents) Set the translations- Parameters:
- copiedContents- Contents to update
 
 
- 
 
-