org.opencms.synchronize
Interface I_CmsSynchronizeModification


public interface I_CmsSynchronizeModification

Defines methods which can be pluged into the syncronisation process between VFS and "real" FS.

Since:
6.0.0
Version:
$Revision: 1.10 $
Author:
Michael Emmerich

Method Summary
 void modifyFs(CmsObject cms, CmsResource vfsRes, java.io.File fsFile)
          Possibility to modify a resource after it has benn exported or updated to the FS.
 void modifyVfs(CmsObject cms, CmsResource vfsRes, java.io.File fsFile)
          Possibility to modify a resource after it has been imported or updated into the VFS.
 java.lang.String translate(CmsObject cms, java.lang.String resName)
          Translates the resource name.
 

Method Detail

modifyFs

void modifyFs(CmsObject cms,
              CmsResource vfsRes,
              java.io.File fsFile)
              throws CmsSynchronizeException
Possibility to modify a resource after it has benn exported or updated to the FS.

Parameters:
cms - the current CmsObject
vfsRes - the resource in the VFS
fsFile - the resource in the FS
Throws:
CmsSynchronizeException - if something goes wrong

modifyVfs

void modifyVfs(CmsObject cms,
               CmsResource vfsRes,
               java.io.File fsFile)
               throws CmsSynchronizeException
Possibility to modify a resource after it has been imported or updated into the VFS.

Parameters:
cms - the current CmsObject
vfsRes - the resource in the VFS
fsFile - the resource in the FS
Throws:
CmsSynchronizeException - if something goes wrong

translate

java.lang.String translate(CmsObject cms,
                           java.lang.String resName)
                           throws CmsSynchronizeException
Translates the resource name.

This is nescessary since the server FS does allow different naming conventions than the VFS. If no special translation is required and the default OpenCms FS-VFS translation should be used, null must be returned.

Parameters:
cms - the current CmsObject
resName - the resource name to be translated
Returns:
the translated resource name or null
Throws:
CmsSynchronizeException - if something goes wrong