com.dominodatalab.api.model.DominoDatasetrwApiDatasetRwDetailsDto 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.DominoDatasetrwApiDatasetRwProjectDetailsDto;
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.HashMap;
import java.util.List;
import java.util.Map;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
/**
* DominoDatasetrwApiDatasetRwDetailsDto
*/
@JsonPropertyOrder({
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_DATASET_PATH,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_PROJECTS,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_LIFECYCLE_STATUS,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_AUTHOR,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_SNAPSHOT_IDS,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_READ_WRITE_SNAPSHOT_ID,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_NAME,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_DESCRIPTION,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_ID,
DominoDatasetrwApiDatasetRwDetailsDto.JSON_PROPERTY_TAGS
})
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-17T15:20:46.682098100-04:00[America/New_York]")
public class DominoDatasetrwApiDatasetRwDetailsDto {
public static final String JSON_PROPERTY_DATASET_PATH = "datasetPath";
private String datasetPath;
public static final String JSON_PROPERTY_PROJECTS = "projects";
private DominoDatasetrwApiDatasetRwProjectDetailsDto projects;
/**
* Gets or Sets lifecycleStatus
*/
public enum LifecycleStatusEnum {
PENDING("Pending"),
DELETED("Deleted"),
DELETIONINPROGRESS("DeletionInProgress"),
FAILED("Failed"),
ACTIVE("Active"),
MARKEDFORDELETION("MarkedForDeletion");
private String value;
LifecycleStatusEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static LifecycleStatusEnum fromValue(String value) {
for (LifecycleStatusEnum b : LifecycleStatusEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
public static final String JSON_PROPERTY_LIFECYCLE_STATUS = "lifecycleStatus";
private LifecycleStatusEnum lifecycleStatus;
public static final String JSON_PROPERTY_AUTHOR = "author";
private String author;
public static final String JSON_PROPERTY_SNAPSHOT_IDS = "snapshotIds";
private List snapshotIds = new ArrayList<>();
public static final String JSON_PROPERTY_READ_WRITE_SNAPSHOT_ID = "readWriteSnapshotId";
private String readWriteSnapshotId;
public static final String JSON_PROPERTY_NAME = "name";
private String name;
public static final String JSON_PROPERTY_DESCRIPTION = "description";
private String description;
public static final String JSON_PROPERTY_ID = "id";
private String id;
public static final String JSON_PROPERTY_TAGS = "tags";
private Map tags = new HashMap<>();
public DominoDatasetrwApiDatasetRwDetailsDto() {
}
public DominoDatasetrwApiDatasetRwDetailsDto datasetPath(String datasetPath) {
this.datasetPath = datasetPath;
return this;
}
/**
* Get datasetPath
* @return datasetPath
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_DATASET_PATH)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getDatasetPath() {
return datasetPath;
}
@JsonProperty(JSON_PROPERTY_DATASET_PATH)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setDatasetPath(String datasetPath) {
this.datasetPath = datasetPath;
}
public DominoDatasetrwApiDatasetRwDetailsDto projects(DominoDatasetrwApiDatasetRwProjectDetailsDto projects) {
this.projects = projects;
return this;
}
/**
* Get projects
* @return projects
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_PROJECTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public DominoDatasetrwApiDatasetRwProjectDetailsDto getProjects() {
return projects;
}
@JsonProperty(JSON_PROPERTY_PROJECTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setProjects(DominoDatasetrwApiDatasetRwProjectDetailsDto projects) {
this.projects = projects;
}
public DominoDatasetrwApiDatasetRwDetailsDto lifecycleStatus(LifecycleStatusEnum lifecycleStatus) {
this.lifecycleStatus = lifecycleStatus;
return this;
}
/**
* Get lifecycleStatus
* @return lifecycleStatus
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_LIFECYCLE_STATUS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public LifecycleStatusEnum getLifecycleStatus() {
return lifecycleStatus;
}
@JsonProperty(JSON_PROPERTY_LIFECYCLE_STATUS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setLifecycleStatus(LifecycleStatusEnum lifecycleStatus) {
this.lifecycleStatus = lifecycleStatus;
}
public DominoDatasetrwApiDatasetRwDetailsDto author(String author) {
this.author = author;
return this;
}
/**
* Get author
* @return author
**/
@javax.annotation.Nullable
@JsonProperty(JSON_PROPERTY_AUTHOR)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getAuthor() {
return author;
}
@JsonProperty(JSON_PROPERTY_AUTHOR)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setAuthor(String author) {
this.author = author;
}
public DominoDatasetrwApiDatasetRwDetailsDto snapshotIds(List snapshotIds) {
this.snapshotIds = snapshotIds;
return this;
}
public DominoDatasetrwApiDatasetRwDetailsDto addSnapshotIdsItem(String snapshotIdsItem) {
if (this.snapshotIds == null) {
this.snapshotIds = new ArrayList<>();
}
this.snapshotIds.add(snapshotIdsItem);
return this;
}
/**
* Get snapshotIds
* @return snapshotIds
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_SNAPSHOT_IDS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public List getSnapshotIds() {
return snapshotIds;
}
@JsonProperty(JSON_PROPERTY_SNAPSHOT_IDS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setSnapshotIds(List snapshotIds) {
this.snapshotIds = snapshotIds;
}
public DominoDatasetrwApiDatasetRwDetailsDto readWriteSnapshotId(String readWriteSnapshotId) {
this.readWriteSnapshotId = readWriteSnapshotId;
return this;
}
/**
* Get readWriteSnapshotId
* @return readWriteSnapshotId
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_READ_WRITE_SNAPSHOT_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getReadWriteSnapshotId() {
return readWriteSnapshotId;
}
@JsonProperty(JSON_PROPERTY_READ_WRITE_SNAPSHOT_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setReadWriteSnapshotId(String readWriteSnapshotId) {
this.readWriteSnapshotId = readWriteSnapshotId;
}
public DominoDatasetrwApiDatasetRwDetailsDto name(String name) {
this.name = name;
return this;
}
/**
* Get name
* @return name
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_NAME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getName() {
return name;
}
@JsonProperty(JSON_PROPERTY_NAME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setName(String name) {
this.name = name;
}
public DominoDatasetrwApiDatasetRwDetailsDto description(String description) {
this.description = description;
return this;
}
/**
* Get description
* @return description
**/
@javax.annotation.Nullable
@JsonProperty(JSON_PROPERTY_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getDescription() {
return description;
}
@JsonProperty(JSON_PROPERTY_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setDescription(String description) {
this.description = description;
}
public DominoDatasetrwApiDatasetRwDetailsDto id(String id) {
this.id = id;
return this;
}
/**
* Get id
* @return id
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getId() {
return id;
}
@JsonProperty(JSON_PROPERTY_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setId(String id) {
this.id = id;
}
public DominoDatasetrwApiDatasetRwDetailsDto tags(Map tags) {
this.tags = tags;
return this;
}
public DominoDatasetrwApiDatasetRwDetailsDto putTagsItem(String key, String tagsItem) {
if (this.tags == null) {
this.tags = new HashMap<>();
}
this.tags.put(key, tagsItem);
return this;
}
/**
* Get tags
* @return tags
**/
@javax.annotation.Nonnull
@JsonProperty(JSON_PROPERTY_TAGS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public Map getTags() {
return tags;
}
@JsonProperty(JSON_PROPERTY_TAGS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setTags(Map tags) {
this.tags = tags;
}
/**
* Return true if this domino.datasetrw.api.DatasetRwDetailsDto object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
DominoDatasetrwApiDatasetRwDetailsDto dominoDatasetrwApiDatasetRwDetailsDto = (DominoDatasetrwApiDatasetRwDetailsDto) o;
return Objects.equals(this.datasetPath, dominoDatasetrwApiDatasetRwDetailsDto.datasetPath) &&
Objects.equals(this.projects, dominoDatasetrwApiDatasetRwDetailsDto.projects) &&
Objects.equals(this.lifecycleStatus, dominoDatasetrwApiDatasetRwDetailsDto.lifecycleStatus) &&
Objects.equals(this.author, dominoDatasetrwApiDatasetRwDetailsDto.author) &&
Objects.equals(this.snapshotIds, dominoDatasetrwApiDatasetRwDetailsDto.snapshotIds) &&
Objects.equals(this.readWriteSnapshotId, dominoDatasetrwApiDatasetRwDetailsDto.readWriteSnapshotId) &&
Objects.equals(this.name, dominoDatasetrwApiDatasetRwDetailsDto.name) &&
Objects.equals(this.description, dominoDatasetrwApiDatasetRwDetailsDto.description) &&
Objects.equals(this.id, dominoDatasetrwApiDatasetRwDetailsDto.id) &&
Objects.equals(this.tags, dominoDatasetrwApiDatasetRwDetailsDto.tags);
}
@Override
public int hashCode() {
return Objects.hash(datasetPath, projects, lifecycleStatus, author, snapshotIds, readWriteSnapshotId, name, description, id, tags);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class DominoDatasetrwApiDatasetRwDetailsDto {\n");
sb.append(" datasetPath: ").append(toIndentedString(datasetPath)).append("\n");
sb.append(" projects: ").append(toIndentedString(projects)).append("\n");
sb.append(" lifecycleStatus: ").append(toIndentedString(lifecycleStatus)).append("\n");
sb.append(" author: ").append(toIndentedString(author)).append("\n");
sb.append(" snapshotIds: ").append(toIndentedString(snapshotIds)).append("\n");
sb.append(" readWriteSnapshotId: ").append(toIndentedString(readWriteSnapshotId)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" tags: ").append(toIndentedString(tags)).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 `datasetPath` to the URL query string
if (getDatasetPath() != null) {
joiner.add(String.format("%sdatasetPath%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getDatasetPath()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `projects` to the URL query string
if (getProjects() != null) {
joiner.add(getProjects().toUrlQueryString(prefix + "projects" + suffix));
}
// add `lifecycleStatus` to the URL query string
if (getLifecycleStatus() != null) {
joiner.add(String.format("%slifecycleStatus%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getLifecycleStatus()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `author` to the URL query string
if (getAuthor() != null) {
joiner.add(String.format("%sauthor%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getAuthor()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `snapshotIds` to the URL query string
if (getSnapshotIds() != null) {
for (int i = 0; i < getSnapshotIds().size(); i++) {
joiner.add(String.format("%ssnapshotIds%s%s=%s", prefix, suffix,
"".equals(suffix) ? "" : String.format("%s%d%s", containerPrefix, i, containerSuffix),
URLEncoder.encode(String.valueOf(getSnapshotIds().get(i)), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
}
// add `readWriteSnapshotId` to the URL query string
if (getReadWriteSnapshotId() != null) {
joiner.add(String.format("%sreadWriteSnapshotId%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getReadWriteSnapshotId()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `name` to the URL query string
if (getName() != null) {
joiner.add(String.format("%sname%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getName()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `description` to the URL query string
if (getDescription() != null) {
joiner.add(String.format("%sdescription%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getDescription()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `id` to the URL query string
if (getId() != null) {
joiner.add(String.format("%sid%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getId()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
// add `tags` to the URL query string
if (getTags() != null) {
for (String _key : getTags().keySet()) {
joiner.add(String.format("%stags%s%s=%s", prefix, suffix,
"".equals(suffix) ? "" : String.format("%s%d%s", containerPrefix, _key, containerSuffix),
getTags().get(_key), URLEncoder.encode(String.valueOf(getTags().get(_key)), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
}
}
return joiner.toString();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy