Class JarFileSystem
java.lang.Object
org.apache.commons.vfs2.provider.AbstractVfsComponent
org.apache.commons.vfs2.provider.AbstractFileSystem
org.apache.commons.vfs2.provider.zip.ZipFileSystem
org.apache.commons.vfs2.provider.jar.JarFileSystem
- All Implemented Interfaces:
FileSystem
,VfsComponent
A read-only file system for Jar files.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
JarFileSystem
(AbstractFileName rootName, FileObject file, FileSystemOptions fileSystemOptions) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addCapabilities
(Collection<Capability> caps) Returns the capabilities of this file system.protected ZipFile
createZipFile
(File file) protected ZipFileObject
createZipFileObject
(AbstractFileName name, ZipEntry entry) getAttribute
(String attrName) Retrives the attribute with the specified name.protected ZipFile
Methods inherited from class org.apache.commons.vfs2.provider.zip.ZipFileSystem
createFile, doCloseCommunicationLink, getFileFromCache, init, putFileToCache, removeFileFromCache, toString
Methods inherited from class org.apache.commons.vfs2.provider.AbstractFileSystem
addJunction, addListener, close, closeCommunicationLink, decorateFileObject, doReplicateFile, fireFileChanged, fireFileCreated, fireFileDeleted, getFileSystemManager, getFileSystemOptions, getLastModTimeAccuracy, getParentLayer, getRoot, getRootName, getRootURI, hasCapability, isOpen, isReleaseable, notifyAllStreamsClosed, removeJunction, removeListener, replicateFile, resolveFile, resolveFile, setAttribute
Methods inherited from class org.apache.commons.vfs2.provider.AbstractVfsComponent
getContext, getLogger, setContext, setLogger
-
Constructor Details
-
JarFileSystem
protected JarFileSystem(AbstractFileName rootName, FileObject file, FileSystemOptions fileSystemOptions) throws FileSystemException - Throws:
FileSystemException
-
-
Method Details
-
createZipFile
- Overrides:
createZipFile
in classZipFileSystem
- Throws:
FileSystemException
-
createZipFileObject
protected ZipFileObject createZipFileObject(AbstractFileName name, ZipEntry entry) throws FileSystemException - Overrides:
createZipFileObject
in classZipFileSystem
- Throws:
FileSystemException
-
addCapabilities
Returns the capabilities of this file system.- Overrides:
addCapabilities
in classZipFileSystem
- Parameters:
caps
- collections of Capabilities, can be immutable.
-
getAttribute
Retrives the attribute with the specified name. The default implementation simply throws an exception.- Specified by:
getAttribute
in interfaceFileSystem
- Overrides:
getAttribute
in classAbstractFileSystem
- Parameters:
attrName
- The attiribute's name.- Returns:
- The value of the attribute.
- Throws:
FileSystemException
- if an error occurs.- See Also:
-
getZipFile
- Overrides:
getZipFile
in classZipFileSystem
- Throws:
FileSystemException
-