java.lang.Object
edu.emory.mathcs.util.classloader.ResourceHandle
edu.emory.mathcs.util.classloader.ResourceLoader.JarResourceHandle
- Enclosing class:
- ResourceLoader
- private static class ResourceLoader.JarResourceHandle
- extends ResourceHandle
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
jar
final java.util.jar.JarFile jar
jentry
final java.util.jar.JarEntry jentry
url
final java.net.URL url
codeSource
final java.net.URL codeSource
ResourceLoader.JarResourceHandle
ResourceLoader.JarResourceHandle(java.util.jar.JarFile jar,
java.util.jar.JarEntry jentry,
java.net.URL url,
java.net.URL codeSource)
getName
public java.lang.String getName()
- Description copied from class:
ResourceHandle
- Return the name of the resource. The name is a "/"-separated path
name that identifies the resource.
- Specified by:
getName in class ResourceHandle
getURL
public java.net.URL getURL()
- Description copied from class:
ResourceHandle
- Returns the URL of the resource.
- Specified by:
getURL in class ResourceHandle
getCodeSourceURL
public java.net.URL getCodeSourceURL()
- Description copied from class:
ResourceHandle
- Returns the CodeSource URL for the class or resource.
- Specified by:
getCodeSourceURL in class ResourceHandle
getInputStream
public java.io.InputStream getInputStream()
throws java.io.IOException
- Description copied from class:
ResourceHandle
- Returns and InputStream for reading this resource data.
- Specified by:
getInputStream in class ResourceHandle
getContentLength
public int getContentLength()
throws java.io.IOException
- Description copied from class:
ResourceHandle
- Returns the length of this resource data, or -1 if unknown.
- Specified by:
getContentLength in class ResourceHandle
close
public void close()
- Description copied from class:
ResourceHandle
- Closes a connection to the resource indentified by this handle. Releases
any I/O objects associated with the handle.
- Overrides:
close in class ResourceHandle