Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
java-gitlab-api
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
沈俊林
java-gitlab-api
Commits
36e858e3
Commit
36e858e3
authored
Jan 30, 2017
by
Brian Krische
Committed by
Tim Olshansky
Jan 30, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add support for projects shared with a group. (#185)
parent
efd607fe
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
62 additions
and
0 deletions
+62
-0
GitlabGroup.java
src/main/java/org/gitlab/api/models/GitlabGroup.java
+13
-0
GitlabProject.java
src/main/java/org/gitlab/api/models/GitlabProject.java
+11
-0
GitlabProjectSharedGroup.java
.../java/org/gitlab/api/models/GitlabProjectSharedGroup.java
+38
-0
No files found.
src/main/java/org/gitlab/api/models/GitlabGroup.java
View file @
36e858e3
...
...
@@ -2,6 +2,8 @@ package org.gitlab.api.models;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
java.util.List
;
public
class
GitlabGroup
{
public
static
final
String
URL
=
"/groups"
;
...
...
@@ -16,6 +18,9 @@ public class GitlabGroup {
@JsonProperty
(
"ldap_access"
)
private
Integer
ldapAccess
;
@JsonProperty
(
"shared_projects"
)
private
List
<
GitlabProject
>
sharedProjects
;
public
Integer
getId
()
{
return
id
;
}
...
...
@@ -60,4 +65,12 @@ public class GitlabGroup {
this
.
ldapAccess
=
ldapGitlabAccessLevel
.
accessValue
;
}
}
public
List
<
GitlabProject
>
getSharedProjects
()
{
return
sharedProjects
;
}
public
void
setSharedProjects
(
List
<
GitlabProject
>
sharedProjects
)
{
this
.
sharedProjects
=
sharedProjects
;
}
}
src/main/java/org/gitlab/api/models/GitlabProject.java
View file @
36e858e3
...
...
@@ -95,6 +95,9 @@ public class GitlabProject {
@JsonProperty
(
"tag_list"
)
private
List
<
String
>
tagList
;
@JsonProperty
(
"shared_with_groups"
)
private
List
<
GitlabProjectSharedGroup
>
sharedWithGroups
;
public
Integer
getId
()
{
return
id
;
}
...
...
@@ -350,4 +353,12 @@ public class GitlabProject {
public
void
setTagList
(
List
<
String
>
tagList
)
{
this
.
tagList
=
tagList
;
}
public
List
<
GitlabProjectSharedGroup
>
getSharedWithGroups
()
{
return
sharedWithGroups
;
}
public
void
setSharedWithGroups
(
List
<
GitlabProjectSharedGroup
>
sharedWithGroups
)
{
this
.
sharedWithGroups
=
sharedWithGroups
;
}
}
src/main/java/org/gitlab/api/models/GitlabProjectSharedGroup.java
0 → 100644
View file @
36e858e3
package
org
.
gitlab
.
api
.
models
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
public
class
GitlabProjectSharedGroup
{
@JsonProperty
(
"group_id"
)
private
int
groupId
;
@JsonProperty
(
"group_name"
)
private
String
groupName
;
@JsonProperty
(
"group_access_level"
)
private
int
groupAccessLevel
;
public
int
getGroupId
()
{
return
groupId
;
}
public
void
setGroupId
(
int
groupId
)
{
this
.
groupId
=
groupId
;
}
public
String
getGroupName
()
{
return
groupName
;
}
public
void
setGroupName
(
String
groupName
)
{
this
.
groupName
=
groupName
;
}
public
GitlabAccessLevel
getAccessLevel
()
{
return
GitlabAccessLevel
.
fromAccessValue
(
groupAccessLevel
);
}
public
void
setAccessLevel
(
GitlabAccessLevel
accessLevel
)
{
this
.
groupAccessLevel
=
accessLevel
.
accessValue
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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