public class CmsSynchronizeSettings extends java.lang.Object implements java.io.Serializable
Constructor and Description |
---|
CmsSynchronizeSettings()
Empty constructor, called from the configuration.
|
Modifier and Type | Method and Description |
---|---|
void |
checkValues(CmsObject cms)
Performs a check if the values that have been set are valid.
|
java.lang.String |
getDestinationPathInRfs()
Returns the destination path of the synchronization in the "real" file system.
|
java.util.List<java.lang.String> |
getSourceListInVfs()
Returns the source path list of the synchronization in the OpenCms VFS.
|
boolean |
isEnabled()
Returns the enabled flag which indicates if this synchronize settings are enabled or not.
|
boolean |
isSyncEnabled()
Returns
true if the synchonization is enabled. |
protected java.util.List<java.lang.String> |
optimizeSourceList(java.util.List<java.lang.String> sourceListInVfs)
Optimizes the list of VFS source files by removing all resources that
have a parent resource already included in the list.
|
void |
setDestinationPathInRfs(java.lang.String destinationPathInRfs)
Sets the destination path of the synchronization in the "real" file system.
|
void |
setEnabled(boolean enabled)
Sets the enabled flag which indicates if this synchronize settings are enabled or not.
|
void |
setSourceListInVfs(java.util.List<java.lang.String> sourceListInVfs)
Sets the source path list of the synchronization in the OpenCms VFS.
|
java.lang.String |
toString() |
public CmsSynchronizeSettings()
public void checkValues(CmsObject cms) throws CmsException
cms
- the current users OpenCms contextCmsException
- in case the values are not validpublic java.lang.String getDestinationPathInRfs()
public java.util.List<java.lang.String> getSourceListInVfs()
The objects in the list are of type
.String
public boolean isEnabled()
public boolean isSyncEnabled()
true
if the synchonization is enabled.The synchonization is enabled if both source and destination path is set, and also the enabled flag is true.
true
if the synchonization is enabledprotected java.util.List<java.lang.String> optimizeSourceList(java.util.List<java.lang.String> sourceListInVfs)
sourceListInVfs
- the list of VFS resources to optimizepublic void setDestinationPathInRfs(java.lang.String destinationPathInRfs)
destinationPathInRfs
- the destination path of the synchronization in the "real" file system to setpublic void setEnabled(boolean enabled)
enabled
- the enabled flag to setpublic void setSourceListInVfs(java.util.List<java.lang.String> sourceListInVfs)
The objects in the list must be of type
.String
sourceListInVfs
- the source path list of the synchronization in the OpenCms VFS to setpublic java.lang.String toString()
toString
in class java.lang.Object
Object.toString()