public class DiscussionsApi extends AbstractApi
Constants.ActionType, Constants.ArchiveFormat, Constants.CommitBuildState, Constants.EpicOrderBy, Constants.GroupOrderBy, Constants.ImpersonationState, Constants.IssueOrderBy, Constants.IssueScope, Constants.IssueState, Constants.JobScope, Constants.LineType, Constants.MergeRequestOrderBy, Constants.MergeRequestScope, Constants.MergeRequestState, Constants.MilestoneState, Constants.PipelineOrderBy, Constants.PipelineScope, Constants.ProjectOrderBy, Constants.SortOrder, Constants.StateEvent, Constants.TargetType, Constants.TokenType
NEXT_PAGE_HEADER, PAGE_HEADER, PAGE_PARAM, PER_PAGE, PER_PAGE_PARAM, PREV_PAGE_HEADER, TOTAL_HEADER, TOTAL_PAGES_HEADER
Constructor and Description |
---|
DiscussionsApi(GitLabApi gitLabApi) |
Modifier and Type | Method and Description |
---|---|
Discussion |
createMergeRequestDiscussion(Object projectIdOrPath,
Integer mergeRequestIid,
String body,
Date createdAt,
String positionHash,
Position position)
Creates a new discussion to a single project merge request.
|
void |
deleteMergeRequestDiscussionNote(Object projectIdOrPath,
Integer mergeRequestIid,
Integer discussionId,
Integer noteId)
Deletes an existing discussion note of a merge request.
|
List<Discussion> |
getCommitDiscussions(Object projectIdOrPath,
Integer commitId)
Get a list of all discussions for the specified commit.
|
List<Discussion> |
getCommitDiscussions(Object projectIdOrPath,
Integer commitId,
int maxItems)
Get a list of discussions for the specified commit.
|
Pager<Discussion> |
getCommitDiscussionsPager(Object projectIdOrPath,
Integer commitId,
int itemsPerPage)
Get a Pager of Discussion instances for the specified commit.
|
Stream<Discussion> |
getCommitDiscussionsStream(Object projectIdOrPath,
Integer commitId)
Get a Stream of Discussion instances for the specified commit.
|
List<Discussion> |
getEpicDiscussions(Object projectIdOrPath,
Integer epicId)
Get a list of all discussions for the specified epic.
|
List<Discussion> |
getEpicDiscussions(Object projectIdOrPath,
Integer epicId,
int maxItems)
Get a list of discussions for the specified epic.
|
Pager<Discussion> |
getEpicDiscussionsPager(Object projectIdOrPath,
Integer epicId,
int itemsPerPage)
Get a Pager of Discussion instances for the specified epic.
|
Stream<Discussion> |
getEpicDiscussionsStream(Object projectIdOrPath,
Integer epicId)
Get a Stream of Discussion instances for the specified epic.
|
List<Discussion> |
getIssueDiscussions(Object projectIdOrPath,
Integer issueIid)
Get a list of all discussions for the specified issue.
|
List<Discussion> |
getIssueDiscussions(Object projectIdOrPath,
Integer issueIid,
int maxItems)
Get a list of discussions for the specified issue.
|
Pager<Discussion> |
getIssueDiscussionsPager(Object projectIdOrPath,
Integer issueIid,
int itemsPerPage)
Get a Pager of Discussion instances for the specified issue.
|
Stream<Discussion> |
getIssueDiscussionsStream(Object projectIdOrPath,
Integer issueIid)
Get a Stream of Discussion instances for the specified issue.
|
List<Discussion> |
getMergeRequestDiscussions(Object projectIdOrPath,
Integer mergeRequestIid)
Get a list of all discussions for the specified merge request.
|
List<Discussion> |
getMergeRequestDiscussions(Object projectIdOrPath,
Integer mergeRequestIid,
int maxItems)
Get a list of discussions for the specified merge request.
|
Pager<Discussion> |
getMergeRequestDiscussionsPager(Object projectIdOrPath,
Integer mergeRequestIid,
int itemsPerPage)
Get a Pager of Discussion instances for the specified merge request.
|
Stream<Discussion> |
getMergeRequestDiscussionsStream(Object projectIdOrPath,
Integer mergeRequestIid)
Get a Stream of Discussion instances for the specified merge request.
|
List<Discussion> |
getSnippetDiscussions(Object projectIdOrPath,
Integer snippetId)
Get a list of all discussions for the specified snippet.
|
List<Discussion> |
getSnippetDiscussions(Object projectIdOrPath,
Integer snippetId,
int maxItems)
Get a list of discussions for the specified snippet.
|
Pager<Discussion> |
getSnippetDiscussionsPager(Object projectIdOrPath,
Integer snippetId,
int itemsPerPage)
Get a Pager of Discussion instances for the specified snippet.
|
Stream<Discussion> |
getSnippetDiscussionsStream(Object projectIdOrPath,
Integer snippetId)
Get a Stream of Discussion instances for the specified snippet.
|
Discussion |
resolveMergeRequestDiscussion(Object projectIdOrPath,
Integer mergeRequestIid,
Integer discussionId,
Boolean resolved)
Resolve or unresolve whole discussion of a merge request.
|
addFormParam, addFormParam, delete, delete, get, get, getApiClient, getApiVersion, getDefaultPerPage, getDefaultPerPageParam, getDefaultPerPageParam, getGroupIdOrPath, getPageQueryParams, getPageQueryParams, getPerPageQueryParam, getProjectIdOrPath, getUserIdOrUsername, getWithAccepts, handle, head, isApiVersion, post, post, post, post, post, put, put, putUpload, putUpload, putWithFormData, upload, upload, upload, urlEncode, validate
public DiscussionsApi(GitLabApi gitLabApi)
public List<Discussion> getIssueDiscussions(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of the issueGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getIssueDiscussions(Object projectIdOrPath, Integer issueIid, int maxItems) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of the issuemaxItems
- the maximum number of Discussion instances to get, if < 1 will fetch all Discussion instances for the issueGitLabApiException
- if any exception occurs during executionpublic Pager<Discussion> getIssueDiscussionsPager(Object projectIdOrPath, Integer issueIid, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of the issueitemsPerPage
- the number of Discussion instances that will be fetched per pageGitLabApiException
- if any exception occurs during executionpublic Stream<Discussion> getIssueDiscussionsStream(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of the issueGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getSnippetDiscussions(Object projectIdOrPath, Integer snippetId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/snippets/:snippet_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancesnippetId
- the ID of the snippetGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getSnippetDiscussions(Object projectIdOrPath, Integer snippetId, int maxItems) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/snippets/:snippet_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancesnippetId
- the ID of the snippetmaxItems
- the maximum number of Discussion instances to get, if < 1 will fetch all Discussion instances for the snippetGitLabApiException
- if any exception occurs during executionpublic Pager<Discussion> getSnippetDiscussionsPager(Object projectIdOrPath, Integer snippetId, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/snippets/:snippet_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancesnippetId
- the ID of the snippetitemsPerPage
- the number of Discussion instances that will be fetched per pageGitLabApiException
- if any exception occurs during executionpublic Stream<Discussion> getSnippetDiscussionsStream(Object projectIdOrPath, Integer snippetId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/snippets/:snippet_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancesnippetId
- the ID of the snippetGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getEpicDiscussions(Object projectIdOrPath, Integer epicId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/epics/:epic_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceepicId
- the internal ID of the epicGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getEpicDiscussions(Object projectIdOrPath, Integer epicId, int maxItems) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/epics/:epic_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceepicId
- the internal ID of the epicmaxItems
- the maximum number of Discussion instances to get, if < 1 will fetch all Discussion instances for the epicGitLabApiException
- if any exception occurs during executionpublic Pager<Discussion> getEpicDiscussionsPager(Object projectIdOrPath, Integer epicId, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/epics/:epic_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceepicId
- the internal ID of the epicitemsPerPage
- the number of Discussion instances that will be fetched per pageGitLabApiException
- if any exception occurs during executionpublic Stream<Discussion> getEpicDiscussionsStream(Object projectIdOrPath, Integer epicId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/epics/:epic_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instanceepicId
- the internal ID of the epicGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getMergeRequestDiscussions(Object projectIdOrPath, Integer mergeRequestIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/merge_requests/:merge_request_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- the internal ID of the merge requestGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getMergeRequestDiscussions(Object projectIdOrPath, Integer mergeRequestIid, int maxItems) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/merge_requests/:merge_request_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- the internal ID of the merge requestmaxItems
- the maximum number of Discussion instances to get, if < 1 will fetch all Discussion instances for the merge requestGitLabApiException
- if any exception occurs during executionpublic Pager<Discussion> getMergeRequestDiscussionsPager(Object projectIdOrPath, Integer mergeRequestIid, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/merge_requests/:merge_request_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- the internal ID of the merge requestitemsPerPage
- the number of Discussion instances that will be fetched per pageGitLabApiException
- if any exception occurs during executionpublic Stream<Discussion> getMergeRequestDiscussionsStream(Object projectIdOrPath, Integer mergeRequestIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- the internal ID of the merge requestGitLabApiException
- if any exception occurs during executionpublic Discussion createMergeRequestDiscussion(Object projectIdOrPath, Integer mergeRequestIid, String body, Date createdAt, String positionHash, Position position) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/merge_requests/:merge_request_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- mergeRequestIid the internal ID of the merge requestbody
- the content of a discussioncreatedAt
- date the discussion was created (requires admin or project/group owner rights)positionHash
- position when creating a diff noteposition
- a Position instance holding the position attributesGitLabApiException
- if any exception occurs during executionpublic Discussion resolveMergeRequestDiscussion(Object projectIdOrPath, Integer mergeRequestIid, Integer discussionId, Boolean resolved) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/merge_requests/:merge_request_iid/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- mergeRequestIid the internal ID of the merge requestdiscussionId
- the ID of a discussionresolved
- resolve/unresolve the discussionGitLabApiException
- if any exception occurs during executionpublic void deleteMergeRequestDiscussionNote(Object projectIdOrPath, Integer mergeRequestIid, Integer discussionId, Integer noteId) throws GitLabApiException
GitLab Endpoint: DELETE /projects/:id/merge_requests/:merge_request_iid/discussions/:discussion_id/notes/:note_id
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancemergeRequestIid
- mergeRequestIid the internal ID of the merge requestdiscussionId
- the ID of a discussionnoteId
- the note ID to deleteGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getCommitDiscussions(Object projectIdOrPath, Integer commitId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/commits/:commit_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancecommitId
- the internal ID of the commitGitLabApiException
- if any exception occurs during executionpublic List<Discussion> getCommitDiscussions(Object projectIdOrPath, Integer commitId, int maxItems) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/commits/:commit_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancecommitId
- the internal ID of the commitmaxItems
- the maximum number of Discussion instances to get, if < 1 will fetch all Discussion instances for the commitGitLabApiException
- if any exception occurs during executionpublic Pager<Discussion> getCommitDiscussionsPager(Object projectIdOrPath, Integer commitId, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/commits/:commit_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancecommitId
- the internal ID of the commititemsPerPage
- the number of Discussion instances that will be fetched per pageGitLabApiException
- if any exception occurs during executionpublic Stream<Discussion> getCommitDiscussionsStream(Object projectIdOrPath, Integer commitId) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/commits/:commit_id/discussions
projectIdOrPath
- projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instancecommitId
- the internal ID of the commitGitLabApiException
- if any exception occurs during executionCopyright © 2019. All rights reserved.