Package org.ametys.core.resources
Class ResourceReader
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.apache.cocoon.reading.AbstractReader
-
- org.ametys.core.resources.ResourceReader
-
- All Implemented Interfaces:
Poolable
,Recyclable
,Component
,Contextualizable
,LogEnabled
,Serviceable
,CacheableProcessingComponent
,Reader
,SitemapModelComponent
,SitemapOutputComponent
public class ResourceReader extends AbstractReader implements CacheableProcessingComponent, Serviceable, Contextualizable
Default resource reader, that handle different resources type using the ResourcesExtensionPoint.
-
-
Field Summary
Fields Modifier and Type Field Description static String
LAST_MODIFIED
last modified parameter name for resources parameters-
Fields inherited from class org.apache.cocoon.reading.AbstractReader
objectModel, out, parameters, resolver, source
-
-
Constructor Summary
Constructors Constructor Description ResourceReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
contextualize(Context context)
void
generate()
Serializable
getKey()
long
getLastModified()
String
getMimeType()
SourceValidity
getValidity()
void
recycle()
void
service(ServiceManager sManager)
void
setup(SourceResolver res, Map objectModel, String source, Parameters parameters)
-
Methods inherited from class org.apache.cocoon.reading.AbstractReader
setOutputStream, shouldSetContentLength
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Field Detail
-
LAST_MODIFIED
public static final String LAST_MODIFIED
last modified parameter name for resources parameters- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ResourceReader
public ResourceReader()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualize
in interfaceContextualizable
- Throws:
ContextException
-
service
public void service(ServiceManager sManager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
setup
public void setup(SourceResolver res, Map objectModel, String source, Parameters parameters) throws ProcessingException, SAXException, IOException
- Specified by:
setup
in interfaceSitemapModelComponent
- Overrides:
setup
in classAbstractReader
- Throws:
ProcessingException
SAXException
IOException
-
generate
public void generate() throws IOException, ProcessingException
- Specified by:
generate
in interfaceReader
- Throws:
IOException
ProcessingException
-
getKey
public Serializable getKey()
- Specified by:
getKey
in interfaceCacheableProcessingComponent
-
getValidity
public SourceValidity getValidity()
- Specified by:
getValidity
in interfaceCacheableProcessingComponent
-
recycle
public void recycle()
- Specified by:
recycle
in interfaceRecyclable
- Overrides:
recycle
in classAbstractReader
-
getMimeType
public String getMimeType()
- Specified by:
getMimeType
in interfaceSitemapOutputComponent
- Overrides:
getMimeType
in classAbstractReader
-
getLastModified
public long getLastModified()
- Specified by:
getLastModified
in interfaceReader
- Overrides:
getLastModified
in classAbstractReader
-
-