public class FileResourceLoader extends ResourceLoader
className, isCachingOn, log, modificationCheckInterval, rsvc| Constructor and Description |
|---|
FileResourceLoader() |
| Modifier and Type | Method and Description |
|---|---|
long |
getLastModified(Resource resource)
Get the last modified time of the InputStream source
that was used to create the template.
|
InputStream |
getResourceStream(String templateName)
Get an InputStream so that the Runtime can build a
template with it.
|
void |
init(org.apache.commons.collections.ExtendedProperties configuration)
Initialize the template loader with a
a resources class.
|
boolean |
isSourceModified(Resource resource)
How to keep track of all the modified times
across the paths.
|
boolean |
resourceExists(String name)
Overrides superclass for better performance.
|
commonInit, getClassName, getModificationCheckInterval, isCachingOn, setCachingOn, setModificationCheckIntervalpublic void init(org.apache.commons.collections.ExtendedProperties configuration)
ResourceLoaderinit in class ResourceLoaderResourceLoader.init(org.apache.commons.collections.ExtendedProperties)public InputStream getResourceStream(String templateName) throws ResourceNotFoundException
getResourceStream in class ResourceLoadertemplateName - name of template to getResourceNotFoundException - if template not found
in the file template path.public boolean resourceExists(String name)
resourceExists in class ResourceLoadername - The name of a resource.public boolean isSourceModified(Resource resource)
isSourceModified in class ResourceLoaderresource - public long getLastModified(Resource resource)
ResourceLoadergetLastModified in class ResourceLoaderResourceLoader.getLastModified(org.apache.velocity.runtime.resource.Resource)Copyright © 2000–2016. All rights reserved.