package org.wfc.omada.api.sitesetting.model;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotNull;
import java.util.Objects;

/**
 * Rate limit custom setting
 */
@ApiModel(description = "Rate limit custom setting")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-12-04T11:32:19.054+08:00[Asia/Shanghai]")

public class CustomRateLimitSettingOpenApiVo   {
  @JsonProperty("downLimitEnable")
  private Boolean downLimitEnable;

  @JsonProperty("downLimit")
  private Integer downLimit;

  @JsonProperty("downLimitType")
  private Integer downLimitType;

  @JsonProperty("upLimitEnable")
  private Boolean upLimitEnable;

  @JsonProperty("upLimit")
  private Integer upLimit;

  @JsonProperty("upLimitType")
  private Integer upLimitType;

  public CustomRateLimitSettingOpenApiVo downLimitEnable(Boolean downLimitEnable) {
    this.downLimitEnable = downLimitEnable;
    return this;
  }

  /**
   * Whether to limit downlink speed; This field is required when select custom setting. True: enable, false: disable.
   * @return downLimitEnable
  */
  @ApiModelProperty(required = true, value = "Whether to limit downlink speed; This field is required when select custom setting. True: enable, false: disable.")
  @NotNull


  public Boolean getDownLimitEnable() {
    return downLimitEnable;
  }

  public void setDownLimitEnable(Boolean downLimitEnable) {
    this.downLimitEnable = downLimitEnable;
  }

  public CustomRateLimitSettingOpenApiVo downLimit(Integer downLimit) {
    this.downLimit = downLimit;
    return this;
  }

  /**
   * Downlink speed limit value. When the value of Parameter [downLimitType] is 0(Kbps), downLimit should be within the range of 1–10485760; when the value of Parameter [downLimitType] is 1(Mbps), downLimit should be within the range of 1-10240.
   * @return downLimit
  */
  @ApiModelProperty(value = "Downlink speed limit value. When the value of Parameter [downLimitType] is 0(Kbps), downLimit should be within the range of 1–10485760; when the value of Parameter [downLimitType] is 1(Mbps), downLimit should be within the range of 1-10240.")


  public Integer getDownLimit() {
    return downLimit;
  }

  public void setDownLimit(Integer downLimit) {
    this.downLimit = downLimit;
  }

  public CustomRateLimitSettingOpenApiVo downLimitType(Integer downLimitType) {
    this.downLimitType = downLimitType;
    return this;
  }

  /**
   * Downlink speed limit unit config; DownLimitType should be a value as follows: 0: Kbps; 1: Mbps.
   * @return downLimitType
  */
  @ApiModelProperty(value = "Downlink speed limit unit config; DownLimitType should be a value as follows: 0: Kbps; 1: Mbps.")


  public Integer getDownLimitType() {
    return downLimitType;
  }

  public void setDownLimitType(Integer downLimitType) {
    this.downLimitType = downLimitType;
  }

  public CustomRateLimitSettingOpenApiVo upLimitEnable(Boolean upLimitEnable) {
    this.upLimitEnable = upLimitEnable;
    return this;
  }

  /**
   * Whether to limit uplink speed; This field is required when select custom setting. True: enable, false: disable.
   * @return upLimitEnable
  */
  @ApiModelProperty(required = true, value = "Whether to limit uplink speed; This field is required when select custom setting. True: enable, false: disable.")
  @NotNull


  public Boolean getUpLimitEnable() {
    return upLimitEnable;
  }

  public void setUpLimitEnable(Boolean upLimitEnable) {
    this.upLimitEnable = upLimitEnable;
  }

  public CustomRateLimitSettingOpenApiVo upLimit(Integer upLimit) {
    this.upLimit = upLimit;
    return this;
  }

  /**
   * Uplink speed limit value. When the value of Parameter [upLimitType] is 0(Kbps), upLimit should be within the range of 1–10485760; when the value of Parameter [upLimitType] is 1(Mbps), upLimit should be within the range of 1-10240.
   * @return upLimit
  */
  @ApiModelProperty(value = "Uplink speed limit value. When the value of Parameter [upLimitType] is 0(Kbps), upLimit should be within the range of 1–10485760; when the value of Parameter [upLimitType] is 1(Mbps), upLimit should be within the range of 1-10240.")


  public Integer getUpLimit() {
    return upLimit;
  }

  public void setUpLimit(Integer upLimit) {
    this.upLimit = upLimit;
  }

  public CustomRateLimitSettingOpenApiVo upLimitType(Integer upLimitType) {
    this.upLimitType = upLimitType;
    return this;
  }

  /**
   * Uplink speed limit unit config; UpLimitType should be a value as follows: 0: Kbps; 1: Mbps.
   * @return upLimitType
  */
  @ApiModelProperty(value = "Uplink speed limit unit config; UpLimitType should be a value as follows: 0: Kbps; 1: Mbps.")


  public Integer getUpLimitType() {
    return upLimitType;
  }

  public void setUpLimitType(Integer upLimitType) {
    this.upLimitType = upLimitType;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CustomRateLimitSettingOpenApiVo customRateLimitSettingOpenApiVo = (CustomRateLimitSettingOpenApiVo) o;
    return Objects.equals(this.downLimitEnable, customRateLimitSettingOpenApiVo.downLimitEnable) &&
        Objects.equals(this.downLimit, customRateLimitSettingOpenApiVo.downLimit) &&
        Objects.equals(this.downLimitType, customRateLimitSettingOpenApiVo.downLimitType) &&
        Objects.equals(this.upLimitEnable, customRateLimitSettingOpenApiVo.upLimitEnable) &&
        Objects.equals(this.upLimit, customRateLimitSettingOpenApiVo.upLimit) &&
        Objects.equals(this.upLimitType, customRateLimitSettingOpenApiVo.upLimitType);
  }

  @Override
  public int hashCode() {
    return Objects.hash(downLimitEnable, downLimit, downLimitType, upLimitEnable, upLimit, upLimitType);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class CustomRateLimitSettingOpenApiVo {\n");
    
    sb.append("    downLimitEnable: ").append(toIndentedString(downLimitEnable)).append("\n");
    sb.append("    downLimit: ").append(toIndentedString(downLimit)).append("\n");
    sb.append("    downLimitType: ").append(toIndentedString(downLimitType)).append("\n");
    sb.append("    upLimitEnable: ").append(toIndentedString(upLimitEnable)).append("\n");
    sb.append("    upLimit: ").append(toIndentedString(upLimit)).append("\n");
    sb.append("    upLimitType: ").append(toIndentedString(upLimitType)).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    ");
  }
}

