com.dominodatalab.api.model.DominoJobsInterfaceJobsTimelineRecord Maven / Gradle / Ivy
/*
* Domino Data Lab API v4
* This API is going to provide access to all the Domino functions available in the user interface. To authenticate your requests, include your API Key (which you can find on your account page) with the header X-Domino-Api-Key.
*
* The version of the OpenAPI document: 4.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package com.dominodatalab.api.model;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
import java.util.StringJoiner;
import java.util.Objects;
import java.util.Map;
import java.util.HashMap;
import com.dominodatalab.api.model.DominoJobsInterfaceJobsTimelineDiagnosticStatRecord;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
/**
* DominoJobsInterfaceJobsTimelineRecord
*/
@JsonPropertyOrder({
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_JOB_NUMBER,
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_JOB_ID,
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_JOB_START_TIME,
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_JOB_TITLE,
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_JOB_STATUS,
DominoJobsInterfaceJobsTimelineRecord.JSON_PROPERTY_DIAGNOSTIC_STATS
})
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-17T15:20:46.682098100-04:00[America/New_York]")
public class DominoJobsInterfaceJobsTimelineRecord {
public static final String JSON_PROPERTY_JOB_NUMBER = "jobNumber";
private Integer jobNumber;
public static final String JSON_PROPERTY_JOB_ID = "jobId";
private String jobId;
public static final String JSON_PROPERTY_JOB_START_TIME = "jobStartTime";
private Long jobStartTime;
public static final String JSON_PROPERTY_JOB_TITLE = "jobTitle";
private String jobTitle;
public static final String JSON_PROPERTY_JOB_STATUS = "jobStatus";
private String jobStatus;
public static final String JSON_PROPERTY_DIAGNOSTIC_STATS = "diagnosticStats";
private List diagnosticStats = new ArrayList<>();
public DominoJobsInterfaceJobsTimelineRecord() {
}
public DominoJobsInterfaceJobsTimelineRecord jobNumber(Integer jobNumber) {
this.jobNumber = jobNumber;
return this;
}
/**
* Get jobNumber
* @return jobNumber
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_JOB_NUMBER)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public Integer getJobNumber() {
return jobNumber;
}
@JsonProperty(JSON_PROPERTY_JOB_NUMBER)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setJobNumber(Integer jobNumber) {
this.jobNumber = jobNumber;
}
public DominoJobsInterfaceJobsTimelineRecord jobId(String jobId) {
this.jobId = jobId;
return this;
}
/**
* Get jobId
* @return jobId
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_JOB_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getJobId() {
return jobId;
}
@JsonProperty(JSON_PROPERTY_JOB_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setJobId(String jobId) {
this.jobId = jobId;
}
public DominoJobsInterfaceJobsTimelineRecord jobStartTime(Long jobStartTime) {
this.jobStartTime = jobStartTime;
return this;
}
/**
* Get jobStartTime
* @return jobStartTime
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_JOB_START_TIME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public Long getJobStartTime() {
return jobStartTime;
}
@JsonProperty(JSON_PROPERTY_JOB_START_TIME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setJobStartTime(Long jobStartTime) {
this.jobStartTime = jobStartTime;
}
public DominoJobsInterfaceJobsTimelineRecord jobTitle(String jobTitle) {
this.jobTitle = jobTitle;
return this;
}
/**
* Get jobTitle
* @return jobTitle
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_JOB_TITLE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getJobTitle() {
return jobTitle;
}
@JsonProperty(JSON_PROPERTY_JOB_TITLE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setJobTitle(String jobTitle) {
this.jobTitle = jobTitle;
}
public DominoJobsInterfaceJobsTimelineRecord jobStatus(String jobStatus) {
this.jobStatus = jobStatus;
return this;
}
/**
* Get jobStatus
* @return jobStatus
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_JOB_STATUS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getJobStatus() {
return jobStatus;
}
@JsonProperty(JSON_PROPERTY_JOB_STATUS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setJobStatus(String jobStatus) {
this.jobStatus = jobStatus;
}
public DominoJobsInterfaceJobsTimelineRecord diagnosticStats(List diagnosticStats) {
this.diagnosticStats = diagnosticStats;
return this;
}
public DominoJobsInterfaceJobsTimelineRecord addDiagnosticStatsItem(DominoJobsInterfaceJobsTimelineDiagnosticStatRecord diagnosticStatsItem) {
if (this.diagnosticStats == null) {
this.diagnosticStats = new ArrayList<>();
}
this.diagnosticStats.add(diagnosticStatsItem);
return this;
}
/**
* Get diagnosticStats
* @return diagnosticStats
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_DIAGNOSTIC_STATS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public List getDiagnosticStats() {
return diagnosticStats;
}
@JsonProperty(JSON_PROPERTY_DIAGNOSTIC_STATS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setDiagnosticStats(List diagnosticStats) {
this.diagnosticStats = diagnosticStats;
}
/**
* Return true if this domino.jobs.interface.JobsTimelineRecord object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
DominoJobsInterfaceJobsTimelineRecord dominoJobsInterfaceJobsTimelineRecord = (DominoJobsInterfaceJobsTimelineRecord) o;
return Objects.equals(this.jobNumber, dominoJobsInterfaceJobsTimelineRecord.jobNumber) &&
Objects.equals(this.jobId, dominoJobsInterfaceJobsTimelineRecord.jobId) &&
Objects.equals(this.jobStartTime, dominoJobsInterfaceJobsTimelineRecord.jobStartTime) &&
Objects.equals(this.jobTitle, dominoJobsInterfaceJobsTimelineRecord.jobTitle) &&
Objects.equals(this.jobStatus, dominoJobsInterfaceJobsTimelineRecord.jobStatus) &&
Objects.equals(this.diagnosticStats, dominoJobsInterfaceJobsTimelineRecord.diagnosticStats);
}
@Override
public int hashCode() {
return Objects.hash(jobNumber, jobId, jobStartTime, jobTitle, jobStatus, diagnosticStats);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class DominoJobsInterfaceJobsTimelineRecord {\n");
sb.append(" jobNumber: ").append(toIndentedString(jobNumber)).append("\n");
sb.append(" jobId: ").append(toIndentedString(jobId)).append("\n");
sb.append(" jobStartTime: ").append(toIndentedString(jobStartTime)).append("\n");
sb.append(" jobTitle: ").append(toIndentedString(jobTitle)).append("\n");
sb.append(" jobStatus: ").append(toIndentedString(jobStatus)).append("\n");
sb.append(" diagnosticStats: ").append(toIndentedString(diagnosticStats)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
/**
* Convert the instance into URL query string.
*
* @return URL query string
*/
public String toUrlQueryString() {
return toUrlQueryString(null);
}
/**
* Convert the instance into URL query string.
*
* @param prefix prefix of the query string
* @return URL query string
*/
public String toUrlQueryString(String prefix) {
String suffix = "";
String containerSuffix = "";
String containerPrefix = "";
if (prefix == null) {
// style=form, explode=true, e.g. /pet?name=cat&type=manx
prefix = "";
} else {
// deepObject style e.g. /pet?id[name]=cat&id[type]=manx
prefix = prefix + "[";
suffix = "]";
containerSuffix = "]";
containerPrefix = "[";
}
StringJoiner joiner = new StringJoiner("&");
// add `jobNumber` to the URL query string
if (getJobNumber() != null) {
joiner.add(String.format("%sjobNumber%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getJobNumber()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `jobId` to the URL query string
if (getJobId() != null) {
joiner.add(String.format("%sjobId%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getJobId()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `jobStartTime` to the URL query string
if (getJobStartTime() != null) {
joiner.add(String.format("%sjobStartTime%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getJobStartTime()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `jobTitle` to the URL query string
if (getJobTitle() != null) {
joiner.add(String.format("%sjobTitle%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getJobTitle()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `jobStatus` to the URL query string
if (getJobStatus() != null) {
joiner.add(String.format("%sjobStatus%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getJobStatus()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `diagnosticStats` to the URL query string
if (getDiagnosticStats() != null) {
for (int i = 0; i < getDiagnosticStats().size(); i++) {
if (getDiagnosticStats().get(i) != null) {
joiner.add(getDiagnosticStats().get(i).toUrlQueryString(String.format("%sdiagnosticStats%s%s", prefix, suffix,
"".equals(suffix) ? "" : String.format("%s%d%s", containerPrefix, i, containerSuffix))));
}
}
}
return joiner.toString();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy