public class JarFileDirectoryImpl extends Object implements IJarFileDirectory
| Constructor and Description |
|---|
JarFileDirectoryImpl(File file) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearCaches() |
boolean |
create() |
boolean |
delete() |
IDirectory |
dir(String relativePath) |
boolean |
equals(Object obj) |
boolean |
exists()
Indicates whether this resource exists.
|
IFile |
file(String path)
Constucts a file given the path.
|
InputStream |
getInputStream(JarEntry entry) |
JarFile |
getJarFile() |
String |
getName()
Gets this file's or directory's name.
|
JarEntryDirectoryImpl |
getOrCreateDirectory(String relativeName) |
JarEntryFileImpl |
getOrCreateFile(String relativeName) |
IDirectory |
getParent()
Gets this file's our directory's parent directory.
|
ResourcePath |
getPath() |
boolean |
hasChildFile(String path)
Returns true if the given path represents a child of this directory that exists.
|
boolean |
isAdditional() |
boolean |
isChildOf(IDirectory dir)
Indicates whether this resource is a direct child of the given directory.
|
boolean |
isDescendantOf(IDirectory dir)
Indicates whether this resource is a descendant of the given directory.
|
boolean |
isInJar() |
boolean |
isJavaFile() |
List<? extends IDirectory> |
listDirs() |
List<? extends IFile> |
listFiles() |
boolean |
mkdir() |
String |
relativePath(IResource resource) |
File |
toJavaFile() |
String |
toString() |
URI |
toURI() |
public JarFileDirectoryImpl(File file)
public InputStream getInputStream(JarEntry entry) throws IOException
IOExceptionpublic JarEntryDirectoryImpl getOrCreateDirectory(String relativeName)
getOrCreateDirectory in interface IJarFileDirectorypublic JarEntryFileImpl getOrCreateFile(String relativeName)
getOrCreateFile in interface IJarFileDirectorypublic IDirectory dir(String relativePath)
dir in interface IDirectorypublic IFile file(String path)
IDirectoryfile in interface IDirectorypath - the path of the filepublic boolean mkdir()
throws IOException
mkdir in interface IDirectoryIOExceptionpublic List<? extends IDirectory> listDirs()
listDirs in interface IDirectorypublic List<? extends IFile> listFiles()
listFiles in interface IDirectorypublic String relativePath(IResource resource)
relativePath in interface IDirectorypublic IDirectory getParent()
IResourcepublic String getName()
IResourcepublic boolean exists()
IResourcepublic boolean delete()
throws IOException
delete in interface IResourceIOExceptionpublic ResourcePath getPath()
public boolean isChildOf(IDirectory dir)
IResourcepublic boolean isDescendantOf(IDirectory dir)
IResourceisDescendantOf in interface IResourcedir - the directory which would be the ancestorpublic File toJavaFile()
toJavaFile in interface IResourcepublic JarFile getJarFile()
public boolean isJavaFile()
isJavaFile in interface IResourcepublic void clearCaches()
clearCaches in interface IDirectorypublic boolean hasChildFile(String path)
IDirectoryhasChildFile in interface IDirectorypath - the path of the filepublic boolean isAdditional()
isAdditional in interface IDirectoryCopyright © 2018. All rights reserved.