Class SkinDAO
java.lang.Object
org.ametys.plugins.skineditor.skin.SkinDAO
- All Implemented Interfaces:
Component
,Serviceable
DAO for files and folders inside a skin directory
-
Field Summary
Modifier and TypeFieldDescriptionprotected SkinLockManager
The lock managerprotected SkinEditionHelper
The skin edition helperstatic final String
Constant for the id of right to edit teh current skinstatic final String
Constant for the id of right to edit all skinsstatic final String
The Avalon rolestatic final String
Constant for skin editor tool id -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetSkinsList
(String siteName) Get the list of available and modifiable skins for a siteOpen a skin for editingvoid
service
(ServiceManager manager) protected void
unlinkModel
(Path skinDir) Unlink model
-
Field Details
-
ROLE
The Avalon role -
EDIT_SKINS_RIGHT_ID
Constant for the id of right to edit all skins- See Also:
-
EDIT_CURRENT_SKIN_RIGHT_ID
Constant for the id of right to edit teh current skin- See Also:
-
SKIN_EDITOR_TOOL_ID
Constant for skin editor tool id- See Also:
-
_lockManager
The lock manager -
_skinHelper
The skin edition helper
-
-
Constructor Details
-
SkinDAO
public SkinDAO()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
getSkinsList
Get the list of available and modifiable skins for a site- Parameters:
siteName
- The site name- Returns:
- the list of skins
-
openSkin
Open a skin for editing- Parameters:
skinId
- the skin idmode
- the edition modeunlinkModel
- True to remove any existing change- Returns:
- the skin id
- Throws:
Exception
- if an error occurs during the skin opening process
-
unlinkModel
Unlink model- Parameters:
skinDir
- The skin directory- Throws:
IOException
- If an error occurred
-