net.hasor.plugins.resource.loader
类 PathResourceLoader

java.lang.Object
  继承者 net.hasor.plugins.resource.loader.PathResourceLoader
所有已实现的接口:
ResourceLoader

public class PathResourceLoader
extends Object
implements ResourceLoader

将一个File对象所代表的路径作为根路径,资源获取相对于该路径下。

版本:
: 2011-9-17
作者:
赵永春 (zyc@hasor.net)

构造方法摘要
PathResourceLoader(String dirPath)
           
 
方法摘要
 boolean canModify(String resourcePath)
          测试资源是否可能被改变。
 void close(Object resource)
          装载指定资源。
 boolean exist(String resourcePath)
          测试资源是否存在。
 InputStream getResourceAsStream(String resourcePath)
          装载指定资源。
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

PathResourceLoader

public PathResourceLoader(String dirPath)
方法详细信息

getResourceAsStream

public InputStream getResourceAsStream(String resourcePath)
从接口 ResourceLoader 复制的描述
装载指定资源。

指定者:
接口 ResourceLoader 中的 getResourceAsStream

canModify

public boolean canModify(String resourcePath)
                  throws IOException
从接口 ResourceLoader 复制的描述
测试资源是否可能被改变。

指定者:
接口 ResourceLoader 中的 canModify
抛出:
IOException

exist

public boolean exist(String resourcePath)
              throws IOException
从接口 ResourceLoader 复制的描述
测试资源是否存在。

指定者:
接口 ResourceLoader 中的 exist
抛出:
IOException

close

public void close(Object resource)
           throws IOException
从接口 ResourceLoader 复制的描述
装载指定资源。

指定者:
接口 ResourceLoader 中的 close
抛出:
IOException


Copyright © 2013-2014. All Rights Reserved.