Package org.ametys.web.parameters.view
Class ContentViewParametersManager
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.web.parameters.view.ContentViewParametersManager
- All Implemented Interfaces:
LogEnabled
,Disposable
,Initializable
,Component
,Contextualizable
,Serviceable
public class ContentViewParametersManager
extends AbstractLogEnabled
implements Component, Serviceable, Contextualizable, Initializable, Disposable
Manager for content view parameters
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Class representing a content view parameters reloader -
Field Summary
Modifier and TypeFieldDescriptionprotected ContentTypeExtensionPoint
The content type extension pointprotected Context
The avalon contextprotected FileReloaderUtils
The file reloader utilsprotected ServiceManager
The service managerprotected AmetysObjectResolver
The ametys object resolverprotected org.ametys.web.parameters.view.ContentViewParametersManager.SkinsContentViewParameters
The object representing the view parameters of the different content type by skinprotected ViewAndParametersParser
The view and parameters parserprotected ModelItemTypeExtensionPoint
The view parameter type extension pointprotected ViewParametersManager
The view parameters managerstatic final String
Avalon Role -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Optional<ViewParametersModel>
_configureViewParameters
(Configuration paramConfiguration, String viewParametersId, String plugin, String catalog) Parse content view parameters from the configurationvoid
contextualize
(Context context) void
dispose()
getViewParameters
(String skinId, String contentTypeId, String viewName) Get view parameters for a content typevoid
void
service
(ServiceManager manager) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
ROLE
Avalon Role -
_fileReloaderUtils
The file reloader utils -
_viewParametersEP
The view parameter type extension point -
_viewAndParametersParser
The view and parameters parser -
_resolver
The ametys object resolver -
_context
The avalon context -
_manager
The service manager -
_contentTypeEP
The content type extension point -
_skinsContentViewParameters
protected org.ametys.web.parameters.view.ContentViewParametersManager.SkinsContentViewParameters _skinsContentViewParametersThe object representing the view parameters of the different content type by skin -
_viewParametersManager
The view parameters manager
-
-
Constructor Details
-
ContentViewParametersManager
public ContentViewParametersManager()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
contextualize
- Specified by:
contextualize
in interfaceContextualizable
- Throws:
ContextException
-
initialize
- Specified by:
initialize
in interfaceInitializable
- Throws:
Exception
-
getViewParameters
public Optional<ViewParametersModel> getViewParameters(String skinId, String contentTypeId, String viewName) Get view parameters for a content type- Parameters:
skinId
- the skin idcontentTypeId
- the content type idviewName
- the view name- Returns:
- the view parameters
-
_configureViewParameters
protected Optional<ViewParametersModel> _configureViewParameters(Configuration paramConfiguration, String viewParametersId, String plugin, String catalog) throws ConfigurationException Parse content view parameters from the configuration- Parameters:
paramConfiguration
- the configurationviewParametersId
- the view parameters idplugin
- the plugincatalog
- the catalog- Returns:
- the view parameters
- Throws:
ConfigurationException
- if a configuration error occurred
-
dispose
- Specified by:
dispose
in interfaceDisposable
-