Class ClasspathResourceLoader


  • public class ClasspathResourceLoader
    extends org.apache.velocity.runtime.resource.loader.ResourceLoader
    Resource loader for Velocity. It loads resources rooted in a base directory.

    Please not that no effort is taken to "chroot" the path.

    • Field Summary

      • Fields inherited from class org.apache.velocity.runtime.resource.loader.ResourceLoader

        className, isCachingOn, log, modificationCheckInterval, rsvc
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      long getLastModified​(org.apache.velocity.runtime.resource.Resource resource)  
      java.io.Reader getResourceReader​(java.lang.String name, java.lang.String encoding)  
      void init​(org.apache.velocity.util.ExtProperties configuration)  
      boolean isSourceModified​(org.apache.velocity.runtime.resource.Resource resource)  
      • Methods inherited from class org.apache.velocity.runtime.resource.loader.ResourceLoader

        buildReader, commonInit, getClassName, getModificationCheckInterval, isCachingOn, resourceExists, setCachingOn, setModificationCheckInterval
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ClasspathResourceLoader

        public ClasspathResourceLoader()
    • Method Detail

      • getLastModified

        public long getLastModified​(org.apache.velocity.runtime.resource.Resource resource)
        Specified by:
        getLastModified in class org.apache.velocity.runtime.resource.loader.ResourceLoader
      • getResourceReader

        public java.io.Reader getResourceReader​(java.lang.String name,
                                                java.lang.String encoding)
                                         throws org.apache.velocity.exception.ResourceNotFoundException
        Specified by:
        getResourceReader in class org.apache.velocity.runtime.resource.loader.ResourceLoader
        Throws:
        org.apache.velocity.exception.ResourceNotFoundException
      • init

        public void init​(org.apache.velocity.util.ExtProperties configuration)
        Specified by:
        init in class org.apache.velocity.runtime.resource.loader.ResourceLoader
      • isSourceModified

        public boolean isSourceModified​(org.apache.velocity.runtime.resource.Resource resource)
        Specified by:
        isSourceModified in class org.apache.velocity.runtime.resource.loader.ResourceLoader