net.hasor.plugins.resource.loader
类 ZipResourceLoader

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

public class ZipResourceLoader
extends Object
implements ResourceLoader

用于创建一个可以从classpath中获取资源的ResourceLoader。

版本:
: 2013-6-6
作者:
赵永春 (zyc@hasor.net)

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

构造方法详细信息

ZipResourceLoader

public ZipResourceLoader(String zipFile)
                  throws IOException
抛出:
IOException
方法详细信息

getZipFile

public String getZipFile()
获取资源获取的包路径。


getResourceAsStream

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

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

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.