org.codehaus.mojo.mrm.api
Interface Entry

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

public interface Entry
extends Serializable

An entry in the repository.

Since:
1.0

Method Summary
 FileSystem getFileSystem()
          Returns the repository that this entry belongs to.
 long getLastModified()
          Returns the time that this entry was last modified.
 String getName()
          Returns the name of this entry.
 DirectoryEntry getParent()
          Returns the parent of this entry (or null if there is no parent, that is the root entry).
 String toPath()
          Returns the path of this entry relative to the root of the filesystem.
 

Method Detail

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.

Returns:
the path of this entry relative to the root of the filesystem.
Since:
1.0


Copyright © 2009-2011 Codehaus. All Rights Reserved.