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
211f823d
Commit
211f823d
authored
Sep 24, 2019
by
Greg Messner
Browse files
Added empty_repo field to Project class (#435).
parent
f214d82b
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/models/Project.java
View file @
211f823d
...
@@ -84,6 +84,7 @@ public class Project {
...
@@ -84,6 +84,7 @@ public class Project {
private
ProjectStatistics
statistics
;
private
ProjectStatistics
statistics
;
private
Boolean
initializeWithReadme
;
private
Boolean
initializeWithReadme
;
private
Boolean
packagesEnabled
;
private
Boolean
packagesEnabled
;
private
Boolean
emptyRepo
;
public
Integer
getApprovalsBeforeMerge
()
{
public
Integer
getApprovalsBeforeMerge
()
{
return
approvalsBeforeMerge
;
return
approvalsBeforeMerge
;
...
@@ -638,6 +639,14 @@ public class Project {
...
@@ -638,6 +639,14 @@ public class Project {
this
.
statistics
=
statistics
;
this
.
statistics
=
statistics
;
}
}
public
Boolean
getEmptyRepo
()
{
return
emptyRepo
;
}
public
void
setEmptyRepo
(
Boolean
emptyRepo
)
{
this
.
emptyRepo
=
emptyRepo
;
}
public
static
final
boolean
isValid
(
Project
project
)
{
public
static
final
boolean
isValid
(
Project
project
)
{
return
(
project
!=
null
&&
project
.
getId
()
!=
null
);
return
(
project
!=
null
&&
project
.
getId
()
!=
null
);
}
}
...
...
src/test/resources/org/gitlab4j/api/project.json
View file @
211f823d
...
@@ -44,6 +44,7 @@
...
@@ -44,6 +44,7 @@
"notification_level"
:
3
"notification_level"
:
3
}
}
},
},
"empty_repo"
:
true
,
"archived"
:
false
,
"archived"
:
false
,
"avatar_url"
:
"http://example.com/uploads/project/avatar/3/uploads/avatar.png"
,
"avatar_url"
:
"http://example.com/uploads/project/avatar/3/uploads/avatar.png"
,
"shared_runners_enabled"
:
true
,
"shared_runners_enabled"
:
true
,
...
...
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