Package org.ametys.web.content
Class GetPageAttachmentAction
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.acting.AbstractAction
org.apache.cocoon.acting.ServiceableAction
org.ametys.web.content.GetPageAttachmentAction
- All Implemented Interfaces:
Component,LogEnabled,Serviceable,Action
Get the page attachment uri from the id of a resource.
Tests if the current asked resource exists and it is an resource of a page.
- If the resource does not exist, an
ResourceNotFoundExceptionis thrown. - If the resource is not an resource of a page, an
AccessDeniedExceptionis thrown. - If the resource exists and is a page's attachment, redirect to the page attachment uri.
-
Field Summary
Fields 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 TypeMethodDescriptionact(Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters parameters) voidservice(ServiceManager smanager) Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Constructor Details
-
GetPageAttachmentAction
public GetPageAttachmentAction()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Overrides:
servicein classServiceableAction- Throws:
ServiceException
-
act
public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters parameters) throws Exception - Throws:
Exception
-