Interface Entry

All Known Subinterfaces:
DirectoryEntry, FileEntry
All Known Implementing Classes:
AbstractEntry, BaseFileEntry, DefaultDirectoryEntry

public interface Entry
An entry in the repository.
Since:
1.0
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the repository that this entry belongs to.
    long
    Returns the time that this entry was last modified.
    Returns the name of this entry.
    Returns the parent of this entry (or null if there is no parent, that is the root entry).
    Returns the path of this entry relative to the root of the filesystem.
  • Method Details

    • getFileSystem

      FileSystem getFileSystem()
      Returns the repository that this entry belongs to.
      Returns:
      the repository that this entry belongs to.
      Since:
      1.0
    • getParent

      DirectoryEntry getParent()
      Returns the parent of this entry (or null if there is no parent, that is the root entry).
      Returns:
      the parent of this entry (or null if there is no parent, that is the root entry).
      Since:
      1.0
    • getName

      String getName()
      Returns the name of this entry.
      Returns:
      the name of this entry.
      Since:
      1.0
    • getLastModified

      long getLastModified() throws IOException
      Returns the time that this entry was last modified. Note that DirectoryEntrys may delegate to FileSystem.getLastModified(DirectoryEntry).
      Returns:
      A long value representing the time the directory was last modified, measured in milliseconds since the epoch (00:00:00 GMT, January 1, 1970), or 0L if the the time is unknown.
      Throws:
      IOException - if an I/O error occurs.
      Since:
      1.0
    • toPath

      String toPath()
      Returns the path of this entry relative to the root of the filesystem. Must not start with a '/'.
      Returns:
      the path of this entry relative to the root of the filesystem.
      Since:
      1.0