public abstract class RepoFile extends Entity implements AutoTrackLocalRevision
Constructor and Description |
---|
RepoFile() |
Modifier and Type | Method and Description |
---|---|
File |
getFile(File localRoot)
|
Date |
getLastModified()
Gets the timestamp of the file's last modification.
|
UUID |
getLastSyncFromRepositoryId() |
long |
getLocalRevision()
Get the
local revision of the last modification
of this entity. |
String |
getName() |
RepoFile |
getParent() |
String |
getPath()
Gets the path from the root to
this . |
List<RepoFile> |
getPathList()
Gets the path within the repository from the
root (including) to this (including). |
void |
setLastModified(Date lastModified) |
void |
setLastSyncFromRepositoryId(UUID repositoryId) |
void |
setLocalRevision(long localRevision) |
void |
setName(String name) |
void |
setParent(RepoFile parent) |
equals, getChanged, getCreated, getId, hashCode, setChanged, setCreated, toString
public RepoFile()
public long getLocalRevision()
local revision
of the last modification
of this entity.
Note that this does not include modifications of children (in case this is a directory). If a child is modified, solely this child's localRevision is updated.
getLocalRevision
in interface AutoTrackLocalRevision
public void setLocalRevision(long localRevision)
setLocalRevision
in interface AutoTrackLocalRevision
public List<RepoFile> getPathList()
root
(including) to this
(including).
The first element in the list is the root
. The last element is this
.
If this method is called on the root
itself, the result will be a list with one single element (the root itself).
root
(including) to this
(including). Never null
.public String getPath()
this
.
The path's elements are separated by a slash ("/"). The path starts with a slash (like an absolute path), but is relative to the repository's local root.
this
. Never null
. The repository's root itself has the path "/".public Date getLastModified()
It reflects the File.lastModified
property.
public void setLastModified(Date lastModified)
public UUID getLastSyncFromRepositoryId()
public void setLastSyncFromRepositoryId(UUID repositoryId)
Copyright © 2013-2014. All Rights Reserved.