|
TrueZIP Kernel 7.0-rc2 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectde.schlichtherle.truezip.fs.FsDriver
de.schlichtherle.truezip.fs.archive.FsArchiveDriver<E>
E - The type of the archive entries.@Immutable @DefaultAnnotation(value=edu.umd.cs.findbugs.annotations.NonNull.class) public abstract class FsArchiveDriver<E extends FsArchiveEntry>
An abstract archive driver which provides access to a federated file system which is persistet in an archive file format like ZIP, JAR, TZP, TAR, TAR.GZ, TAR.BZ2 etc.
| Constructor Summary | |
|---|---|
FsArchiveDriver()
|
|
| Method Summary | |
|---|---|
Icon |
getClosedIcon(FsConcurrentModel model)
Returns the icon that should be displayed for the given archive file if it's closed/collapsed in the view. |
Icon |
getOpenIcon(FsConcurrentModel model)
Returns the icon that should be displayed for the given archive file if it's open/expanded in the view. |
abstract IOPool<?> |
getPool()
Returns the I/O pool to use for allocating temporary I/O entries. |
boolean |
isFederated()
Returns true iff this file system driver implements a federated
file system type, i.e. if the type of file system must be a member of a
parent file system. |
FsController<?> |
newController(FsModel model,
FsController<?> parent)
Returns a new thread-safe file system controller for the given mount point and parent file system controller. |
abstract InputShop<E> |
newInputShop(FsConcurrentModel model,
InputSocket<?> input)
Creates a new input shop for reading the archive entries of the the described archive from the given input socket's target. |
abstract OutputShop<E> |
newOutputShop(FsConcurrentModel model,
OutputSocket<?> output,
InputShop<E> source)
Creates a new output shop for writing archive entries to the the described archive to the given output socket's target. |
| Methods inherited from class de.schlichtherle.truezip.fs.FsDriver |
|---|
toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface de.schlichtherle.truezip.entry.EntryFactory |
|---|
newEntry |
| Constructor Detail |
|---|
public FsArchiveDriver()
| Method Detail |
|---|
public final boolean isFederated()
true iff this file system driver implements a federated
file system type, i.e. if the type of file system must be a member of a
parent file system.
The implementation in the class FsDriver returns false.
The implementation in the class FsArchiveDriver always returns
true.
This can't get overridden.
isFederated in class FsDrivertrue iff the type of the file system implemented by this
file system driver is federated, i.e. must be a member of a
parent file system.public abstract IOPool<?> getPool()
public FsController<?> newController(FsModel model,
FsController<?> parent)
When called, the following expression is a precondition:
mountPoint.getParent().equals(parent.getModel().getMountPoint())
Note that an archive file system is always federated and therefore
its parent file system controller is never null.
Furthermore, an archive driver implementation is not expected to consider the scheme of the given mount point to determine the class of the returned file system controller. Consequently, it is an error to call this method with a mount point which has a scheme which is not supported by this archive driver.
Note again that the returned file system controller must be thread-safe!
newController in class FsDrivermodel - the file system model.parent - the nullable parent file system controller.
public abstract InputShop<E> newInputShop(FsConcurrentModel model,
InputSocket<?> input)
throws IOException
archive from the given input socket's target.
model - the concurrent file system model.input - the input socket for reading the contents of the archive
from its target.
TabuFileException - if the target archive file is temporarily not
accessible, e.g. if a key for decryption is currently not
available.
The client application will recognize the target archive file
as a tabu file until a subsequent repetition of this
method call succeeds.
A tabu file will not be accessible through the API although it
exists.
FileNotFoundException - if the target archive file does not exist
or is (temporarily) not accessible.
An exception of this type marks a transient cause,
i.e. this method may get subsequently called until it succeeds.
IOException - if the target archive file is a
false positive archive file.
An exception of this type marks a persistent cause,
i.e. this method will not get called again until the archive
file system is synchronized with its parent file system.
public abstract OutputShop<E> newOutputShop(FsConcurrentModel model,
OutputSocket<?> output,
@CheckForNull
InputShop<E> source)
throws IOException
archive to the given output socket's target.
model - the concurrent file system model.output - the output socket for writing the contents of the
archive to its target.source - the InputShop if archive is going to get
updated.
If not null, this is guaranteed to be a product
of this driver's newInputShop(de.schlichtherle.truezip.fs.FsConcurrentModel, de.schlichtherle.truezip.socket.InputSocket>) factory method, which may
be used to copy some meta data which is specific to the type of
archive this driver supports.
For example, this could be used to copy the comment of a ZIP
file.
FileNotFoundException - if the target archive file does not exist
or is (temporarily) not accessible.
An exception of this type marks a transient cause,
i.e. this method may get subsequently called until it succeeds.
IOException - if the target archive file is a
false positive archive file.
An exception of this type marks a persistent cause,
i.e. this method will not get called again until the archive
file system is synchronized with its parent file system.@CheckForNull public Icon getOpenIcon(FsConcurrentModel model)
The implementation in the abstract class FsArchiveDriver simply
returns null.
model - the concurrent file system model.
null is returned, a default icon should be displayed.@CheckForNull public Icon getClosedIcon(FsConcurrentModel model)
The implementation in the abstract class FsArchiveDriver simply
returns null.
model - the concurrent file system model.
null is returned, a default icon should be displayed.
|
TrueZIP Kernel 7.0-rc2 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||