Commit 14a437f8 authored by Greg Messner's avatar Greg Messner
Browse files

Added missing fields (#241).

parent a5ca728b
package org.gitlab4j.api.models; package org.gitlab4j.api.models;
import java.util.Date; import java.util.Date;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlRootElement;
...@@ -14,6 +16,7 @@ public class Job { ...@@ -14,6 +16,7 @@ public class Job {
private String coverage; private String coverage;
private Date createdAt; private Date createdAt;
private Date finishedAt; private Date finishedAt;
private Date artifactsExpireAt;
private String name; private String name;
private Pipeline pipeline; private Pipeline pipeline;
private String ref; private String ref;
...@@ -21,7 +24,9 @@ public class Job { ...@@ -21,7 +24,9 @@ public class Job {
private User user; private User user;
private Date startedAt; private Date startedAt;
private ArtifactsFile artifactsFile; private ArtifactsFile artifactsFile;
private List<Artifact> artifacts;
private Boolean tag; private Boolean tag;
private String webUrl;
private String stage; private String stage;
private JobStatus status; private JobStatus status;
...@@ -57,6 +62,14 @@ public class Job { ...@@ -57,6 +62,14 @@ public class Job {
this.finishedAt = finishedAt; this.finishedAt = finishedAt;
} }
public Date getArtifactsExpireAt() {
return artifactsExpireAt;
}
public void setArtifactsExpireAt(Date artifactsExpireAt) {
this.artifactsExpireAt = artifactsExpireAt;
}
public String getName() { public String getName() {
return name; return name;
} }
...@@ -105,6 +118,14 @@ public class Job { ...@@ -105,6 +118,14 @@ public class Job {
this.tag = tag; this.tag = tag;
} }
public String getWebUrl() {
return webUrl;
}
public void setWebUrl(String webUrl) {
this.webUrl = webUrl;
}
public String getStage() { public String getStage() {
return stage; return stage;
} }
...@@ -137,6 +158,14 @@ public class Job { ...@@ -137,6 +158,14 @@ public class Job {
this.artifactsFile = artifactsFile; this.artifactsFile = artifactsFile;
} }
public List<Artifact> getArtifacts() {
return artifacts;
}
public void setArtifacts(List<Artifact> artifacts) {
this.artifacts = artifacts;
}
public Runner getRunner() { public Runner getRunner() {
return runner; return runner;
} }
...@@ -145,7 +174,6 @@ public class Job { ...@@ -145,7 +174,6 @@ public class Job {
this.runner = runner; this.runner = runner;
} }
public Job withId(Integer id) { public Job withId(Integer id) {
this.id = id; this.id = id;
return this; return this;
......
{ {
"commit": { "commit": {
"author_email": "admin@example.com", "author_email": "admin@example.com",
"author_name": "Administrator", "author_name": "Administrator",
"created_at": "2015-12-24T16:51:14Z", "created_at": "2015-12-24T16:51:14Z",
"id": "0ff3ae198f8601a285adcf5c0fff204ee6fba5fd", "id": "0ff3ae198f8601a285adcf5c0fff204ee6fba5fd",
"message": "Test the CI integration.", "message": "Test the CI integration.",
"short_id": "0ff3ae19", "short_id": "0ff3ae19",
"title": "Test the CI integration." "title": "Test the CI integration."
}, },
"created_at": "2015-12-24T15:51:21.880Z", "created_at": "2015-12-24T15:51:21.802Z",
"finished_at": "2015-12-24T17:54:31.198Z", "artifacts_file": {
"id": 8, "filename": "artifacts.zip",
"name": "rubocop", "size": 1000
"pipeline": { },
"id": 6, "artifacts": [
{"file_type": "archive", "size": 1000, "filename": "artifacts.zip", "file_format": "zip"},
{"file_type": "metadata", "size": 186, "filename": "metadata.gz", "file_format": "gzip"},
{"file_type": "trace", "size": 1500, "filename": "job.log", "file_format": "raw"},
{"file_type": "junit", "size": 750, "filename": "junit.xml.gz", "file_format": "gzip"}
],
"finished_at": "2015-12-24T17:54:27.895Z",
"artifacts_expire_at": "2016-01-23T17:54:27.895Z",
"id": 7,
"name": "teaspoon",
"pipeline": {
"id": 6,
"ref": "master",
"sha": "0ff3ae198f8601a285adcf5c0fff204ee6fba5fd",
"status": "pending"
},
"ref": "master", "ref": "master",
"sha": "0ff3ae198f8601a285adcf5c0fff204ee6fba5fd", "artifacts": [],
"status": "pending" "stage": "test",
}, "started_at": "2015-12-24T17:54:27.722Z",
"ref": "master", "status": "failed",
"stage": "test", "tag": false,
"started_at": "2015-12-24T17:54:30.733Z", "web_url": "https://example.com/foo/bar/-/jobs/7",
"status": "failed", "user": {
"tag": false, "avatar_url": "http://www.gravatar.com/avatar/e64c7d89f26bd1972efa854d13d7dd61?s=80&d=identicon",
"user": { "created_at": "2015-12-21T13:14:24.077Z",
"avatar_url": "http://www.gravatar.com/avatar/e64c7d89f26bd1972efa854d13d7dd61?s=80&d=identicon", "id": 1,
"created_at": "2015-12-21T13:14:24.077Z", "linkedin": "",
"id": 1, "name": "Administrator",
"linkedin": "", "skype": "",
"name": "Administrator", "state": "active",
"skype": "", "twitter": "",
"state": "active", "username": "root",
"twitter": "", "web_url": "http://gitlab.dev/root",
"username": "root", "website_url": ""
"web_url": "http://gitlab.dev/root", }
"website_url": ""
}
} }
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment