/*
 * Swagger of Opencellsoft Api
 * @#Introduction
 *
 * The version of the OpenAPI document: 7.3.1-SNAPSHOT
 * Contact: contact@opencellsoft.fr
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package org.openapitools.client.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.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
import java.math.BigDecimal;

/**
 * WalletTemplateDto
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2019-09-13T10:03:17.753Z[GMT]")
public class WalletTemplateDto {
  public static final String SERIALIZED_NAME_ID = "id";
  @SerializedName(SERIALIZED_NAME_ID)
  private Long id;

  public static final String SERIALIZED_NAME_CODE = "code";
  @SerializedName(SERIALIZED_NAME_CODE)
  private String code;

  public static final String SERIALIZED_NAME_DESCRIPTION = "description";
  @SerializedName(SERIALIZED_NAME_DESCRIPTION)
  private String description;

  public static final String SERIALIZED_NAME_UPDATED_CODE = "updatedCode";
  @SerializedName(SERIALIZED_NAME_UPDATED_CODE)
  private String updatedCode;

  /**
   * Gets or Sets walletType
   */
  @JsonAdapter(WalletTypeEnum.Adapter.class)
  public enum WalletTypeEnum {
    POSTPAID("POSTPAID"),
    
    PREPAID("PREPAID");

    private String value;

    WalletTypeEnum(String value) {
      this.value = value;
    }

    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }

    public static WalletTypeEnum fromValue(String value) {
      for (WalletTypeEnum b : WalletTypeEnum.values()) {
        if (b.value.equals(value)) {
          return b;
        }
      }
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
    }

    public static class Adapter extends TypeAdapter<WalletTypeEnum> {
      @Override
      public void write(final JsonWriter jsonWriter, final WalletTypeEnum enumeration) throws IOException {
        jsonWriter.value(enumeration.getValue());
      }

      @Override
      public WalletTypeEnum read(final JsonReader jsonReader) throws IOException {
        String value = jsonReader.nextString();
        return WalletTypeEnum.fromValue(value);
      }
    }
  }

  public static final String SERIALIZED_NAME_WALLET_TYPE = "walletType";
  @SerializedName(SERIALIZED_NAME_WALLET_TYPE)
  private WalletTypeEnum walletType;

  public static final String SERIALIZED_NAME_CONSUMPTION_ALERT_SET = "consumptionAlertSet";
  @SerializedName(SERIALIZED_NAME_CONSUMPTION_ALERT_SET)
  private Boolean consumptionAlertSet;

  public static final String SERIALIZED_NAME_FAST_RATING_LEVEL = "fastRatingLevel";
  @SerializedName(SERIALIZED_NAME_FAST_RATING_LEVEL)
  private Integer fastRatingLevel;

  public static final String SERIALIZED_NAME_LOW_BALANCE_LEVEL = "lowBalanceLevel";
  @SerializedName(SERIALIZED_NAME_LOW_BALANCE_LEVEL)
  private BigDecimal lowBalanceLevel;

  public static final String SERIALIZED_NAME_REJECT_LEVEL = "rejectLevel";
  @SerializedName(SERIALIZED_NAME_REJECT_LEVEL)
  private BigDecimal rejectLevel;


  public WalletTemplateDto id(Long id) {
    
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public Long getId() {
    return id;
  }



  public void setId(Long id) {
    this.id = id;
  }


  public WalletTemplateDto code(String code) {
    
    this.code = code;
    return this;
  }

   /**
   * Get code
   * @return code
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCode() {
    return code;
  }



  public void setCode(String code) {
    this.code = code;
  }


  public WalletTemplateDto description(String description) {
    
    this.description = description;
    return this;
  }

   /**
   * Get description
   * @return description
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getDescription() {
    return description;
  }



  public void setDescription(String description) {
    this.description = description;
  }


  public WalletTemplateDto updatedCode(String updatedCode) {
    
    this.updatedCode = updatedCode;
    return this;
  }

   /**
   * Get updatedCode
   * @return updatedCode
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getUpdatedCode() {
    return updatedCode;
  }



  public void setUpdatedCode(String updatedCode) {
    this.updatedCode = updatedCode;
  }


  public WalletTemplateDto walletType(WalletTypeEnum walletType) {
    
    this.walletType = walletType;
    return this;
  }

   /**
   * Get walletType
   * @return walletType
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public WalletTypeEnum getWalletType() {
    return walletType;
  }



  public void setWalletType(WalletTypeEnum walletType) {
    this.walletType = walletType;
  }


  public WalletTemplateDto consumptionAlertSet(Boolean consumptionAlertSet) {
    
    this.consumptionAlertSet = consumptionAlertSet;
    return this;
  }

   /**
   * Get consumptionAlertSet
   * @return consumptionAlertSet
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public Boolean getConsumptionAlertSet() {
    return consumptionAlertSet;
  }



  public void setConsumptionAlertSet(Boolean consumptionAlertSet) {
    this.consumptionAlertSet = consumptionAlertSet;
  }


  public WalletTemplateDto fastRatingLevel(Integer fastRatingLevel) {
    
    this.fastRatingLevel = fastRatingLevel;
    return this;
  }

   /**
   * Get fastRatingLevel
   * @return fastRatingLevel
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public Integer getFastRatingLevel() {
    return fastRatingLevel;
  }



  public void setFastRatingLevel(Integer fastRatingLevel) {
    this.fastRatingLevel = fastRatingLevel;
  }


  public WalletTemplateDto lowBalanceLevel(BigDecimal lowBalanceLevel) {
    
    this.lowBalanceLevel = lowBalanceLevel;
    return this;
  }

   /**
   * Get lowBalanceLevel
   * @return lowBalanceLevel
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public BigDecimal getLowBalanceLevel() {
    return lowBalanceLevel;
  }



  public void setLowBalanceLevel(BigDecimal lowBalanceLevel) {
    this.lowBalanceLevel = lowBalanceLevel;
  }


  public WalletTemplateDto rejectLevel(BigDecimal rejectLevel) {
    
    this.rejectLevel = rejectLevel;
    return this;
  }

   /**
   * Get rejectLevel
   * @return rejectLevel
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public BigDecimal getRejectLevel() {
    return rejectLevel;
  }



  public void setRejectLevel(BigDecimal rejectLevel) {
    this.rejectLevel = rejectLevel;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    WalletTemplateDto walletTemplateDto = (WalletTemplateDto) o;
    return Objects.equals(this.id, walletTemplateDto.id) &&
        Objects.equals(this.code, walletTemplateDto.code) &&
        Objects.equals(this.description, walletTemplateDto.description) &&
        Objects.equals(this.updatedCode, walletTemplateDto.updatedCode) &&
        Objects.equals(this.walletType, walletTemplateDto.walletType) &&
        Objects.equals(this.consumptionAlertSet, walletTemplateDto.consumptionAlertSet) &&
        Objects.equals(this.fastRatingLevel, walletTemplateDto.fastRatingLevel) &&
        Objects.equals(this.lowBalanceLevel, walletTemplateDto.lowBalanceLevel) &&
        Objects.equals(this.rejectLevel, walletTemplateDto.rejectLevel);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, code, description, updatedCode, walletType, consumptionAlertSet, fastRatingLevel, lowBalanceLevel, rejectLevel);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class WalletTemplateDto {\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    code: ").append(toIndentedString(code)).append("\n");
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
    sb.append("    updatedCode: ").append(toIndentedString(updatedCode)).append("\n");
    sb.append("    walletType: ").append(toIndentedString(walletType)).append("\n");
    sb.append("    consumptionAlertSet: ").append(toIndentedString(consumptionAlertSet)).append("\n");
    sb.append("    fastRatingLevel: ").append(toIndentedString(fastRatingLevel)).append("\n");
    sb.append("    lowBalanceLevel: ").append(toIndentedString(lowBalanceLevel)).append("\n");
    sb.append("    rejectLevel: ").append(toIndentedString(rejectLevel)).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    ");
  }

}

