Package org.ametys.core.resources
Class AbstractResourceHandlerProvider
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.core.resources.AbstractResourceHandlerProvider
-
- All Implemented Interfaces:
ResourceHandlerProvider
,LogEnabled
,Prioritizable
,Contextualizable
,Serviceable
- Direct Known Subclasses:
AbstractSimpleResourceHandlerProvider
,CompiledCssResourceHandlerProvider
,SassSourceMapResourceHandlerProvider
,VueJsResourceHandlerProvider
public abstract class AbstractResourceHandlerProvider extends AbstractLogEnabled implements ResourceHandlerProvider, Serviceable, Contextualizable
Abstract superclass forResourceHandlerProvider
for helpingResourceHandler
creation.
-
-
Field Summary
Fields Modifier and Type Field Description protected Context
_context
The application contextprotected ServiceManager
_manager
The service manager-
Fields inherited from interface org.ametys.core.resources.ResourceHandlerProvider
MAX_PRIORITY, MIN_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description AbstractResourceHandlerProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
contextualize(Context context)
void
service(ServiceManager manager)
protected ResourceHandler
setup(ResourceHandler handler)
Setup the handler right after its creation-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ametys.core.resources.ResourceHandlerProvider
getPriority, getResourceHandler
-
-
-
-
Field Detail
-
_manager
protected ServiceManager _manager
The service manager
-
-
Constructor Detail
-
AbstractResourceHandlerProvider
public AbstractResourceHandlerProvider()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualize
in interfaceContextualizable
- Throws:
ContextException
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
setup
protected ResourceHandler setup(ResourceHandler handler) throws Exception
Setup the handler right after its creation- Parameters:
handler
- the handler.- Returns:
- the initialized
ResourceHandler
. - Throws:
Exception
- if something goes wrong during initialization
-
-