public class GHCommit extends Object
GHRepository.getCommit(String),
GHCommitComment.getCommit()| Modifier and Type | Class and Description |
|---|---|
static class |
GHCommit.File
A file that was modified.
|
static class |
GHCommit.GHAuthor
Deprecated.
Use
GitUser instead. |
static class |
GHCommit.Parent |
static class |
GHCommit.ShortInfo
Short summary of this commit.
|
static class |
GHCommit.Stats |
| Constructor and Description |
|---|
GHCommit() |
| Modifier and Type | Method and Description |
|---|---|
GHCommitComment |
createComment(String body) |
GHCommitComment |
createComment(String body,
String path,
Integer line,
Integer position)
Creates a commit comment.
|
GHUser |
getAuthor() |
GHCommit.ShortInfo |
getCommitShortInfo() |
GHUser |
getCommitter() |
List<GHCommit.File> |
getFiles()
List of files changed/added/removed in this commit.
|
URL |
getHtmlUrl()
URL of this commit like "https://github.com/kohsuke/sandbox-ant/commit/8ae38db0ea5837313ab5f39d43a6f73de3bd9000"
|
GHCommitStatus |
getLastStatus()
Gets the last status of this commit, which is what gets shown in the UI.
|
int |
getLinesAdded()
Number of lines added.
|
int |
getLinesChanged()
Number of lines added + removed.
|
int |
getLinesDeleted()
Number of lines removed.
|
GHRepository |
getOwner()
The repository that contains the commit.
|
List<GHCommit> |
getParents()
Resolves the parent commit objects and return them.
|
List<String> |
getParentSHA1s()
Returns the SHA1 of parent commit objects.
|
String |
getSHA1()
[0-9a-f]{40} SHA1 checksum.
|
PagedIterable<GHCommitComment> |
listComments()
Lists up all the commit comments in this repository.
|
PagedIterable<GHCommitStatus> |
listStatuses()
Gets the status of this commit, newer ones first.
|
public GHCommit.ShortInfo getCommitShortInfo() throws IOException
IOExceptionpublic GHRepository getOwner()
public int getLinesChanged()
throws IOException
IOExceptionpublic int getLinesAdded()
throws IOException
IOExceptionpublic int getLinesDeleted()
throws IOException
IOExceptionpublic URL getHtmlUrl()
public String getSHA1()
public List<GHCommit.File> getFiles() throws IOException
IOExceptionpublic List<GHCommit> getParents() throws IOException
IOExceptionpublic GHUser getAuthor() throws IOException
IOExceptionpublic GHUser getCommitter() throws IOException
IOExceptionpublic PagedIterable<GHCommitComment> listComments()
public GHCommitComment createComment(String body, String path, Integer line, Integer position) throws IOException
IOExceptionpublic GHCommitComment createComment(String body) throws IOException
IOExceptionpublic PagedIterable<GHCommitStatus> listStatuses() throws IOException
IOExceptionpublic GHCommitStatus getLastStatus() throws IOException
IOExceptionCopyright © 2016. All Rights Reserved.