Package digilib.io
Class FsDocuDirectory
java.lang.Object
digilib.io.DocuDirectory
digilib.io.FsDocuDirectory
- All Implemented Interfaces:
Iterable<DocuDirent>
- Direct Known Subclasses:
BaseDirDocuDirectory
Filesystem-based DocuDirectory implementation.
- Author:
- casties
-
Field Summary
FieldsFields inherited from class digilib.io.DocuDirectory
dirMTime, dirName, fileClass, files, isValid, logger, meta, objectATime, parent -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateFilename(String fn) Returns a possible file name for path fn.Returns a possible parent directory name for path fn.getDir()Returns the filesystem File for this directory.String[]Returns the parent filesystem Directory.abstract booleanreadDir()Read the filesystem directory and fill this object.Methods inherited from class digilib.io.DocuDirectory
checkMeta, configure, find, get, getAccessTime, getDirMTime, getDirName, getMeta, getParent, indexOf, isBasenameAt, isPrefixBasenameAt, isRead, isValid, iterator, readMeta, refresh, setParent, size, touchMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
dir
-
-
Constructor Details
-
FsDocuDirectory
public FsDocuDirectory()
-
-
Method Details
-
readDir
public abstract boolean readDir()Description copied from class:DocuDirectoryRead the filesystem directory and fill this object. Clears the List and (re)reads all files.- Specified by:
readDirin classDocuDirectory- Returns:
- boolean the directory exists
-
getParentDirectory
Returns the parent filesystem Directory.- Returns:
- the Directory
-
getDir
Returns the filesystem File for this directory.- Returns:
- the File
-
getFilenames
- Returns:
- the filenames
-
createParentName
Description copied from class:DocuDirectoryReturns a possible parent directory name for path fn.- Specified by:
createParentNamein classDocuDirectory- Parameters:
fn- the fn- Returns:
- the parent name
-
createFilename
Description copied from class:DocuDirectoryReturns a possible file name for path fn.- Specified by:
createFilenamein classDocuDirectory- Parameters:
fn- the fn- Returns:
- the name
-