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

com.volcengine.fwcenter.model.AssetListRequest Maven / Gradle / Ivy

There is a newer version: 0.1.144
Show newest version
/*
 * fwcenter
 * No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
 *
 * OpenAPI spec version: common-version
 * 
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package com.volcengine.fwcenter.model;

import java.util.Objects;
import java.util.Arrays;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
/**
 * AssetListRequest
 */



public class AssetListRequest {
  @SerializedName("asset")
  private String asset = null;

  @SerializedName("asset_type")
  private List assetType = null;

  @SerializedName("current_page")
  private Integer currentPage = null;

  /**
   * Gets or Sets orderDir
   */
  @JsonAdapter(OrderDirEnum.Adapter.class)
  public enum OrderDirEnum {
    @SerializedName("asc")
    ASC("asc"),
    @SerializedName("desc")
    DESC("desc");

    private String value;

    OrderDirEnum(String value) {
      this.value = value;
    }
    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }
    public static OrderDirEnum fromValue(String input) {
      for (OrderDirEnum b : OrderDirEnum.values()) {
        if (b.value.equals(input)) {
          return b;
        }
      }
      return null;
    }
    public static class Adapter extends TypeAdapter {
      @Override
      public void write(final JsonWriter jsonWriter, final OrderDirEnum enumeration) throws IOException {
        jsonWriter.value(String.valueOf(enumeration.getValue()));
      }

      @Override
      public OrderDirEnum read(final JsonReader jsonReader) throws IOException {
        Object value = jsonReader.nextString();
        return OrderDirEnum.fromValue((String)(value));
      }
    }
  }  @SerializedName("order_dir")
  private OrderDirEnum orderDir = null;

  @SerializedName("page_size")
  private Integer pageSize = null;

  @SerializedName("stat")
  private Integer stat = null;

  public AssetListRequest asset(String asset) {
    this.asset = asset;
    return this;
  }

   /**
   * Get asset
   * @return asset
  **/
  @Schema(description = "")
  public String getAsset() {
    return asset;
  }

  public void setAsset(String asset) {
    this.asset = asset;
  }

  public AssetListRequest assetType(List assetType) {
    this.assetType = assetType;
    return this;
  }

  public AssetListRequest addAssetTypeItem(String assetTypeItem) {
    if (this.assetType == null) {
      this.assetType = new ArrayList();
    }
    this.assetType.add(assetTypeItem);
    return this;
  }

   /**
   * Get assetType
   * @return assetType
  **/
  @Schema(description = "")
  public List getAssetType() {
    return assetType;
  }

  public void setAssetType(List assetType) {
    this.assetType = assetType;
  }

  public AssetListRequest currentPage(Integer currentPage) {
    this.currentPage = currentPage;
    return this;
  }

   /**
   * Get currentPage
   * @return currentPage
  **/
  @Schema(description = "")
  public Integer getCurrentPage() {
    return currentPage;
  }

  public void setCurrentPage(Integer currentPage) {
    this.currentPage = currentPage;
  }

  public AssetListRequest orderDir(OrderDirEnum orderDir) {
    this.orderDir = orderDir;
    return this;
  }

   /**
   * Get orderDir
   * @return orderDir
  **/
  @Schema(description = "")
  public OrderDirEnum getOrderDir() {
    return orderDir;
  }

  public void setOrderDir(OrderDirEnum orderDir) {
    this.orderDir = orderDir;
  }

  public AssetListRequest pageSize(Integer pageSize) {
    this.pageSize = pageSize;
    return this;
  }

   /**
   * Get pageSize
   * maximum: 1000000
   * @return pageSize
  **/
 @Max(1000000)  @Schema(description = "")
  public Integer getPageSize() {
    return pageSize;
  }

  public void setPageSize(Integer pageSize) {
    this.pageSize = pageSize;
  }

  public AssetListRequest stat(Integer stat) {
    this.stat = stat;
    return this;
  }

   /**
   * Get stat
   * @return stat
  **/
  @Schema(description = "")
  public Integer getStat() {
    return stat;
  }

  public void setStat(Integer stat) {
    this.stat = stat;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    AssetListRequest assetListRequest = (AssetListRequest) o;
    return Objects.equals(this.asset, assetListRequest.asset) &&
        Objects.equals(this.assetType, assetListRequest.assetType) &&
        Objects.equals(this.currentPage, assetListRequest.currentPage) &&
        Objects.equals(this.orderDir, assetListRequest.orderDir) &&
        Objects.equals(this.pageSize, assetListRequest.pageSize) &&
        Objects.equals(this.stat, assetListRequest.stat);
  }

  @Override
  public int hashCode() {
    return Objects.hash(asset, assetType, currentPage, orderDir, pageSize, stat);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class AssetListRequest {\n");
    
    sb.append("    asset: ").append(toIndentedString(asset)).append("\n");
    sb.append("    assetType: ").append(toIndentedString(assetType)).append("\n");
    sb.append("    currentPage: ").append(toIndentedString(currentPage)).append("\n");
    sb.append("    orderDir: ").append(toIndentedString(orderDir)).append("\n");
    sb.append("    pageSize: ").append(toIndentedString(pageSize)).append("\n");
    sb.append("    stat: ").append(toIndentedString(stat)).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(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy