Skip to content

Commit a20807b

Browse files
authored
Merge branch 'gitlab4j:main' into main
2 parents d490e50 + d1e1f05 commit a20807b

26 files changed

+1414
-125
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ To utilize GitLab4J™ API in your Java project, simply add the following de
3131
```java
3232
dependencies {
3333
...
34-
implementation group: 'org.gitlab4j', name: 'gitlab4j-api', version: '6.0.0-rc.7'
34+
implementation group: 'org.gitlab4j', name: 'gitlab4j-api', version: '6.0.0-rc.8'
3535
}
3636
```
3737

@@ -40,7 +40,7 @@ dependencies {
4040
<dependency>
4141
<groupId>org.gitlab4j</groupId>
4242
<artifactId>gitlab4j-api</artifactId>
43-
<version>6.0.0-rc.7</version>
43+
<version>6.0.0-rc.8</version>
4444
</dependency>
4545
```
4646

@@ -51,7 +51,7 @@ dependencies {
5151
Just add this line at the top of your script:
5252

5353
```java
54-
//DEPS org.gitlab4j:gitlab4j-api:6.0.0-rc.7
54+
//DEPS org.gitlab4j:gitlab4j-api:6.0.0-rc.8
5555
```
5656

5757
**Ivy and SBT**<br/>
@@ -146,7 +146,7 @@ Those projects might want to use the Jackson-based model classes, and implement
146146
```java
147147
dependencies {
148148
...
149-
implementation 'org.gitlab4j:gitlab4j-models:6.0.0-rc.7'
149+
implementation 'org.gitlab4j:gitlab4j-models:6.0.0-rc.8'
150150
}
151151
```
152152

@@ -155,7 +155,7 @@ dependencies {
155155
<dependency>
156156
<groupId>org.gitlab4j</groupId>
157157
<artifactId>gitlab4j-models</artifactId>
158-
<version>6.0.0-rc.7</version>
158+
<version>6.0.0-rc.8</version>
159159
</dependency>
160160
```
161161

gitlab4j-api/src/main/java/org/gitlab4j/api/BoardsApi.java

Lines changed: 1041 additions & 96 deletions
Large diffs are not rendered by default.

gitlab4j-models/src/main/java/org/gitlab4j/api/models/AbstractEpic.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
import com.fasterxml.jackson.annotation.JsonIgnore;
1313
import com.fasterxml.jackson.annotation.JsonProperty;
1414
import com.fasterxml.jackson.annotation.JsonValue;
15+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
1516

1617
public class AbstractEpic<E extends AbstractEpic<E>> extends AbstractMinimalEpic<E> implements Serializable {
1718
private static final long serialVersionUID = 1L;
@@ -45,9 +46,16 @@ public String toString() {
4546
private References references;
4647
private Author author;
4748
private List<String> labels;
49+
50+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
4851
private Date startDate;
52+
53+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
4954
private Date dueDate;
55+
56+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
5057
private Date endDate;
58+
5159
private Date createdAt;
5260
private Date updatedAt;
5361
private Date closedAt;

gitlab4j-models/src/main/java/org/gitlab4j/api/models/AbstractUser.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ public abstract class AbstractUser<U extends AbstractUser<U>> implements Seriali
1717
private Long id;
1818
private String name;
1919
private String state;
20+
private Boolean locked;
2021
private String username;
2122
private String webUrl;
2223

@@ -60,6 +61,14 @@ public void setName(String name) {
6061
this.name = name;
6162
}
6263

64+
public Boolean getLocked() {
65+
return locked;
66+
}
67+
68+
public void setLocked(Boolean locked) {
69+
this.locked = locked;
70+
}
71+
6372
public String getState() {
6473
return state;
6574
}

gitlab4j-models/src/main/java/org/gitlab4j/api/models/Board.java

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,15 @@ public class Board implements Serializable {
1010

1111
private Long id;
1212
private String name;
13+
private Boolean hideBacklogList;
14+
private Boolean hideClosedList;
1315
private Project project;
14-
private Milestone milestone;
1516
private List<BoardList> lists;
17+
private Group group;
18+
private Milestone milestone;
19+
private Assignee assignee;
20+
private List<Label> labels;
21+
private Integer weight;
1622

1723
public Long getId() {
1824
return id;
@@ -30,6 +36,22 @@ public void setName(String name) {
3036
this.name = name;
3137
}
3238

39+
public Boolean getHideBacklogList() {
40+
return hideBacklogList;
41+
}
42+
43+
public void setHideBacklogList(Boolean hideBacklogList) {
44+
this.hideBacklogList = hideBacklogList;
45+
}
46+
47+
public Boolean getHideClosedList() {
48+
return hideClosedList;
49+
}
50+
51+
public void setHideClosedList(Boolean hideClosedList) {
52+
this.hideClosedList = hideClosedList;
53+
}
54+
3355
public Project getProject() {
3456
return project;
3557
}
@@ -54,6 +76,38 @@ public void setLists(List<BoardList> lists) {
5476
this.lists = lists;
5577
}
5678

79+
public Group getGroup() {
80+
return group;
81+
}
82+
83+
public void setGroup(Group group) {
84+
this.group = group;
85+
}
86+
87+
public Assignee getAssignee() {
88+
return assignee;
89+
}
90+
91+
public void setAssignee(Assignee assignee) {
92+
this.assignee = assignee;
93+
}
94+
95+
public List<Label> getLabels() {
96+
return labels;
97+
}
98+
99+
public void setLabels(List<Label> labels) {
100+
this.labels = labels;
101+
}
102+
103+
public Integer getWeight() {
104+
return weight;
105+
}
106+
107+
public void setWeight(Integer weight) {
108+
this.weight = weight;
109+
}
110+
57111
@Override
58112
public String toString() {
59113
return (JacksonJson.toJsonString(this));

gitlab4j-models/src/main/java/org/gitlab4j/api/models/BoardList.java

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ public class BoardList implements Serializable {
1010
private Long id;
1111
private Label label;
1212
private Integer position;
13+
private Assignee assignee;
14+
private Milestone milestone;
15+
private Iteration iteration;
16+
private Integer maxIssueCount;
17+
private Integer maxIssueWeight;
18+
private Integer limitMetric;
19+
private String listType;
1320

1421
public Long getId() {
1522
return id;
@@ -35,6 +42,62 @@ public void setPosition(Integer position) {
3542
this.position = position;
3643
}
3744

45+
public Assignee getAssignee() {
46+
return assignee;
47+
}
48+
49+
public void setAssignee(Assignee assignee) {
50+
this.assignee = assignee;
51+
}
52+
53+
public Milestone getMilestone() {
54+
return milestone;
55+
}
56+
57+
public void setMilestone(Milestone milestone) {
58+
this.milestone = milestone;
59+
}
60+
61+
public Iteration getIteration() {
62+
return iteration;
63+
}
64+
65+
public void setIteration(Iteration iteration) {
66+
this.iteration = iteration;
67+
}
68+
69+
public Integer getMaxIssueCount() {
70+
return maxIssueCount;
71+
}
72+
73+
public void setMaxIssueCount(Integer maxIssueCount) {
74+
this.maxIssueCount = maxIssueCount;
75+
}
76+
77+
public Integer getMaxIssueWeight() {
78+
return maxIssueWeight;
79+
}
80+
81+
public void setMaxIssueWeight(Integer maxIssueWeight) {
82+
this.maxIssueWeight = maxIssueWeight;
83+
}
84+
85+
public Integer getLimitMetric() {
86+
return limitMetric;
87+
}
88+
89+
public void setLimitMetric(Integer limitMetric) {
90+
this.limitMetric = limitMetric;
91+
}
92+
93+
public String getListType() {
94+
return listType;
95+
}
96+
97+
public void setListType(String listType) {
98+
this.listType = listType;
99+
}
100+
38101
@Override
39102
public String toString() {
40103
return (JacksonJson.toJsonString(this));

gitlab4j-models/src/main/java/org/gitlab4j/api/models/Epic.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,17 @@
44

55
import org.gitlab4j.models.utils.JacksonJson;
66

7+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
8+
79
public class Epic extends AbstractEpic<Epic> {
810
private static final long serialVersionUID = 1L;
911

1012
private Boolean startDateIsFixed;
1113
private Boolean dueDateIsFixed;
14+
15+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
1216
private Date dueDateFromInheritedSource;
17+
1318
private Boolean subscribed;
1419

1520
public Boolean getStartDateIsFixed() {

gitlab4j-models/src/main/java/org/gitlab4j/api/models/ImpersonationToken.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
import com.fasterxml.jackson.annotation.JsonCreator;
1111
import com.fasterxml.jackson.annotation.JsonValue;
12+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
1213

1314
public class ImpersonationToken implements Serializable {
1415
private static final long serialVersionUID = 1L;
@@ -52,6 +53,8 @@ public String toString() {
5253
private Date createdAt;
5354
private Date lastUsedAt;
5455
private Boolean impersonation;
56+
57+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
5558
private Date expiresAt;
5659

5760
public Boolean getActive() {

gitlab4j-models/src/main/java/org/gitlab4j/api/models/Iteration.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
import com.fasterxml.jackson.annotation.JsonCreator;
99
import com.fasterxml.jackson.annotation.JsonValue;
10+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
1011

1112
public class Iteration implements Serializable {
1213
private static final long serialVersionUID = 1L;
@@ -52,8 +53,13 @@ public String toString() {
5253
private IterationState state;
5354
private Date createdAt;
5455
private Date updatedAt;
56+
57+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
5558
private Date startDate;
59+
60+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
5661
private Date dueDate;
62+
5763
private String webUrl;
5864

5965
public Long getId() {

gitlab4j-models/src/main/java/org/gitlab4j/api/models/Label.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ public class Label implements Serializable {
1515
private String color;
1616
private String description;
1717
private String descriptionHtml;
18+
private String textColor;
1819
private Integer openIssuesCount;
1920
private Integer closedIssuesCount;
2021
private Integer openMergeRequestsCount;
@@ -77,6 +78,14 @@ public void setDescriptionHtml(String descriptionHtml) {
7778
this.descriptionHtml = descriptionHtml;
7879
}
7980

81+
public String getTextColor() {
82+
return textColor;
83+
}
84+
85+
public void setTextColor(String textColor) {
86+
this.textColor = textColor;
87+
}
88+
8089
public Integer getOpenIssuesCount() {
8190
return openIssuesCount;
8291
}

gitlab4j-models/src/main/java/org/gitlab4j/api/models/ProjectAccessToken.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,18 @@
77
import org.gitlab4j.models.Constants;
88
import org.gitlab4j.models.utils.JacksonJson;
99

10+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
11+
1012
public class ProjectAccessToken implements Serializable {
1113
private static final long serialVersionUID = 1L;
1214

1315
private Long userId;
1416
private List<Constants.ProjectAccessTokenScope> scopes;
1517
private String name;
18+
19+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
1620
private Date expiresAt;
21+
1722
private Long id;
1823
private Boolean active;
1924
private Date createdAt;

gitlab4j-models/src/main/java/org/gitlab4j/api/models/RelatedEpic.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,17 @@
44

55
import org.gitlab4j.models.utils.JacksonJson;
66

7+
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
8+
79
public class RelatedEpic extends AbstractEpic<RelatedEpic> {
810
private static final long serialVersionUID = 1L;
911

1012
private Boolean startDateIsFixed;
1113
private Boolean dueDateIsFixed;
14+
15+
@JsonSerialize(using = JacksonJson.DateOnlySerializer.class)
1216
private Date dueDateFromInheritedSource;
17+
1318
private Long relatedEpicLinkId;
1419
private LinkType linkType;
1520
private Date linkCreatedAt;

gitlab4j-models/src/test/java/org/gitlab4j/models/TestGitLabApiBeans.java

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,23 @@ public void testBlame() throws Exception {
7878
}
7979

8080
@Test
81-
public void testBoard() throws Exception {
81+
public void testProjectBoard() throws Exception {
8282
List<Board> boards = unmarshalResourceList(Board.class, "project-board.json");
8383
assertTrue(compareJson(boards, "project-board.json"));
8484
}
8585

86+
@Test
87+
public void testGroupBoard() throws Exception {
88+
List<Board> boards = unmarshalResourceList(Board.class, "group-board.json");
89+
assertTrue(compareJson(boards, "group-board.json"));
90+
}
91+
92+
@Test
93+
public void testGroupEpicBoard() throws Exception {
94+
Board board = unmarshalResource(Board.class, "group-epic-board.json");
95+
assertTrue(compareJson(board, "group-epic-board.json"));
96+
}
97+
8698
@Test
8799
public void testBranch() throws Exception {
88100

0 commit comments

Comments
 (0)