|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opencms.module.CmsModuleImportExportHandler
public class CmsModuleImportExportHandler
Import/export handler implementation for Cms modules.
| Constructor Summary | |
|---|---|
CmsModuleImportExportHandler()
Creates a new Cms module import/export handler. |
|
| Method Summary | |
|---|---|
void |
exportData(CmsObject cms,
I_CmsReport report)
Exports the data from the Cms. |
protected void |
finalize()
|
List |
getAdditionalResources()
Returns the VFS resources to be exported additionally with the module. |
String |
getDescription()
Returns the description of this import/export handler. |
String |
getFileName()
Returns the name of the export file in the real file system. |
String |
getModuleName()
Returns the (package) name of the module to be exported. |
List |
getResourcesAsList()
Returns the VFS resources to be exported additionally with the module as a list. |
void |
importData(CmsObject cms,
String importFile,
String importPath,
I_CmsReport report)
Imports the data into the Cms. |
boolean |
matches(Document manifest)
Checks, if this import/export handler matches with a specified manifest document of an import, so that it is able to import the data listed in the manifest document. |
static CmsModule |
readModuleFromImport(String importResource)
Reads a module object from an external file source. |
void |
setAdditionalResources(String[] resources)
Sets the VFS resources to be exported additionally with the module. |
void |
setDescription(String description)
Sets the description of this import/export handler. |
void |
setFileName(String fileName)
Sets the name of the export file in the real file system. |
void |
setModule(CmsModuleXmlHandler moduleHandler)
Will be called by the digester if a module was imported. |
void |
setModuleName(String moduleName)
Sets the (package) name of the module to be exported. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CmsModuleImportExportHandler()
| Method Detail |
|---|
public static CmsModule readModuleFromImport(String importResource)
throws CmsConfigurationException
importResource - the name of the input source
CmsConfigurationException - if the module could not be imported
public void exportData(CmsObject cms,
I_CmsReport report)
throws CmsConfigurationException,
CmsImportExportException,
CmsRoleViolationException
I_CmsImportExportHandler
exportData in interface I_CmsImportExportHandlercms - the current OpenCms context objectreport - a Cms report to print log messages
CmsConfigurationException - if a specified module to be exproted does not exist
CmsImportExportException - if operation was not successful
CmsRoleViolationException - if the current user has not the required roleI_CmsImportExportHandler.exportData(org.opencms.file.CmsObject, org.opencms.report.I_CmsReport)public List getAdditionalResources()
public String getDescription()
I_CmsImportExportHandlerThe description is useful to print some info about the purpose of this handler.
getDescription in interface I_CmsImportExportHandlerI_CmsImportExportHandler.getDescription()public String getFileName()
public String getModuleName()
public List getResourcesAsList()
public void importData(CmsObject cms,
String importFile,
String importPath,
I_CmsReport report)
throws CmsXmlException,
CmsImportExportException,
CmsRoleViolationException,
CmsException
I_CmsImportExportHandler
importData in interface I_CmsImportExportHandlercms - the current OpenCms context objectimportFile - the name (absolute path) of the resource (zipfile or folder) to be importedimportPath - the name (absolute path) of the destination folder in the Cms (if required)report - a Cms report to print log messages
CmsXmlException - if the manifest of the import could not be unmarshalled
CmsImportExportException - if operation was not successful
CmsRoleViolationException - if the current user has not the required role
CmsException - in case of errors accessing the VFSI_CmsImportExportHandler.importData(org.opencms.file.CmsObject, java.lang.String, java.lang.String, org.opencms.report.I_CmsReport)public boolean matches(Document manifest)
I_CmsImportExportHandler
matches in interface I_CmsImportExportHandlermanifest - the manifest.xml of the import as a dom4j XML document
I_CmsImportExportHandler.matches(org.dom4j.Document)public void setAdditionalResources(String[] resources)
resources - the VFS resources to be exported additionally with the modulepublic void setDescription(String description)
I_CmsImportExportHandlerThe description is useful to print some info about the purpose of this handler.
setDescription in interface I_CmsImportExportHandlerdescription - the description of this import/export handlerI_CmsImportExportHandler.setDescription(java.lang.String)public void setFileName(String fileName)
fileName - the name of the export file in the real file systempublic void setModule(CmsModuleXmlHandler moduleHandler)
moduleHandler - contains the imported modulepublic void setModuleName(String moduleName)
moduleName - the (package) name of the module to be exported
protected void finalize()
throws Throwable
finalize in class ObjectThrowableObject.finalize()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||