Package org.ametys.plugins.flipbook
Class PdfCoverResourceHandler
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.core.resources.SimpleResourceHandler
-
- org.ametys.core.resources.ImageResourceHandler
-
- org.ametys.plugins.flipbook.PdfCoverResourceHandler
-
- All Implemented Interfaces:
ResourceHandler,LogEnabled,Contextualizable,Serviceable
public class PdfCoverResourceHandler extends ImageResourceHandler implements Contextualizable
Resource handler for pdf resources files
-
-
Field Summary
Fields Modifier and Type Field Description protected AmetysObjectResolver_ametysObjectResolverAmetys object resolverprotected ConvertExternalResource2ImagesComponent_externalResourceComponentAttachment component-
Fields inherited from class org.ametys.core.resources.SimpleResourceHandler
_objectModel, _parameters, _readForDownload, _requestedLocation, _resolver, _source
-
-
Constructor Summary
Constructors Constructor Description PdfCoverResourceHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcontextualize(Context context)voidservice(ServiceManager serviceManager)Sourcesetup(String location, Map objectModel, Parameters par, boolean readForDownload)Initialize the resource handler with a resource.-
Methods inherited from class org.ametys.core.resources.ImageResourceHandler
generate, getKey
-
Methods inherited from class org.ametys.core.resources.SimpleResourceHandler
getLastModified, getMimeType, getValidity
-
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.ResourceHandler
acceptRanges, generate, getLength, shouldUseSourceContentLength
-
-
-
-
Field Detail
-
_externalResourceComponent
protected ConvertExternalResource2ImagesComponent _externalResourceComponent
Attachment component
-
_ametysObjectResolver
protected AmetysObjectResolver _ametysObjectResolver
Ametys object resolver
-
-
Constructor Detail
-
PdfCoverResourceHandler
public PdfCoverResourceHandler()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualizein interfaceContextualizable- Throws:
ContextException
-
service
public void service(ServiceManager serviceManager) throws ServiceException
- Specified by:
servicein interfaceServiceable- Overrides:
servicein classSimpleResourceHandler- Throws:
ServiceException
-
setup
public Source setup(String location, Map objectModel, Parameters par, boolean readForDownload) throws IOException, ProcessingException
Description copied from interface:ResourceHandlerInitialize the resource handler with a resource.- Specified by:
setupin interfaceResourceHandler- Overrides:
setupin classImageResourceHandler- Parameters:
location- The source uriobjectModel- The object modelpar- The parametersreadForDownload- if the resource is to be downloaded and not rendered.- Returns:
- the resolved source
- Throws:
IOException- If an error occursProcessingException- If an error occurs
-
-