|
TrueZIP 6.8.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectde.schlichtherle.io.ArchiveController
de.schlichtherle.io.ArchiveFileSystemController
abstract class ArchiveFileSystemController
This archive controller implements the automounting functionality. It is up to the sub class to implement the actual mounting/unmounting strategy.
| Nested Class Summary | |
|---|---|
private static class |
ArchiveFileSystemController.AutoMounter
Represents the mount state of the archive file system. |
private class |
ArchiveFileSystemController.FalsePositiveFileSystem
|
private class |
ArchiveFileSystemController.MountedFileSystem
|
private class |
ArchiveFileSystemController.ResetFileSystem
|
| Field Summary | |
|---|---|
private ArchiveFileSystemController.AutoMounter |
autoMounter
The mount state of the archive file system. |
| Fields inherited from interface de.schlichtherle.io.Entry |
|---|
ROOT_NAME, SEPARATOR, SEPARATOR_CHAR |
| Constructor Summary | |
|---|---|
ArchiveFileSystemController(File target,
ArchiveController enclController,
String enclEntryName,
ArchiveDriver driver)
Creates a new instance of ArchiveFileSystemController |
|
| Method Summary | |
|---|---|
(package private) ArchiveFileSystem |
autoMount(boolean create)
Returns the virtual archive file system mounted from the target file. |
(package private) ArchiveEntry |
createArchiveEntry(String entryName,
ArchiveEntry blueprint)
|
(package private) ArchiveFileSystem |
getFileSystem()
|
(package private) boolean |
isTouched()
Returns true if and only if the file system has been
touched. |
(package private) abstract void |
mount(boolean create)
Mounts the virtual file system from the target file. |
(package private) void |
reset()
Resets the archive controller to its initial state - all changes to the archive file which have not yet been updated get lost! |
(package private) void |
setFileSystem(ArchiveFileSystem fileSystem)
|
(package private) void |
touch()
Called by this controller's ArchiveFileSystem to notify it
that the file system has been touched. |
| Methods inherited from class de.schlichtherle.io.ArchiveController |
|---|
autoUmount, canRead, canWrite, createInputStream, createInputStream, createInputStream0, createNewFile, createOutputStream, createOutputStream, createOutputStream0, delete, enclEntryName, exists, getClosedIcon, getDriver, getEnclArchive, getEnclController, getEnclEntryName, getOpenIcon, getPath, getTarget, hasNewData, isDirectory, isFile, isRfsEntryTarget, isRoot, lastModified, length, list, list, listFiles, listFiles, mkdir, readLock, runWriteLocked, setDriver, setLastModified, setReadOnly, setScheduled, toString, umount, waitAllInputStreamsByOtherThreads, waitAllOutputStreamsByOtherThreads, writeLock |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private ArchiveFileSystemController.AutoMounter autoMounter
| Constructor Detail |
|---|
ArchiveFileSystemController(File target,
ArchiveController enclController,
String enclEntryName,
ArchiveDriver driver)
| Method Detail |
|---|
final boolean isTouched()
ArchiveControllertrue if and only if the file system has been
touched.
isTouched in class ArchiveController
void touch()
throws IOException
ArchiveFileSystem to notify it
that the file system has been touched.
A file system is touched if an operation has been performed on it
which modifies it.
Warning: The write lock of this controller must be acquired while this method is called!
IOException
final ArchiveFileSystem autoMount(boolean create)
throws IOException
ArchiveControllerWarning: Either the read or the write lock of this controller must be acquired while this method is called! If only a read lock is acquired, but a write lock is required, this method will temporarily release all locks, so any preconditions must be checked again upon return to protect against concurrent modifications!
autoMount in class ArchiveControllercreate - If the archive file does not exist and this is
true, a new file system with only a virtual root
directory is created with its last modification time set to the
system's current time.
null is never returned.
ArchiveController.FalsePositiveException
IOException - On any other I/O related issue with the target file
or the target file of any enclosing archive file's controller.final ArchiveFileSystem getFileSystem()
final void setFileSystem(ArchiveFileSystem fileSystem)
abstract void mount(boolean create)
throws IOException
Upon normal termination, this method is expected to have called
ArchiveFileSystemController.ResetFileSystem to assign the fully initialized file system
to this controller.
Other than this, the method must not have any side effects on the
state of this class or its super class.
It may, however, have side effects on the state of the sub class.
create - If the archive file does not exist and this is
true, a new file system with only a virtual root
directory is created with its last modification time set to the
system's current time.
FalsePositiveException
IOException - On any other I/O related issue with the target file
or the target file of any enclosing archive file's controller.
void reset()
throws IOException
ArchiveControllerThis method should be overridden by subclasses, but must still be called when doing so.
reset in class ArchiveControllerIOException
final ArchiveEntry createArchiveEntry(String entryName,
ArchiveEntry blueprint)
throws CharConversionException
CharConversionException
|
TrueZIP 6.8.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||