Package org.ametys.skinfactory.actions
Class AbstractSkinAction
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.acting.AbstractAction
org.apache.cocoon.acting.ServiceableAction
org.ametys.skinfactory.actions.AbstractSkinAction
- All Implemented Interfaces:
Component,LogEnabled,Serviceable,Action
Abstract class for manipulating skin directory
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ContextThe cocoon contextprotected SkinLockManagerThe lock managerprotected SkinModelsManagerThe models managerprotected SiteManagerThe sites managerprotected SkinFactoryComponentThe skin factory componentprotected SkinEditionHelperThe skin edition helperprotected SkinsManagerThe skin managerprotected UserManagerThe users managerprotected CurrentUserProviderThe user providerstatic final StringConstant for skin editor tool idFields inherited from class org.apache.cocoon.acting.ServiceableAction
managerFields inherited from class org.apache.cocoon.acting.AbstractAction
EMPTY_MAP -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanDetermines the skin directory is locked.protected booleancheckModelExists(Request request, String modelName) Determines if the model still existsvoidservice(ServiceManager smanager) Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Field Details
-
SKIN_FACTORY_TOOL_ID
Constant for skin editor tool id- See Also:
-
_cocoonContext
The cocoon context -
_userProvider
The user provider -
_siteManager
The sites manager -
_skinFactoryManager
The skin factory component -
_modelsManager
The models manager -
_lockManager
The lock manager -
_skinHelper
The skin edition helper -
_skinsManager
The skin manager -
_userManager
The users manager
-
-
Constructor Details
-
AbstractSkinAction
public AbstractSkinAction()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Overrides:
servicein classServiceableAction- Throws:
ServiceException
-
checkLock
Determines the skin directory is locked. If no, the lock owner is set in JSON map request attribute- Parameters:
request- The requestskinDir- The skin directory- Returns:
- <code>true</code> if the current user can write.
- Throws:
IOException- if an exception occurs while manipulating the skin directory
-
checkModelExists
Determines if the model still exists- Parameters:
request- The requestmodelName- The model name- Returns:
trueif the model still exists.
-