Package org.ametys.web.source
Class WebContentView
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.ametys.cms.source.DefaultContentView
org.ametys.web.source.WebContentView
- All Implemented Interfaces:
ContentView
,Contextualizable
,LogEnabled
,Serviceable
This implementation of a
ContentView
looks first in the directory skin://stylesheets/content/[cType]/[cType]-[view].[extension] then skin://stylesheets/content/[cType]/[cType].[extension] then defaults to DefaultContentView
.-
Field Summary
Fields inherited from class org.ametys.cms.source.DefaultContentView
_contentTypeEP, _contentTypesHelper, _context, _dynamicContentTypeDescriptorEP, _resolver
Fields inherited from interface org.ametys.cms.source.ContentView
ROLE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription_getDefaultSourceURIs
(String pluginName, String formatSuffix, String extension) Get the URIs of default stylesheets_getSourceURIsForContentTypeWithPlugin
(String pluginName, String contentTypeAlias, String contentTypeId, String view, String formatSuffix, String extension) Get source for a non dynamic content type, call _getSourceURIsForContentType() which call this method twice if necessary (with the alias and the real content type id)._getSourceURIsForDynamicContentType
(String contentTypeAlias, String view, String formatSuffix, String pluginName, String extension) get source for a dynamic content typevoid
service
(ServiceManager smanager) Methods inherited from class org.ametys.cms.source.DefaultContentView
_getDefaultSourceURIsForContentType, _getSourceURIs, _getSourceURIsForContentType, _getSourceURIsForSuperTypes, contextualize, getSource
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Constructor Details
-
WebContentView
public WebContentView()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classDefaultContentView
- Throws:
ServiceException
-
_getDefaultSourceURIs
protected List<String> _getDefaultSourceURIs(String pluginName, String formatSuffix, String extension) Description copied from class:DefaultContentView
Get the URIs of default stylesheets- Overrides:
_getDefaultSourceURIs
in classDefaultContentView
- Parameters:
pluginName
- The current plugin nameformatSuffix
- the format of the output (html, pdf, ...)extension
- the extension (xsl, xml, ...)- Returns:
- a list of URIs
-
_getSourceURIsForDynamicContentType
protected List<String> _getSourceURIsForDynamicContentType(String contentTypeAlias, String view, String formatSuffix, String pluginName, String extension) Description copied from class:DefaultContentView
get source for a dynamic content type- Overrides:
_getSourceURIsForDynamicContentType
in classDefaultContentView
- Parameters:
contentTypeAlias
- the content type alias for renderingview
- the content viewformatSuffix
- the format of the output (html, pdf, ...)pluginName
- the plugin nameextension
- the extension (xsl, xml, ...)- Returns:
- the list
-
_getSourceURIsForContentTypeWithPlugin
protected List<String> _getSourceURIsForContentTypeWithPlugin(String pluginName, String contentTypeAlias, String contentTypeId, String view, String formatSuffix, String extension) Description copied from class:DefaultContentView
Get source for a non dynamic content type, call _getSourceURIsForContentType() which call this method twice if necessary (with the alias and the real content type id).- Overrides:
_getSourceURIsForContentTypeWithPlugin
in classDefaultContentView
- Parameters:
pluginName
- the plugin name of the content typecontentTypeAlias
- the content type alias for renderingcontentTypeId
- the content type id used to build the URIsview
- the content viewformatSuffix
- the format of the output (html, pdf, ...)extension
- the extension (xsl, xml, ...)- Returns:
- the list
-