org.restlet.ext.velocity
Class RepresentationResourceLoader
java.lang.Object
org.apache.velocity.runtime.resource.loader.ResourceLoader
org.restlet.ext.velocity.RepresentationResourceLoader
public class RepresentationResourceLoader
- extends ResourceLoader
Velocity resource loader based on a static map of representations or on a
default representation.
- Author:
- Jerome Louvel
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RepresentationResourceLoader
public RepresentationResourceLoader(Representation defaultRepresentation)
- Constructor.
- Parameters:
defaultRepresentation
- The default representation to use.
getStore
public static Map<String,Representation> getStore()
- Returns the cache of template representations.
- Returns:
- The cache of template representations.
getLastModified
public long getLastModified(Resource resource)
- Specified by:
getLastModified
in class ResourceLoader
getResourceStream
public InputStream getResourceStream(String name)
throws ResourceNotFoundException
- Specified by:
getResourceStream
in class ResourceLoader
- Throws:
ResourceNotFoundException
init
public void init(org.apache.commons.collections.ExtendedProperties configuration)
- Specified by:
init
in class ResourceLoader
isSourceModified
public boolean isSourceModified(Resource resource)
- Specified by:
isSourceModified
in class ResourceLoader
Copyright © 2005-2013 Restlet.