/** * @see java.lang.Object#toString() */ public String toString() { return "Directory['" + getPath() + "' lastModified=" + getLastModified() + " owner=" + getOwner() + " group=" + getGroup() + " permissions=" + getPermissions() + "]"; }
/** * Return a new FileSystemEntry that is a clone of this object, except having the specified path * * @param path - the new path value for the cloned file system entry * @return a new FileSystemEntry that has all the same values as this object except for its path */ public FileSystemEntry cloneWithNewPath(String path) { DirectoryEntry clone = new DirectoryEntry(path); clone.setLastModified(getLastModified()); clone.setOwner(getOwner()); clone.setGroup(getGroup()); clone.setPermissions(getPermissions()); return clone; }