content: /*
   * Open Banking API
   *
   * The version of the OpenAPI document: 1
   *
   *
   * 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.openbanking;
  
  import com.fasterxml.jackson.annotation.JsonInclude;
  import com.fasterxml.jackson.annotation.JsonProperty;
  import com.fasterxml.jackson.annotation.JsonPropertyOrder;
  import com.fasterxml.jackson.core.JsonProcessingException;
  import java.util.*;
  
  /** RIXAccountIdentifier */
  @JsonPropertyOrder({
    RIXAccountIdentifier.JSON_PROPERTY_ACCOUNT_NUMBER,
    RIXAccountIdentifier.JSON_PROPERTY_CLEARING_NUMBER
  })
  public class RIXAccountIdentifier {
    public static final String JSON_PROPERTY_ACCOUNT_NUMBER = "accountNumber";
    private String accountNumber;
  
    public static final String JSON_PROPERTY_CLEARING_NUMBER = "clearingNumber";
    private String clearingNumber;
  
    public RIXAccountIdentifier() {}
  
    /**
     * The account number of the bank account.
     *
     * @param accountNumber The account number of the bank account.
     * @return the current {@code RIXAccountIdentifier} instance, allowing for method chaining
     */
    public RIXAccountIdentifier accountNumber(String accountNumber) {
      this.accountNumber = accountNumber;
      return this;
    }
  
    /**
     * The account number of the bank account.
     *
     * @return accountNumber The account number of the bank account.
     */
    @JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getAccountNumber() {
      return accountNumber;
    }
  
    /**
     * The account number of the bank account.
     *
     * @param accountNumber The account number of the bank account.
     */
    @JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setAccountNumber(String accountNumber) {
      this.accountNumber = accountNumber;
    }
  
    /**
     * The 4- to 5-digit clearing number, without separators or whitespace.
     *
     * @param clearingNumber The 4- to 5-digit clearing number, without separators or whitespace.
     * @return the current {@code RIXAccountIdentifier} instance, allowing for method chaining
     */
    public RIXAccountIdentifier clearingNumber(String clearingNumber) {
      this.clearingNumber = clearingNumber;
      return this;
    }
  
    /**
     * The 4- to 5-digit clearing number, without separators or whitespace.
     *
     * @return clearingNumber The 4- to 5-digit clearing number, without separators or whitespace.
     */
    @JsonProperty(JSON_PROPERTY_CLEARING_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getClearingNumber() {
      return clearingNumber;
    }
  
    /**
     * The 4- to 5-digit clearing number, without separators or whitespace.
     *
     * @param clearingNumber The 4- to 5-digit clearing number, without separators or whitespace.
     */
    @JsonProperty(JSON_PROPERTY_CLEARING_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setClearingNumber(String clearingNumber) {
      this.clearingNumber = clearingNumber;
    }
  
    /** Return true if this RIXAccountIdentifier object is equal to o. */
    @Override
    public boolean equals(Object o) {
      if (this == o) {
        return true;
      }
      if (o == null || getClass() != o.getClass()) {
        return false;
      }
      RIXAccountIdentifier riXAccountIdentifier = (RIXAccountIdentifier) o;
      return Objects.equals(this.accountNumber, riXAccountIdentifier.accountNumber)
          && Objects.equals(this.clearingNumber, riXAccountIdentifier.clearingNumber);
    }
  
    @Override
    public int hashCode() {
      return Objects.hash(accountNumber, clearingNumber);
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append("class RIXAccountIdentifier {\n");
      sb.append("    accountNumber: ").append(toIndentedString(accountNumber)).append("\n");
      sb.append("    clearingNumber: ").append(toIndentedString(clearingNumber)).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 RIXAccountIdentifier given an JSON string
     *
     * @param jsonString JSON string
     * @return An instance of RIXAccountIdentifier
     * @throws JsonProcessingException if the JSON string is invalid with respect to
     *     RIXAccountIdentifier
     */
    public static RIXAccountIdentifier fromJson(String jsonString) throws JsonProcessingException {
      return JSON.getMapper().readValue(jsonString, RIXAccountIdentifier.class);
    }
  
    /**
     * Convert an instance of RIXAccountIdentifier to an JSON string
     *
     * @return JSON string
     */
    public String toJson() throws JsonProcessingException {
      return JSON.getMapper().writeValueAsString(this);
    }
  }
  