Class CmsModuleImportExportRepository


  • public class CmsModuleImportExportRepository
    extends java.lang.Object
    Class which manages import/export of modules from repositories configured in opencms-importexport.xml.

    • Method Detail

      • deleteModule

        public boolean deleteModule​(java.lang.String fileName)
                             throws CmsException
        Deletes the module corresponding to the given virtual module file name.

        Parameters:
        fileName - the file name
        Returns:
        true if the module could be deleted
        Throws:
        CmsException - if something goes wrong
      • getModuleFileNames

        public java.util.List<java.lang.String> getModuleFileNames()
        Gets the list of modules as file names.

        Returns:
        the list of modules as file names
      • getModuleLog

        public CmsModuleLog getModuleLog()
        Gets the object used to access the module log.

        Returns:
        the module log
      • importModule

        public void importModule​(java.lang.String name,
                                 byte[] content)
                          throws CmsException
        Imports module data.

        Parameters:
        name - the module file name
        content - the module ZIP file data
        Throws:
        CmsException - if something goes wrong
      • initialize

        public void initialize​(CmsObject adminCms)
        Initializes the CMS context.

        Parameters:
        adminCms - the admin CMS context