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

com.adyen.model.balanceplatform.BankAccountDetails Maven / Gradle / Ivy

/*
 * Configuration API
 *
 * The version of the OpenAPI document: 2
 * 
 *
 * 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.adyen.model.balanceplatform;

import java.util.Objects;
import java.util.Arrays;
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 io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.core.JsonProcessingException;


/**
 * BankAccountDetails
 */
@JsonPropertyOrder({
  BankAccountDetails.JSON_PROPERTY_ACCOUNT_NUMBER,
  BankAccountDetails.JSON_PROPERTY_ACCOUNT_TYPE,
  BankAccountDetails.JSON_PROPERTY_FORM_FACTOR,
  BankAccountDetails.JSON_PROPERTY_IBAN,
  BankAccountDetails.JSON_PROPERTY_ROUTING_NUMBER,
  BankAccountDetails.JSON_PROPERTY_SORT_CODE,
  BankAccountDetails.JSON_PROPERTY_TYPE
})

public class BankAccountDetails {
  public static final String JSON_PROPERTY_ACCOUNT_NUMBER = "accountNumber";
  private String accountNumber;

  public static final String JSON_PROPERTY_ACCOUNT_TYPE = "accountType";
  private String accountType;

  public static final String JSON_PROPERTY_FORM_FACTOR = "formFactor";
  private String formFactor;

  public static final String JSON_PROPERTY_IBAN = "iban";
  private String iban;

  public static final String JSON_PROPERTY_ROUTING_NUMBER = "routingNumber";
  private String routingNumber;

  public static final String JSON_PROPERTY_SORT_CODE = "sortCode";
  private String sortCode;

  public static final String JSON_PROPERTY_TYPE = "type";
  private String type;

  public BankAccountDetails() { 
  }

  public BankAccountDetails accountNumber(String accountNumber) {
    this.accountNumber = accountNumber;
    return this;
  }

   /**
   * The bank account number, without separators or whitespace.
   * @return accountNumber
  **/
  @ApiModelProperty(value = "The bank account number, without separators or whitespace.")
  @JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getAccountNumber() {
    return accountNumber;
  }


 /**
  * The bank account number, without separators or whitespace.
  *
  * @param accountNumber
  */ 
  @JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setAccountNumber(String accountNumber) {
    this.accountNumber = accountNumber;
  }


  public BankAccountDetails accountType(String accountType) {
    this.accountType = accountType;
    return this;
  }

   /**
   * The bank account type.  Possible values: **checking** or **savings**. Defaults to **checking**.
   * @return accountType
  **/
  @ApiModelProperty(value = "The bank account type.  Possible values: **checking** or **savings**. Defaults to **checking**.")
  @JsonProperty(JSON_PROPERTY_ACCOUNT_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getAccountType() {
    return accountType;
  }


 /**
  * The bank account type.  Possible values: **checking** or **savings**. Defaults to **checking**.
  *
  * @param accountType
  */ 
  @JsonProperty(JSON_PROPERTY_ACCOUNT_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setAccountType(String accountType) {
    this.accountType = accountType;
  }


  public BankAccountDetails formFactor(String formFactor) {
    this.formFactor = formFactor;
    return this;
  }

   /**
   * Business accounts with a `formFactor` value of **physical** are business accounts issued under the central bank of that country. The default value is **physical** for NL, US, and UK business accounts.   Adyen creates a local IBAN for business accounts when the `formFactor` value is set to **virtual**. The local IBANs that are supported are for DE and FR, which reference a physical NL account, with funds being routed through the central bank of NL.
   * @return formFactor
  **/
  @ApiModelProperty(value = "Business accounts with a `formFactor` value of **physical** are business accounts issued under the central bank of that country. The default value is **physical** for NL, US, and UK business accounts.   Adyen creates a local IBAN for business accounts when the `formFactor` value is set to **virtual**. The local IBANs that are supported are for DE and FR, which reference a physical NL account, with funds being routed through the central bank of NL.")
  @JsonProperty(JSON_PROPERTY_FORM_FACTOR)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getFormFactor() {
    return formFactor;
  }


 /**
  * Business accounts with a `formFactor` value of **physical** are business accounts issued under the central bank of that country. The default value is **physical** for NL, US, and UK business accounts.   Adyen creates a local IBAN for business accounts when the `formFactor` value is set to **virtual**. The local IBANs that are supported are for DE and FR, which reference a physical NL account, with funds being routed through the central bank of NL.
  *
  * @param formFactor
  */ 
  @JsonProperty(JSON_PROPERTY_FORM_FACTOR)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setFormFactor(String formFactor) {
    this.formFactor = formFactor;
  }


  public BankAccountDetails iban(String iban) {
    this.iban = iban;
    return this;
  }

   /**
   * The international bank account number as defined in the [ISO-13616](https://www.iso.org/standard/81090.html) standard.
   * @return iban
  **/
  @ApiModelProperty(value = "The international bank account number as defined in the [ISO-13616](https://www.iso.org/standard/81090.html) standard.")
  @JsonProperty(JSON_PROPERTY_IBAN)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getIban() {
    return iban;
  }


 /**
  * The international bank account number as defined in the [ISO-13616](https://www.iso.org/standard/81090.html) standard.
  *
  * @param iban
  */ 
  @JsonProperty(JSON_PROPERTY_IBAN)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIban(String iban) {
    this.iban = iban;
  }


  public BankAccountDetails routingNumber(String routingNumber) {
    this.routingNumber = routingNumber;
    return this;
  }

   /**
   * The [routing number](https://en.wikipedia.org/wiki/ABA_routing_transit_number), without separators or whitespace.
   * @return routingNumber
  **/
  @ApiModelProperty(value = "The [routing number](https://en.wikipedia.org/wiki/ABA_routing_transit_number), without separators or whitespace.")
  @JsonProperty(JSON_PROPERTY_ROUTING_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getRoutingNumber() {
    return routingNumber;
  }


 /**
  * The [routing number](https://en.wikipedia.org/wiki/ABA_routing_transit_number), without separators or whitespace.
  *
  * @param routingNumber
  */ 
  @JsonProperty(JSON_PROPERTY_ROUTING_NUMBER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setRoutingNumber(String routingNumber) {
    this.routingNumber = routingNumber;
  }


  public BankAccountDetails sortCode(String sortCode) {
    this.sortCode = sortCode;
    return this;
  }

   /**
   * The [sort code](https://en.wikipedia.org/wiki/Sort_code), without separators or whitespace.
   * @return sortCode
  **/
  @ApiModelProperty(value = "The [sort code](https://en.wikipedia.org/wiki/Sort_code), without separators or whitespace.")
  @JsonProperty(JSON_PROPERTY_SORT_CODE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getSortCode() {
    return sortCode;
  }


 /**
  * The [sort code](https://en.wikipedia.org/wiki/Sort_code), without separators or whitespace.
  *
  * @param sortCode
  */ 
  @JsonProperty(JSON_PROPERTY_SORT_CODE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setSortCode(String sortCode) {
    this.sortCode = sortCode;
  }


  public BankAccountDetails type(String type) {
    this.type = type;
    return this;
  }

   /**
   * **iban** or **usLocal** or **ukLocal**
   * @return type
  **/
  @ApiModelProperty(required = true, value = "**iban** or **usLocal** or **ukLocal**")
  @JsonProperty(JSON_PROPERTY_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getType() {
    return type;
  }


 /**
  * **iban** or **usLocal** or **ukLocal**
  *
  * @param type
  */ 
  @JsonProperty(JSON_PROPERTY_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setType(String type) {
    this.type = type;
  }


  /**
   * Return true if this BankAccountDetails object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    BankAccountDetails bankAccountDetails = (BankAccountDetails) o;
    return Objects.equals(this.accountNumber, bankAccountDetails.accountNumber) &&
        Objects.equals(this.accountType, bankAccountDetails.accountType) &&
        Objects.equals(this.formFactor, bankAccountDetails.formFactor) &&
        Objects.equals(this.iban, bankAccountDetails.iban) &&
        Objects.equals(this.routingNumber, bankAccountDetails.routingNumber) &&
        Objects.equals(this.sortCode, bankAccountDetails.sortCode) &&
        Objects.equals(this.type, bankAccountDetails.type);
  }

  @Override
  public int hashCode() {
    return Objects.hash(accountNumber, accountType, formFactor, iban, routingNumber, sortCode, type);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class BankAccountDetails {\n");
    sb.append("    accountNumber: ").append(toIndentedString(accountNumber)).append("\n");
    sb.append("    accountType: ").append(toIndentedString(accountType)).append("\n");
    sb.append("    formFactor: ").append(toIndentedString(formFactor)).append("\n");
    sb.append("    iban: ").append(toIndentedString(iban)).append("\n");
    sb.append("    routingNumber: ").append(toIndentedString(routingNumber)).append("\n");
    sb.append("    sortCode: ").append(toIndentedString(sortCode)).append("\n");
    sb.append("    type: ").append(toIndentedString(type)).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    ");
  }

/**
   * Create an instance of BankAccountDetails given an JSON string
   *
   * @param jsonString JSON string
   * @return An instance of BankAccountDetails
   * @throws JsonProcessingException if the JSON string is invalid with respect to BankAccountDetails
   */
  public static BankAccountDetails fromJson(String jsonString) throws JsonProcessingException {
    return JSON.getMapper().readValue(jsonString, BankAccountDetails.class);
  }
/**
  * Convert an instance of BankAccountDetails to an JSON string
  *
  * @return JSON string
  */
  public String toJson() throws JsonProcessingException {
    return JSON.getMapper().writeValueAsString(this);
  }
}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy