public class GHPullRequest extends GHIssue
GHRepository.getPullRequest(int)GHIssue.Label, GHIssue.PullRequestassignee, assignees, body, closed_at, closed_by, comments, html_url, labels, milestone, number, pull_request, state, title, usercreated_at, id, updated_at, url| Constructor and Description |
|---|
GHPullRequest() |
| Modifier and Type | Method and Description |
|---|---|
GHPullRequestReviewComment |
createReviewComment(String body,
String sha,
String path,
int position) |
int |
getAdditions() |
protected String |
getApiRoute() |
GHCommitPointer |
getBase()
This points to where the change should be pulled into,
but I'm not really sure what exactly it means.
|
int |
getChangedFiles() |
GHUser |
getClosedBy()
Reports who has closed the issue.
|
int |
getDeletions() |
URL |
getDiffUrl()
The diff file,
like https://github.com/jenkinsci/jenkins/pull/100.diff
|
GHCommitPointer |
getHead()
The change that should be pulled.
|
Date |
getIssueUpdatedAt()
Deprecated.
|
URL |
getIssueUrl()
The URL of the patch file.
|
Collection<GHLabel> |
getLabels() |
Boolean |
getMergeable() |
String |
getMergeableState() |
String |
getMergeCommitSha()
See GitHub blog post
|
Date |
getMergedAt() |
GHUser |
getMergedBy() |
URL |
getPatchUrl()
The URL of the patch file.
|
GHIssue.PullRequest |
getPullRequest()
Returns non-null if this issue is a shadow of a pull request.
|
int |
getReviewComments() |
boolean |
isMerged() |
PagedIterable<GHPullRequestCommitDetail> |
listCommits()
Retrieves all the commits associated to this pull request.
|
PagedIterable<GHPullRequestFileDetail> |
listFiles()
Retrieves all the commits associated to this pull request.
|
PagedIterable<GHPullRequestReviewComment> |
listReviewComments()
Obtains all the review comments associated with this pull request.
|
void |
merge(String msg)
Merge this pull request.
|
void |
merge(String msg,
String sha)
Merge this pull request.
|
addAssignees, addAssignees, assignTo, close, comment, createReaction, getApiURL, getAssignee, getAssignees, getBody, getClosedAt, getComments, getCommentsCount, getHtmlUrl, getIssuesApiRoute, getMilestone, getNumber, getRepository, getState, getTitle, getUser, isPullRequest, listComments, listReactions, removeAssignees, removeAssignees, reopen, setAssignees, setAssignees, setBody, setLabels, setTitlegetCreatedAt, getId, getUpdatedAt, getUrl, toStringprotected String getApiRoute()
getApiRoute in class GHIssuepublic URL getPatchUrl()
public URL getIssueUrl()
public GHCommitPointer getBase()
public GHCommitPointer getHead()
@Deprecated public Date getIssueUpdatedAt() throws IOException
IOExceptionpublic URL getDiffUrl()
public Date getMergedAt()
public Collection<GHLabel> getLabels() throws IOException
getLabels in class GHIssueIOExceptionpublic GHUser getClosedBy()
GHIssueNote that GitHub doesn't always seem to report this information even for an issue that's already closed. See https://github.com/kohsuke/github-api/issues/60.
getClosedBy in class GHIssuepublic GHIssue.PullRequest getPullRequest()
GHIssuegetPullRequest in class GHIssuepublic GHUser getMergedBy() throws IOException
IOExceptionpublic int getReviewComments()
throws IOException
IOExceptionpublic int getAdditions()
throws IOException
IOExceptionpublic boolean isMerged()
throws IOException
IOExceptionpublic Boolean getMergeable() throws IOException
IOExceptionpublic int getDeletions()
throws IOException
IOExceptionpublic String getMergeableState() throws IOException
IOExceptionpublic int getChangedFiles()
throws IOException
IOExceptionpublic String getMergeCommitSha() throws IOException
IOExceptionpublic PagedIterable<GHPullRequestFileDetail> listFiles()
public PagedIterable<GHPullRequestReviewComment> listReviewComments() throws IOException
IOExceptionpublic PagedIterable<GHPullRequestCommitDetail> listCommits()
public GHPullRequestReviewComment createReviewComment(String body, String sha, String path, int position) throws IOException
IOExceptionpublic void merge(String msg) throws IOException
msg - Commit message. If null, the default one will be used.IOExceptionpublic void merge(String msg, String sha) throws IOException
msg - Commit message. If null, the default one will be used.sha - SHA that pull request head must match to allow merge.IOExceptionCopyright © 2017. All rights reserved.