|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface FsDirectoryEntry
Represents one entry in a FsDirectory.
| Field Summary | |
|---|---|
static Comparator<FsDirectoryEntry> |
DIRECTORY_ENTRY_COMPARATOR
Compares directory entries alphabetically, with all directories coming before all files. |
| Method Summary | |
|---|---|
long |
getCreated()
Returns the time when this entry was created as ms since 1970. |
FsDirectory |
getDirectory()
Gets the directory this entry refers to. |
FsFile |
getFile()
Gets the file this entry refers to. |
long |
getLastAccessed()
Returns the time when this entry was last accessed as ms since 1970. |
long |
getLastModified()
Gets the last modification time of this entry. |
String |
getName()
Gets the name of this entry. |
FsDirectory |
getParent()
Deprecated. deprecated since version 0.6 because in the presence of hard links it might not always be possible to determine the parent directory of an entry |
boolean |
isDirectory()
Is this entry refering to a (sub-)directory? |
boolean |
isDirty()
Indicate if the entry has been modified in memory (ie need to be saved) |
boolean |
isFile()
Is this entry refering to a file? |
void |
setLastModified(long lastModified)
Sets the last modification time of this entry. |
void |
setName(String newName)
Sets the name of this entry. |
| Methods inherited from interface de.waldheinz.fs.FsObject |
|---|
isReadOnly, isValid |
| Field Detail |
|---|
static final Comparator<FsDirectoryEntry> DIRECTORY_ENTRY_COMPARATOR
| Method Detail |
|---|
String getName()
@Deprecated FsDirectory getParent()
null
long getLastModified()
throws IOException
0 if this filesystem does not support
getting the last modification time
IOException - if an error occurs retrieving the time stamp
long getCreated()
throws IOException
IOException - on error retrieving the time stamp
long getLastAccessed()
throws IOException
IOException - on error retrieving the last access timeboolean isFile()
boolean isDirectory()
void setName(String newName)
throws IOException
newName - the new name of this entry
IOException - on error setting the new name
void setLastModified(long lastModified)
throws IOException
lastModified - the new last modification time of this entry
IOException - on write error
FsFile getFile()
throws IOException
isFile returns true.
IOException - on error accessing the file
FsDirectory getDirectory()
throws IOException
isDirectory returns true.
IOException - on read errorboolean isDirty()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||