Package org.opencms.file.wrapper
Class CmsResourceWrapperSystemFolder
java.lang.Object
org.opencms.file.wrapper.A_CmsResourceWrapper
org.opencms.file.wrapper.CmsResourceWrapperSystemFolder
- All Implemented Interfaces:
I_CmsResourceWrapper
Adds the system folder to every root folder of target sites.
- Since:
- 6.5.6
-
Field Summary
Fields inherited from class org.opencms.file.wrapper.A_CmsResourceWrapper
m_isWrappedResource
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddResourcesToFolder
(CmsObject cms, String resourcename, CmsResourceFilter filter) Here it is possible to add additional (virtual) child resources to those already existing in the VFS.boolean
isWrappedResource
(CmsObject cms, CmsResource res) Is called to check if the given resource is handled by this wrapper.readResource
(CmsObject cms, String resourcename, CmsResourceFilter filter) Reads a resource from the VFS, using the specified resource filter.Methods inherited from class org.opencms.file.wrapper.A_CmsResourceWrapper
configure, copyResource, createResource, deleteResource, getLock, lockResource, moveResource, readFile, restoreLink, rewriteLink, unlockResource, wrapResource, writeFile
-
Constructor Details
-
CmsResourceWrapperSystemFolder
public CmsResourceWrapperSystemFolder()
-
-
Method Details
-
addResourcesToFolder
public List<CmsResource> addResourcesToFolder(CmsObject cms, String resourcename, CmsResourceFilter filter) throws CmsException Description copied from interface:I_CmsResourceWrapper
Here it is possible to add additional (virtual) child resources to those already existing in the VFS.- Specified by:
addResourcesToFolder
in interfaceI_CmsResourceWrapper
- Overrides:
addResourcesToFolder
in classA_CmsResourceWrapper
- Parameters:
cms
- the current users OpenCms contextresourcename
- the full path of the resource where to add the child resources forfilter
- the resource filter to use- Returns:
- a list of all additionaly child
sCmsResource
- Throws:
CmsException
- if something goes wrong- See Also:
-
isWrappedResource
Description copied from interface:I_CmsResourceWrapper
Is called to check if the given resource is handled by this wrapper.- Parameters:
cms
- the initialized CmsObjectres
- the resource to check- Returns:
- true if the resource will be handled by the wrapper otherwise false
- See Also:
-
readResource
public CmsResource readResource(CmsObject cms, String resourcename, CmsResourceFilter filter) throws CmsException Description copied from interface:I_CmsResourceWrapper
Reads a resource from the VFS, using the specified resource filter.First should be a check if the resourcename is handled by this resource wrapper.
It is possible that the path in the resourcename is a virtual path and so has to be translated into a valid path existing in the VFS to read the resource.
- Specified by:
readResource
in interfaceI_CmsResourceWrapper
- Overrides:
readResource
in classA_CmsResourceWrapper
- Parameters:
cms
- the current users OpenCms contextresourcename
- The name of the resource to read (full path)filter
- the resource filter to use while reading- Returns:
- the resource that was read or null if it could not be handled by this resource wrapper
- Throws:
CmsException
- if the resource could not be read for any reason- See Also:
-