All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dominodatalab.api.model.DominoDatasetrwApiDatasetRwFileDetailsDto 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.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.Arrays;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;


/**
 * DominoDatasetrwApiDatasetRwFileDetailsDto
 */
@JsonPropertyOrder({
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_IS_DIRECTORY,
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_LABEL,
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_SORTABLE_NAME,
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_FILE_NAME,
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_URL,
  DominoDatasetrwApiDatasetRwFileDetailsDto.JSON_PROPERTY_SIZE_IN_BYTES
})
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-10-17T15:20:46.682098100-04:00[America/New_York]")
public class DominoDatasetrwApiDatasetRwFileDetailsDto {
  public static final String JSON_PROPERTY_IS_DIRECTORY = "isDirectory";
  private Boolean isDirectory;

  public static final String JSON_PROPERTY_LABEL = "label";
  private String label;

  public static final String JSON_PROPERTY_SORTABLE_NAME = "sortableName";
  private String sortableName;

  public static final String JSON_PROPERTY_FILE_NAME = "fileName";
  private String fileName;

  public static final String JSON_PROPERTY_URL = "url";
  private String url;

  public static final String JSON_PROPERTY_SIZE_IN_BYTES = "sizeInBytes";
  private Long sizeInBytes;

  public DominoDatasetrwApiDatasetRwFileDetailsDto() { 
  }

  public DominoDatasetrwApiDatasetRwFileDetailsDto isDirectory(Boolean isDirectory) {
    this.isDirectory = isDirectory;
    return this;
  }

   /**
   * Get isDirectory
   * @return isDirectory
  **/
  @javax.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_IS_DIRECTORY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Boolean getIsDirectory() {
    return isDirectory;
  }


  @JsonProperty(JSON_PROPERTY_IS_DIRECTORY)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIsDirectory(Boolean isDirectory) {
    this.isDirectory = isDirectory;
  }


  public DominoDatasetrwApiDatasetRwFileDetailsDto label(String label) {
    this.label = label;
    return this;
  }

   /**
   * Get label
   * @return label
  **/
  @javax.annotation.Nonnull
  @JsonProperty(JSON_PROPERTY_LABEL)
  @JsonInclude(value = JsonInclude.Include.ALWAYS)

  public String getLabel() {
    return label;
  }


  @JsonProperty(JSON_PROPERTY_LABEL)
  @JsonInclude(value = JsonInclude.Include.ALWAYS)
  public void setLabel(String label) {
    this.label = label;
  }


  public DominoDatasetrwApiDatasetRwFileDetailsDto sortableName(String sortableName) {
    this.sortableName = sortableName;
    return this;
  }

   /**
   * Get sortableName
   * @return sortableName
  **/
  @javax.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_SORTABLE_NAME)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getSortableName() {
    return sortableName;
  }


  @JsonProperty(JSON_PROPERTY_SORTABLE_NAME)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setSortableName(String sortableName) {
    this.sortableName = sortableName;
  }


  public DominoDatasetrwApiDatasetRwFileDetailsDto fileName(String fileName) {
    this.fileName = fileName;
    return this;
  }

   /**
   * Get fileName
   * @return fileName
  **/
  @javax.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_FILE_NAME)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getFileName() {
    return fileName;
  }


  @JsonProperty(JSON_PROPERTY_FILE_NAME)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setFileName(String fileName) {
    this.fileName = fileName;
  }


  public DominoDatasetrwApiDatasetRwFileDetailsDto url(String url) {
    this.url = url;
    return this;
  }

   /**
   * Get url
   * @return url
  **/
  @javax.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_URL)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getUrl() {
    return url;
  }


  @JsonProperty(JSON_PROPERTY_URL)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setUrl(String url) {
    this.url = url;
  }


  public DominoDatasetrwApiDatasetRwFileDetailsDto sizeInBytes(Long sizeInBytes) {
    this.sizeInBytes = sizeInBytes;
    return this;
  }

   /**
   * Get sizeInBytes
   * @return sizeInBytes
  **/
  @javax.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_SIZE_IN_BYTES)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Long getSizeInBytes() {
    return sizeInBytes;
  }


  @JsonProperty(JSON_PROPERTY_SIZE_IN_BYTES)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setSizeInBytes(Long sizeInBytes) {
    this.sizeInBytes = sizeInBytes;
  }


  /**
   * Return true if this domino.datasetrw.api.DatasetRwFileDetailsDto object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    DominoDatasetrwApiDatasetRwFileDetailsDto dominoDatasetrwApiDatasetRwFileDetailsDto = (DominoDatasetrwApiDatasetRwFileDetailsDto) o;
    return Objects.equals(this.isDirectory, dominoDatasetrwApiDatasetRwFileDetailsDto.isDirectory) &&
        Objects.equals(this.label, dominoDatasetrwApiDatasetRwFileDetailsDto.label) &&
        Objects.equals(this.sortableName, dominoDatasetrwApiDatasetRwFileDetailsDto.sortableName) &&
        Objects.equals(this.fileName, dominoDatasetrwApiDatasetRwFileDetailsDto.fileName) &&
        Objects.equals(this.url, dominoDatasetrwApiDatasetRwFileDetailsDto.url) &&
        Objects.equals(this.sizeInBytes, dominoDatasetrwApiDatasetRwFileDetailsDto.sizeInBytes);
  }

  @Override
  public int hashCode() {
    return Objects.hash(isDirectory, label, sortableName, fileName, url, sizeInBytes);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class DominoDatasetrwApiDatasetRwFileDetailsDto {\n");
    sb.append("    isDirectory: ").append(toIndentedString(isDirectory)).append("\n");
    sb.append("    label: ").append(toIndentedString(label)).append("\n");
    sb.append("    sortableName: ").append(toIndentedString(sortableName)).append("\n");
    sb.append("    fileName: ").append(toIndentedString(fileName)).append("\n");
    sb.append("    url: ").append(toIndentedString(url)).append("\n");
    sb.append("    sizeInBytes: ").append(toIndentedString(sizeInBytes)).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 `isDirectory` to the URL query string
    if (getIsDirectory() != null) {
      joiner.add(String.format("%sisDirectory%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getIsDirectory()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    // add `label` to the URL query string
    if (getLabel() != null) {
      joiner.add(String.format("%slabel%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getLabel()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    // add `sortableName` to the URL query string
    if (getSortableName() != null) {
      joiner.add(String.format("%ssortableName%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getSortableName()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    // add `fileName` to the URL query string
    if (getFileName() != null) {
      joiner.add(String.format("%sfileName%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getFileName()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    // add `url` to the URL query string
    if (getUrl() != null) {
      joiner.add(String.format("%surl%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getUrl()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    // add `sizeInBytes` to the URL query string
    if (getSizeInBytes() != null) {
      joiner.add(String.format("%ssizeInBytes%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getSizeInBytes()), StandardCharsets.UTF_8).replaceAll("\\+", "%20")));
    }

    return joiner.toString();
  }
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy