Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
佳 邓
Gitlab4j Api
Commits
07c3aab0
Commit
07c3aab0
authored
Mar 17, 2017
by
Matteo Facchinetti
Browse files
add an API to get a list of project's issues
Signed-off-by:
Matteo Facchinetti
<
matteo.facchinetti@sirius-es.it
>
parent
fa32315d
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/ProjectApi.java
View file @
07c3aab0
package
org.gitlab4j.api
;
package
org.gitlab4j.api
;
import
org.gitlab4j.api.models.Event
;
import
org.gitlab4j.api.models.Event
;
import
org.gitlab4j.api.models.Issue
;
import
org.gitlab4j.api.models.Member
;
import
org.gitlab4j.api.models.Member
;
import
org.gitlab4j.api.models.Project
;
import
org.gitlab4j.api.models.Project
;
import
org.gitlab4j.api.models.ProjectHook
;
import
org.gitlab4j.api.models.ProjectHook
;
...
@@ -460,4 +461,19 @@ public class ProjectApi extends AbstractApi {
...
@@ -460,4 +461,19 @@ public class ProjectApi extends AbstractApi {
Response
response
=
put
(
Response
.
Status
.
OK
,
formData
.
asMap
(),
"projects"
,
hook
.
getProjectId
(),
"hooks"
,
hook
.
getId
());
Response
response
=
put
(
Response
.
Status
.
OK
,
formData
.
asMap
(),
"projects"
,
hook
.
getProjectId
(),
"hooks"
,
hook
.
getId
());
return
(
response
.
readEntity
(
ProjectHook
.
class
));
return
(
response
.
readEntity
(
ProjectHook
.
class
));
}
}
/**
* Get a list of project's issues.
*
* GET /projects/:id/issues
*
* @param projectId
* @return a list of project's issues
* @throws GitLabApiException
*/
public
List
<
Issue
>
getIssues
(
Integer
projectId
)
throws
GitLabApiException
{
Response
response
=
get
(
Response
.
Status
.
OK
,
null
,
"projects"
,
projectId
,
"issues"
);
return
(
response
.
readEntity
(
new
GenericType
<
List
<
Issue
>>()
{
}));
}
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment