Package org.ametys.cms.content
Class GetWrapperContextAction
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.acting.AbstractAction
org.ametys.cms.content.GetWrapperContextAction
- All Implemented Interfaces:
Component
,LogEnabled
,Serviceable
,Action
- Direct Known Subclasses:
GetWrapperContextAction
This action export the wrapping XSLT URI.
Content negociation will be performed with the given URI: if content.xsl is asked, content-[contentType].xsl will be looked up first. This action needs the parameter
Content negociation will be performed with the given URI: if content.xsl is asked, content-[contentType].xsl will be looked up first. This action needs the parameter
path
pointing the default path to the XSL.-
Field Summary
Modifier and TypeFieldDescriptionprotected ContentTypesHelper
The content types helperprotected SourceResolver
The source resolverFields inherited from class org.apache.cocoon.acting.AbstractAction
EMPTY_MAP
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionact
(Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters parameters) getSourceURIs
(Request request, String requestedURI) Get the source URI for wrapped contentprotected String
getWrapperURI
(Request request, String uri) Compute the wrapping URI for the current Content.void
service
(ServiceManager manager) Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Field Details
-
_srcResolver
The source resolver -
_contentTypesHelper
The content types helper
-
-
Constructor Details
-
GetWrapperContextAction
public GetWrapperContextAction()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
act
public Map<String,String> act(Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters parameters) throws Exception -
getWrapperURI
Compute the wrapping URI for the current Content.- Parameters:
request
- the current Request.uri
- the default uri.- Returns:
- the wrapper XSLT URI.
- Throws:
IOException
- if an error occurs whuile resolving Sources.
-
getSourceURIs
Get the source URI for wrapped content- Parameters:
request
- The requestrequestedURI
- The requested URI- Returns:
- the wrapped URI
-