Interface Commit
-
- All Superinterfaces:
VCSModelElement
public interface Commit extends VCSModelElement
Represents a single commit.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description java.lang.String
getAuthor()
Returns the author of this commit.java.time.LocalDateTime
getDateTime()
Returns the datetime of this commit.java.util.List<FileChange>
getFileChanges()
Returns the list of file changes.java.lang.String
getId()
Returns the commit id.java.util.List<Issue>
getIssues()
Returns the issues referenced by this commit.java.lang.String
getMessage()
Returns the commit message.java.util.List<java.lang.String>
getParentIds()
Returns the ids of the parents of this commit.default boolean
isMerge()
Returns whether this commit is a merge commit.-
Methods inherited from interface de.unibremen.informatik.st.libvcs4j.VCSModelElement
getVCSEngine
-
-
-
-
Method Detail
-
getId
java.lang.String getId()
Returns the commit id.- Returns:
- The commit id.
-
getAuthor
java.lang.String getAuthor()
Returns the author of this commit.- Returns:
- The author of this commit.
-
getMessage
java.lang.String getMessage()
Returns the commit message.- Returns:
- The commit message.
-
getDateTime
java.time.LocalDateTime getDateTime()
Returns the datetime of this commit.- Returns:
- The datetime of this commit.
-
getParentIds
java.util.List<java.lang.String> getParentIds()
Returns the ids of the parents of this commit.- Returns:
- The ids of the parents of this commit.
-
getFileChanges
java.util.List<FileChange> getFileChanges()
Returns the list of file changes.- Returns:
- The list of file changes.
-
getIssues
java.util.List<Issue> getIssues()
Returns the issues referenced by this commit. To enable this feature when processing a repository, set an appropriateITEngine
withVCSEngine.setITEngine(ITEngine)
. The returned list does not contain the same issue (according toIssue.getId()
) twice.- Returns:
- The Issues referenced by this commit.
-
isMerge
default boolean isMerge()
Returns whether this commit is a merge commit. That is, it has more than one parent (seegetParentIds()
).- Returns:
true
if this commit is a merge commit,false
otherwise.
-
-