public class JarResource extends URLResource
| Modifier and Type | Field and Description |
|---|---|
protected JarURLConnection |
_jarConnection |
_connection, _in, _url, _urlString__defaultUseCaches| Modifier | Constructor and Description |
|---|---|
protected |
JarResource(URL url) |
protected |
JarResource(URL url,
boolean useCaches) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
checkConnection() |
void |
close()
Release any resources held by the resource.
|
void |
copyTo(File directory) |
boolean |
exists()
Returns true if the represented resource exists.
|
File |
getFile()
Returns an File representing the given resource or NULL if this
is not possible.
|
InputStream |
getInputStream()
Returns an input stream to the resource.
|
protected void |
newConnection() |
static Resource |
newJarResource(Resource resource) |
addPath, delete, equals, getInputStream, getName, getReadableByteChannel, getURL, getUseCaches, hashCode, isContainedIn, isDirectory, lastModified, length, list, renameTo, toStringencode, finalize, getAlias, getAllResources, getAssociate, getDefaultUseCaches, getListHTML, getResource, getURI, getWeakETag, isContainedIn, newClassPathResource, newClassPathResource, newResource, newResource, newResource, newResource, newResource, newSystemResource, release, setAssociate, setDefaultUseCaches, toURL, writeToprotected JarURLConnection _jarConnection
protected JarResource(URL url)
protected JarResource(URL url, boolean useCaches)
public void close()
URLResourceclose in interface Closeableclose in interface AutoCloseableclose in class URLResourceprotected boolean checkConnection()
checkConnection in class URLResourceprotected void newConnection()
throws IOException
IOException - Sub-classes of JarResource may throw an IOException (or subclass)public boolean exists()
exists in class URLResourcepublic File getFile() throws IOException
URLResourcegetFile in class URLResourceIOExceptionpublic InputStream getInputStream() throws IOException
URLResourcegetInputStream in class URLResourceIOExceptionpublic void copyTo(File directory) throws IOException
copyTo in class ResourceIOExceptionpublic static Resource newJarResource(Resource resource) throws IOException
IOExceptionCopyright © 1995-2015 Webtide. All Rights Reserved.