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
358b8c9a
Unverified
Commit
358b8c9a
authored
Feb 05, 2023
by
Jérémie Bresson
Committed by
GitHub
Feb 05, 2023
Browse files
Add id to ProtectedBranch and BranchAccessLevel (#901)
parent
2be235b8
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/models/BranchAccessLevel.java
View file @
358b8c9a
...
...
@@ -4,11 +4,20 @@ import org.gitlab4j.api.utils.JacksonJson;
public
class
BranchAccessLevel
{
private
Long
id
;
private
AccessLevel
accessLevel
;
private
String
accessLevelDescription
;
private
Long
userId
;
private
Long
groupId
;
public
Long
getId
()
{
return
id
;
}
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
public
AccessLevel
getAccessLevel
()
{
return
this
.
accessLevel
;
}
...
...
src/main/java/org/gitlab4j/api/models/ProtectedBranch.java
View file @
358b8c9a
...
...
@@ -7,12 +7,21 @@ import org.gitlab4j.api.utils.JacksonJson;
public
class
ProtectedBranch
{
private
Long
id
;
private
String
name
;
private
List
<
BranchAccessLevel
>
pushAccessLevels
;
private
List
<
BranchAccessLevel
>
mergeAccessLevels
;
private
List
<
BranchAccessLevel
>
unprotectAccessLevels
;
private
Boolean
codeOwnerApprovalRequired
;
public
Long
getId
()
{
return
id
;
}
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
public
String
getName
()
{
return
this
.
name
;
}
...
...
src/test/resources/org/gitlab4j/api/protected-branch.json
View file @
358b8c9a
{
"id"
:
457
,
"name"
:
"develop"
,
"push_access_levels"
:
[
{
"id"
:
123
,
"access_level"
:
40
,
"access_level_description"
:
"Masters"
},
...
...
@@ -11,6 +13,7 @@
],
"merge_access_levels"
:
[
{
"id"
:
789
,
"access_level"
:
40
,
"access_level_description"
:
"Masters"
},
...
...
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