Package org.ametys.cms.source
Class ContentViewSourceFactory
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.cms.source.ContentViewSourceFactory
-
- All Implemented Interfaces:
Component,Contextualizable,LogEnabled,Serviceable,SourceFactory
public class ContentViewSourceFactory extends AbstractLogEnabled implements SourceFactory, Contextualizable, Serviceable
This factory looks for files in the current skin and fallback in the current plugin dir. Use: content-view:[view]://path_to_file Will first look in the skin of the current site in the sub-directory stylesheet/{contenttype} => skins/{skin}/stylesheets/{contenttype}/path_to_file And if the file does not exist will search in plugin:{currentPluginName}://path_to_file
-
-
Field Summary
-
Fields inherited from interface org.apache.excalibur.source.SourceFactory
ROLE
-
-
Constructor Summary
Constructors Constructor Description ContentViewSourceFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcontextualize(Context context)SourcegetSource(String location, Map parameters)voidrelease(Source source)voidservice(ServiceManager manager)-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Constructor Detail
-
ContentViewSourceFactory
public ContentViewSourceFactory()
-
-
Method Detail
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualizein interfaceContextualizable- Throws:
ContextException
-
getSource
public Source getSource(String location, Map parameters) throws IOException, MalformedURLException
- Specified by:
getSourcein interfaceSourceFactory- Throws:
IOExceptionMalformedURLException
-
release
public void release(Source source)
- Specified by:
releasein interfaceSourceFactory
-
-