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

org.openapitools.client.model.AchDebitUpdate Maven / Gradle / Ivy

There is a newer version: 3.2.1
Show newest version
/*
* Quickstart API Reference
* Zuora Quickstart API is the API that helps you achieve fundamental use cases.
* It provides a much simplified object model and improved performance, enabling developers to easily learn and use.
*/

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 org.openapitools.client.model.Mandate;

import org.openapitools.client.JSON.CustomFieldAdapter;
import org.openapitools.client.JSON.NullableFieldAdapter;
/**
 * AchDebitUpdate
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AchDebitUpdate {
  public static final String SERIALIZED_NAME_MANDATE = "mandate";
  @SerializedName(SERIALIZED_NAME_MANDATE)
  private Mandate mandate;

  public static final String SERIALIZED_NAME_BANK_ABA_CODE = "bank_aba_code";
  @SerializedName(SERIALIZED_NAME_BANK_ABA_CODE)
  private String bankAbaCode;

  public static final String SERIALIZED_NAME_BANK_ACCOUNT_NAME = "bank_account_name";
  @SerializedName(SERIALIZED_NAME_BANK_ACCOUNT_NAME)
  private String bankAccountName;

  /**
   * The type of bank account associated with the payment method.
   */
  @JsonAdapter(BankAccountTypeEnum.Adapter.class)
  public enum BankAccountTypeEnum {
    BUSINESS_SAVING("business_saving"),
    
    BUSINESS_CHECKING("business_checking"),
    
    CHECKING("checking"),
    
    SAVING("saving"),
    
    UNKNOWN_DEFAULT_OPEN_API("unknown_default_open_api");

    private String value;

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

    public String getValue() {
      return value;
    }

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

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

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

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

  public static final String SERIALIZED_NAME_BANK_ACCOUNT_TYPE = "bank_account_type";
  @SerializedName(SERIALIZED_NAME_BANK_ACCOUNT_TYPE)
  private BankAccountTypeEnum bankAccountType;

  public static final String SERIALIZED_NAME_BANK_NAME = "bank_name";
  @SerializedName(SERIALIZED_NAME_BANK_NAME)
  private String bankName;

  public AchDebitUpdate() { 
  }

  public AchDebitUpdate mandate(Mandate mandate) {
    
    this.mandate = mandate;
    return this;
  }

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

  public Mandate getMandate() {
    return mandate;
  }


  public void setMandate(Mandate mandate) {
    this.mandate = mandate;
  }


  public AchDebitUpdate bankAbaCode(String bankAbaCode) {
    
    this.bankAbaCode = bankAbaCode;
    return this;
  }

   /**
   * The nine-digit routing number or ABA number used by banks.
   * @return bankAbaCode
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "The nine-digit routing number or ABA number used by banks.")

  public String getBankAbaCode() {
    return bankAbaCode;
  }


  public void setBankAbaCode(String bankAbaCode) {
    this.bankAbaCode = bankAbaCode;
  }


  public AchDebitUpdate bankAccountName(String bankAccountName) {
    
    this.bankAccountName = bankAccountName;
    return this;
  }

   /**
   * The name of the account holder, which can be either a person or a company.
   * @return bankAccountName
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "The name of the account holder, which can be either a person or a company.")

  public String getBankAccountName() {
    return bankAccountName;
  }


  public void setBankAccountName(String bankAccountName) {
    this.bankAccountName = bankAccountName;
  }


  public AchDebitUpdate bankAccountType(BankAccountTypeEnum bankAccountType) {
    
    this.bankAccountType = bankAccountType;
    return this;
  }

   /**
   * The type of bank account associated with the payment method.
   * @return bankAccountType
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "The type of bank account associated with the payment method.")

  public BankAccountTypeEnum getBankAccountType() {
    return bankAccountType;
  }


  public void setBankAccountType(BankAccountTypeEnum bankAccountType) {
    this.bankAccountType = bankAccountType;
  }


  public AchDebitUpdate bankName(String bankName) {
    
    this.bankName = bankName;
    return this;
  }

   /**
   * Name of the bank associated with this bank account.
   * @return bankName
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "Name of the bank associated with this bank account.")

  public String getBankName() {
    return bankName;
  }


  public void setBankName(String bankName) {
    this.bankName = bankName;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    AchDebitUpdate achDebitUpdate = (AchDebitUpdate) o;
    return Objects.equals(this.mandate, achDebitUpdate.mandate) &&
        Objects.equals(this.bankAbaCode, achDebitUpdate.bankAbaCode) &&
        Objects.equals(this.bankAccountName, achDebitUpdate.bankAccountName) &&
        Objects.equals(this.bankAccountType, achDebitUpdate.bankAccountType) &&
        Objects.equals(this.bankName, achDebitUpdate.bankName);
  }

  @Override
  public int hashCode() {
    return Objects.hash(mandate, bankAbaCode, bankAccountName, bankAccountType, bankName);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class AchDebitUpdate {\n");
    sb.append("    mandate: ").append(toIndentedString(mandate)).append("\n");
    sb.append("    bankAbaCode: ").append(toIndentedString(bankAbaCode)).append("\n");
    sb.append("    bankAccountName: ").append(toIndentedString(bankAccountName)).append("\n");
    sb.append("    bankAccountType: ").append(toIndentedString(bankAccountType)).append("\n");
    sb.append("    bankName: ").append(toIndentedString(bankName)).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    ");
  }

}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy