public class IssuesApi extends AbstractApi implements Constants
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
Modifier and Type | Method and Description |
---|---|
TimeStats |
addSpentTime(Object projectIdOrPath,
Integer issueIid,
Duration duration)
Adds spent time for this issue
|
TimeStats |
addSpentTime(Object projectIdOrPath,
Integer issueIid,
int duration)
Adds spent time for this issue
|
TimeStats |
addSpentTime(Object projectIdOrPath,
Integer issueIid,
String duration)
Adds spent time for this issue
|
Issue |
closeIssue(Object projectIdOrPath,
Integer issueIid)
Closes an existing project issue.
|
Issue |
createIssue(Object projectIdOrPath,
String title,
String description)
Create an issue for the project.
|
Issue |
createIssue(Object projectIdOrPath,
String title,
String description,
Boolean confidential,
List<Integer> assigneeIds,
Integer milestoneId,
String labels,
Date createdAt,
Date dueDate,
Integer mergeRequestToResolveId,
Integer discussionToResolveId)
Create an issue for the project.
|
void |
deleteIssue(Object projectIdOrPath,
Integer issueIid)
Delete an issue.
|
TimeStats |
estimateTime(Object projectIdOrPath,
Integer issueIid,
Duration duration)
Sets an estimated time of work in this issue
|
TimeStats |
estimateTime(Object projectIdOrPath,
Integer issueIid,
int duration)
Sets an estimated time of work in this issue
|
TimeStats |
estimateTime(Object projectIdOrPath,
Integer issueIid,
String duration)
Sets an estimated time of work in this issue
|
List<MergeRequest> |
getClosedByMergeRequests(Object projectIdOrPath,
Integer issueIid)
Get list containing all the merge requests that will close issue when merged.
|
Pager<MergeRequest> |
getClosedByMergeRequests(Object projectIdOrPath,
Integer issueIid,
int itemsPerPage)
Get a Pager containing all the merge requests that will close issue when merged.
|
List<MergeRequest> |
getClosedByMergeRequests(Object projectIdOrPath,
Integer issueIid,
int page,
int perPage)
Get list containing all the merge requests that will close issue when merged.
|
Stream<MergeRequest> |
getClosedByMergeRequestsStream(Object projectIdOrPath,
Integer issueIid)
Get list containing all the merge requests that will close issue when merged.
|
Issue |
getIssue(Object projectIdOrPath,
Integer issueIid)
Get a single project issue.
|
List<Issue> |
getIssues()
Get all issues the authenticated user has access to.
|
Pager<Issue> |
getIssues(int itemsPerPage)
Get a Pager of all issues the authenticated user has access to.
|
List<Issue> |
getIssues(int page,
int perPage)
Get all issues the authenticated user has access to using the specified page and per page setting.
|
List<Issue> |
getIssues(IssueFilter filter)
Get all issues the authenticated user has access to.
|
Pager<Issue> |
getIssues(IssueFilter filter,
int itemsPerPage)
Get all issues the authenticated user has access to.
|
List<Issue> |
getIssues(IssueFilter filter,
int page,
int perPage)
Get all issues the authenticated user has access to.
|
List<Issue> |
getIssues(Object projectIdOrPath)
Get a list of project's issues.
|
Pager<Issue> |
getIssues(Object projectIdOrPath,
int itemsPerPage)
Get a Pager of project's issues.
|
List<Issue> |
getIssues(Object projectIdOrPath,
int page,
int perPage)
Get a list of project's issues using the specified page and per page settings.
|
List<Issue> |
getIssues(Object projectIdOrPath,
IssueFilter filter)
Get a list of project's issues.
|
Pager<Issue> |
getIssues(Object projectIdOrPath,
IssueFilter filter,
int itemsPerPage)
Get a list of project's issues.
|
List<Issue> |
getIssues(Object projectIdOrPath,
IssueFilter filter,
int page,
int perPage)
Get a list of project's issues.
|
Stream<Issue> |
getIssuesStream()
Get all issues the authenticated user has access to as a Stream.
|
Stream<Issue> |
getIssuesStream(IssueFilter filter)
Get all issues the authenticated user has access to.
|
Stream<Issue> |
getIssuesStream(Object projectIdOrPath)
Get a Stream of project's issues.
|
Stream<Issue> |
getIssuesStream(Object projectIdOrPath,
IssueFilter filter)
Get a Stream of project's issues.
|
Optional<Issue> |
getOptionalIssue(Object projectIdOrPath,
Integer issueIid)
Get a single project issue as an Optional instance.
|
Optional<TimeStats> |
getOptionalTimeTrackingStats(Object projectIdOrPath,
Integer issueIid)
Get time tracking stats as an Optional instance
|
TimeStats |
getTimeTrackingStats(Object projectIdOrPath,
Integer issueIid)
Get time tracking stats.
|
TimeStats |
resetEstimatedTime(Object projectIdOrPath,
Integer issueIid)
Resets the estimated time for this issue to 0 seconds.
|
TimeStats |
resetSpentTime(Object projectIdOrPath,
Integer issueIid)
Resets the total spent time for this issue to 0 seconds.
|
Issue |
updateIssue(Object projectIdOrPath,
Integer issueIid,
String title,
String description,
Boolean confidential,
List<Integer> assigneeIds,
Integer milestoneId,
String labels,
Constants.StateEvent stateEvent,
Date updatedAt,
Date dueDate)
Updates an existing project issue.
|
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 IssuesApi(GitLabApi gitLabApi)
public List<Issue> getIssues() throws GitLabApiException
GitLab Endpoint: GET /issues
GitLabApiException
- if any exception occurspublic List<Issue> getIssues(int page, int perPage) throws GitLabApiException
GitLab Endpoint: GET /issues
page
- the page to getperPage
- the number of issues per pageGitLabApiException
- if any exception occurspublic Pager<Issue> getIssues(int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /issues
ritemsPerPage
- the number of issues per pageGitLabApiException
- if any exception occurspublic Stream<Issue> getIssuesStream() throws GitLabApiException
GitLab Endpoint: GET /issues
GitLabApiException
- if any exception occurspublic List<Issue> getIssues(Object projectIdOrPath) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceGitLabApiException
- if any exception occurspublic List<Issue> getIssues(Object projectIdOrPath, int page, int perPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancepage
- the page to getperPage
- the number of issues per pageGitLabApiException
- if any exception occurspublic Pager<Issue> getIssues(Object projectIdOrPath, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceitemsPerPage
- the number of issues per pageGitLabApiException
- if any exception occurspublic Stream<Issue> getIssuesStream(Object projectIdOrPath) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceGitLabApiException
- if any exception occurspublic List<Issue> getIssues(Object projectIdOrPath, IssueFilter filter) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancefilter
- IssueFilter
a IssueFilter instance with the filter settingsGitLabApiException
- if any exception occurspublic List<Issue> getIssues(Object projectIdOrPath, IssueFilter filter, int page, int perPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancefilter
- IssueFilter
a IssueFilter instance with the filter settings.page
- the page to get.perPage
- the number of projects per page.GitLabApiException
- if any exception occurspublic Pager<Issue> getIssues(Object projectIdOrPath, IssueFilter filter, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancefilter
- IssueFilter
a IssueFilter instance with the filter settings.itemsPerPage
- the number of Project instances that will be fetched per page.GitLabApiException
- if any exception occurspublic Stream<Issue> getIssuesStream(Object projectIdOrPath, IssueFilter filter) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancefilter
- IssueFilter
a IssueFilter instance with the filter settingsGitLabApiException
- if any exception occurspublic List<Issue> getIssues(IssueFilter filter) throws GitLabApiException
GitLab Endpoint: GET /issues
filter
- IssueFilter
a IssueFilter instance with the filter settingsGitLabApiException
- if any exception occurspublic List<Issue> getIssues(IssueFilter filter, int page, int perPage) throws GitLabApiException
GitLab Endpoint: GET /issues
filter
- IssueFilter
a IssueFilter instance with the filter settings.page
- the page to get.perPage
- the number of projects per page.GitLabApiException
- if any exception occurspublic Pager<Issue> getIssues(IssueFilter filter, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /issues
filter
- IssueFilter
a IssueFilter instance with the filter settings.itemsPerPage
- the number of Project instances that will be fetched per page.GitLabApiException
- if any exception occurspublic Stream<Issue> getIssuesStream(IssueFilter filter) throws GitLabApiException
GitLab Endpoint: GET /issues
filter
- IssueFilter
a IssueFilter instance with the filter settingsGitLabApiException
- if any exception occurspublic Issue getIssue(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic Optional<Issue> getOptionalIssue(Object projectIdOrPath, Integer issueIid)
GitLab Endpoint: GET /projects/:id/issues/:issue_iid
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issuepublic Issue createIssue(Object projectIdOrPath, String title, String description) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancetitle
- the title of an issue, requireddescription
- the description of an issue, optionalGitLabApiException
- if any exception occurspublic Issue createIssue(Object projectIdOrPath, String title, String description, Boolean confidential, List<Integer> assigneeIds, Integer milestoneId, String labels, Date createdAt, Date dueDate, Integer mergeRequestToResolveId, Integer discussionToResolveId) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instancetitle
- the issue title of an issue, requireddescription
- the description of an issue, optionalconfidential
- set the issue to be confidential, default is false, optionalassigneeIds
- the IDs of the users to assign issue, optionalmilestoneId
- the ID of a milestone to assign issue, optionallabels
- comma-separated label names for an issue, optionalcreatedAt
- the date the issue was created at, optionaldueDate
- the due date, optionalmergeRequestToResolveId
- the IID of a merge request in which to resolve all issues. This will fill the issue with a default
description and mark all discussions as resolved. When passing a description or title, these values will take precedence over the default values. OptionaldiscussionToResolveId
- the ID of a discussion to resolve. This will fill in the issue with a default description and mark the discussion as resolved.
Use in combination with merge_request_to_resolve_discussions_of. OptionalGitLabApiException
- if any exception occurspublic Issue closeIssue(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: PUT /projects/:id/issues/:issue_iid
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instance, requiredissueIid
- the issue IID to update, requiredGitLabApiException
- if any exception occurspublic Issue updateIssue(Object projectIdOrPath, Integer issueIid, String title, String description, Boolean confidential, List<Integer> assigneeIds, Integer milestoneId, String labels, Constants.StateEvent stateEvent, Date updatedAt, Date dueDate) throws GitLabApiException
GitLab Endpoint: PUT /projects/:id/issues/:issue_iid
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instance, requiredissueIid
- the issue IID to update, requiredtitle
- the title of an issue, optionaldescription
- the description of an issue, optionalconfidential
- set the issue to be confidential, default is false, optionalassigneeIds
- the IDs of the users to assign issue, optionalmilestoneId
- the ID of a milestone to assign issue, optionallabels
- comma-separated label names for an issue, optionalstateEvent
- the state event of an issue. Set close to close the issue and reopen to reopen it, optionalupdatedAt
- sets the updated date, requires admin or project owner rights, optionaldueDate
- the due date, optionalGitLabApiException
- if any exception occurspublic void deleteIssue(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: DELETE /projects/:id/issues/:issue_iid
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instance, requiredissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic TimeStats estimateTime(Object projectIdOrPath, Integer issueIid, int duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instance, requiredissueIid
- the internal ID of a project's issueduration
- estimated time in secondsGitLabApiException
- if any exception occurspublic TimeStats estimateTime(Object projectIdOrPath, Integer issueIid, String duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instance, requiredissueIid
- the internal ID of a project's issueduration
- Human readable format, e.g. 3h30mGitLabApiException
- if any exception occurspublic TimeStats estimateTime(Object projectIdOrPath, Integer issueIid, Duration duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/time_estimate
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueduration
- set the estimate of time to this durationGitLabApiException
- if any exception occurspublic TimeStats resetEstimatedTime(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/reset_time_estimate
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic TimeStats addSpentTime(Object projectIdOrPath, Integer issueIid, int duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueduration
- the duration in secondsGitLabApiException
- if any exception occurspublic TimeStats addSpentTime(Object projectIdOrPath, Integer issueIid, String duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueduration
- Human readable format, e.g. 3h30mGitLabApiException
- if any exception occurspublic TimeStats addSpentTime(Object projectIdOrPath, Integer issueIid, Duration duration) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/add_spent_time
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueduration
- the duration of time spentGitLabApiException
- if any exception occurspublic TimeStats resetSpentTime(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: POST /projects/:id/issues/:issue_iid/reset_spent_time
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic TimeStats getTimeTrackingStats(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/time_stats
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic Optional<TimeStats> getOptionalTimeTrackingStats(Object projectIdOrPath, Integer issueIid)
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/time_stats
projectIdOrPath
- the project in the form of an Integer(ID), String(path), or Project instanceissueIid
- the internal ID of a project's issuepublic List<MergeRequest> getClosedByMergeRequests(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/closed_by
projectIdOrPath
- id, path of the project, or a Project instance holding the project ID or pathissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occurspublic List<MergeRequest> getClosedByMergeRequests(Object projectIdOrPath, Integer issueIid, int page, int perPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/closed_by
projectIdOrPath
- id, path of the project, or a Project instance holding the project ID or pathissueIid
- the internal ID of a project's issuepage
- the page to getperPage
- the number of issues per pageGitLabApiException
- if any exception occurspublic Pager<MergeRequest> getClosedByMergeRequests(Object projectIdOrPath, Integer issueIid, int itemsPerPage) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/closed_by
projectIdOrPath
- id, path of the project, or a Project instance holding the project ID or pathissueIid
- the internal ID of a project's issueitemsPerPage
- the number of Issue instances that will be fetched per pageGitLabApiException
- if any exception occurspublic Stream<MergeRequest> getClosedByMergeRequestsStream(Object projectIdOrPath, Integer issueIid) throws GitLabApiException
GitLab Endpoint: GET /projects/:id/issues/:issue_iid/closed_by
projectIdOrPath
- id, path of the project, or a Project instance holding the project ID or pathissueIid
- the internal ID of a project's issueGitLabApiException
- if any exception occursCopyright © 2019. All rights reserved.