Package org.ametys.odf.source
Class DefaultODFView
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.odf.source.DefaultODFView
- All Implemented Interfaces:
ODFViewSelector,LogEnabled,Serviceable
- Direct Known Subclasses:
ODFWebView
Default implementation of
ODFViewSelector.
First looks the wanted file in context://WEB-INF/stylesheets/path_to_file
If it's not present, it will look in the ODF plugin.-
Field Summary
FieldsFields inherited from interface org.ametys.odf.source.ODFViewSelector
ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription_getDefaultSourceURIs(String pluginName, String filePath) Get the default URIsgetLocations(String pluginName, String filePath) Returns the ordered list of URI to be tested to find the corresponding view.Get the file source for rendering a contentvoidservice(ServiceManager manager) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
_resolver
The source resolver
-
-
Constructor Details
-
DefaultODFView
public DefaultODFView()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
getSource
Description copied from interface:ODFViewSelectorGet the file source for rendering a content- Specified by:
getSourcein interfaceODFViewSelector- Parameters:
pluginName- the plugin namefilePath- the path of the file to retrieve- Returns:
- the file source
- Throws:
IOException- if the Source cannot be resolved
-
getLocations
Returns the ordered list of URI to be tested to find the corresponding view.- Parameters:
pluginName- the plugin namefilePath- the requested location.- Returns:
- a list of possible URIs for the resource.
-
_getDefaultSourceURIs
Get the default URIs- Parameters:
pluginName- The current plugin namefilePath- the requested location.- Returns:
- a list of URIs
-