|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.partnersoft.io.vfs.AbstractVfs
public abstract class AbstractVfs
A basic (and fairly simpleminded) implementation of a Vfs. It provides an indexing setup so that VfsDirectories and VfsFile objects are stored and tracked as objects rather than on disk. So, it may be appropriate to relatively small and static file systems (e.g. a archive file format) but not for large or dynamic ones.
Copyright 2009 Partner Software, Inc.
| Constructor Summary | |
|---|---|
AbstractVfs()
|
|
| Method Summary | |
|---|---|
protected VfsDirectory |
addDirectoryEntry(Path path)
Adds a directory entry to the index, and automatically adds all parent directories as well. |
protected void |
addFileEntry(VfsFile file)
Adds a file entry to the index, and automatically adds all parent directories as well. |
abstract void |
close()
|
VfsDirectory |
directoryFor(Path path)
Returns a VfsDirectory for the given path. |
VfsDirectory |
directoryFor(java.lang.String pathString)
Returns a VfsDirectory for the given path. |
VfsFile |
fileFor(Path path)
Returns a VfsFile for the given path. |
VfsFile |
fileFor(java.lang.String pathString)
Returns a VfsFile for the given path string. |
boolean |
isWritable()
True if this module supports writing. |
abstract void |
open()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.partnersoft.io.vfs.Vfs |
|---|
getAbsolutePath |
| Constructor Detail |
|---|
public AbstractVfs()
throws java.io.IOException
java.io.IOException| Method Detail |
|---|
public abstract void open()
throws java.io.IOException
java.io.IOException
public abstract void close()
throws java.io.IOException
java.io.IOExceptionpublic VfsDirectory directoryFor(Path path)
Vfs
directoryFor in interface Vfspath - to directory
public VfsDirectory directoryFor(java.lang.String pathString)
Vfs
directoryFor in interface VfspathString - string-encoded path to directory
public VfsFile fileFor(Path path)
Vfs
fileFor in interface Vfspath - to file
public VfsFile fileFor(java.lang.String pathString)
Vfs
fileFor in interface VfspathString - string-encoded path to file
public boolean isWritable()
Vfs
isWritable in interface Vfsprotected void addFileEntry(VfsFile file)
protected VfsDirectory addDirectoryEntry(Path path)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||