public class JarPath extends FilesystemPath
Path.FileChannelFactory
_bindRoot, _pathname, _root, _userPath
_pathSeparatorChar, _schemeMap, _separatorChar, L
Modifier | Constructor and Description |
---|---|
protected |
JarPath(FilesystemPath root,
java.lang.String userPath,
java.lang.String path,
Path backing)
Creates a new jar path for the specific file
|
Modifier and Type | Method and Description |
---|---|
boolean |
canRead()
Tests if the file can be read.
|
boolean |
canWrite()
Tests if the file can be written.
|
void |
closeJar() |
static JarPath |
create(Path backing)
Creates a new root Jar path.
|
boolean |
equals(java.lang.Object o)
Tests for equality.
|
boolean |
exists()
Returns true if the entry exists in the jar file.
|
Path |
fsWalk(java.lang.String userPath,
java.util.Map<java.lang.String,java.lang.Object> attributes,
java.lang.String path)
Lookup a path relative to the current filesystem's root.
|
java.security.cert.Certificate[] |
getCertificates()
Returns any signing certificates.
|
Path |
getContainer()
Returns the underlying file below the jar.
|
PersistentDependency |
getDepend()
Returns the dependency checker from the jar.
|
Jar |
getJar() |
long |
getLastModified()
Returns the last modified time of the file.
|
long |
getLength()
Returns the length of the file in bytes.
|
java.util.jar.Manifest |
getManifest()
Returns the manifest.
|
java.lang.String |
getScheme()
Returns the scheme (jar)
|
java.lang.String |
getURL()
Returns the full url.
|
int |
hashCode() |
boolean |
isDirectory()
Returns true if the entry is a directory in the jar file.
|
boolean |
isFile()
Returns true if the entry is a file in the jar file.
|
boolean |
isPathCacheable()
Returns true if the path itself is cacheable
|
java.lang.String[] |
list()
Returns a list of the directories in the jar.
|
StreamImpl |
openReadImpl() |
java.lang.String |
toString() |
bind, createRoot, getFullPath, getParent, getPath, getRoot, getTail, getUserPath, init, normalizePath, normalizePath, schemeWalk, setUserPath
cacheCopy, canExecute, changeGroup, changeGroup, changeOwner, changeOwner, chmod, clearStatusCache, compareTo, copy, createDepend, createLink, createNewFile, createRoot, createTempFile, escapeURL, fileChannelFactory, getAttribute, getAttributeNames, getBlockCount, getBlockSize, getCache, getContentType, getCrc64, getCreateTime, getDevice, getDeviceId, getDiskSpaceFree, getDiskSpaceTotal, getFileSeparatorChar, getGroup, getHost, getInode, getLastAccessTime, getLastStatusChangeTime, getMode, getNativePath, getNewlineString, getNumberOfLinks, getObject, getOwner, getPathSeparatorChar, getPort, getQuery, getRelativePath, getResources, getResources, getSchemeMap, getSeparatorChar, getUser, getUserDir, getValue, isBlockDevice, isCharacterDevice, isExecutable, isFIFO, isHardLink, isLink, isObject, isSocket, isSymbolicLink, isWindows, isWindowsInsecure, iterator, lookup, lookup, lookup, lookupChild, lookupImpl, lookupNative, lookupNative, lookupRelativeNativePath, mkdir, mkdirs, openAppend, openAppendImpl, openFileRandomAccess, openMemoryMappedFile, openRandomAccess, openRead, openReadWrite, openReadWrite, openReadWrite, openReadWriteImpl, openWrite, openWriteImpl, putCache, readLink, realPath, remove, removeAll, renameTo, renameTo, scanScheme, sendfile, setDefaultSchemeMap, setExecutable, setLastModified, setObject, setTestWindows, setValue, truncate, truncate, unbind, unwrap, writeToStream, writeToStream
protected JarPath(FilesystemPath root, java.lang.String userPath, java.lang.String path, Path backing)
root
- the root of this jaruserPath
- the path specified by the user in the lookup()path
- the normalized pathjarFile
- the underlying jarpublic Path fsWalk(java.lang.String userPath, java.util.Map<java.lang.String,java.lang.Object> attributes, java.lang.String path)
FilesystemPath
fsWalk
in class FilesystemPath
userPath
- the exact string passed by the user's lookup()attributes
- the user's new attributespath
- the normalized real pathpublic java.lang.String getScheme()
public boolean isPathCacheable()
Path
isPathCacheable
in class Path
public java.lang.String getURL()
jar:
public Path getContainer()
public java.security.cert.Certificate[] getCertificates()
getCertificates
in class Path
public boolean exists()
public boolean isDirectory()
isDirectory
in class Path
public boolean isFile()
public long getLength()
Path
public long getLastModified()
Path
getLastModified
in class Path
public boolean canRead()
Path
public boolean canWrite()
Path
public java.lang.String[] list() throws java.io.IOException
public java.util.jar.Manifest getManifest() throws java.io.IOException
java.io.IOException
public PersistentDependency getDepend()
public StreamImpl openReadImpl() throws java.io.IOException
openReadImpl
in class Path
java.io.IOException
public Jar getJar()
public void closeJar()
public int hashCode()
hashCode
in class FilesystemPath
public boolean equals(java.lang.Object o)
equals
in class FilesystemPath