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.*;
  
  /** BSBAccountIdentifier */
  @JsonPropertyOrder({
    BSBAccountIdentifier.JSON_PROPERTY_ACCOUNT_NUMBER,
    BSBAccountIdentifier.JSON_PROPERTY_BSB_CODE
  })
  public class BSBAccountIdentifier {
    public static final String JSON_PROPERTY_ACCOUNT_NUMBER = "accountNumber";
    private String accountNumber;
  
    public static final String JSON_PROPERTY_BSB_CODE = "bsbCode";
    private String bsbCode;
  
    public BSBAccountIdentifier() {}
  
    /**
     * The account number of the bank account.
     *
     * @param accountNumber The account number of the bank account.
     * @return the current {@code BSBAccountIdentifier} instance, allowing for method chaining
     */
    public BSBAccountIdentifier 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 BSB (Bank-State-Branch) code.
     *
     * @param bsbCode The BSB (Bank-State-Branch) code.
     * @return the current {@code BSBAccountIdentifier} instance, allowing for method chaining
     */
    public BSBAccountIdentifier bsbCode(String bsbCode) {
      this.bsbCode = bsbCode;
      return this;
    }
  
    /**
     * The BSB (Bank-State-Branch) code.
     *
     * @return bsbCode The BSB (Bank-State-Branch) code.
     */
    @JsonProperty(JSON_PROPERTY_BSB_CODE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getBsbCode() {
      return bsbCode;
    }
  
    /**
     * The BSB (Bank-State-Branch) code.
     *
     * @param bsbCode The BSB (Bank-State-Branch) code.
     */
    @JsonProperty(JSON_PROPERTY_BSB_CODE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setBsbCode(String bsbCode) {
      this.bsbCode = bsbCode;
    }
  
    /** Return true if this BSBAccountIdentifier object is equal to o. */
    @Override
    public boolean equals(Object o) {
      if (this == o) {
        return true;
      }
      if (o == null || getClass() != o.getClass()) {
        return false;
      }
      BSBAccountIdentifier bsBAccountIdentifier = (BSBAccountIdentifier) o;
      return Objects.equals(this.accountNumber, bsBAccountIdentifier.accountNumber)
          && Objects.equals(this.bsbCode, bsBAccountIdentifier.bsbCode);
    }
  
    @Override
    public int hashCode() {
      return Objects.hash(accountNumber, bsbCode);
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append("class BSBAccountIdentifier {\n");
      sb.append("    accountNumber: ").append(toIndentedString(accountNumber)).append("\n");
      sb.append("    bsbCode: ").append(toIndentedString(bsbCode)).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 BSBAccountIdentifier given an JSON string
     *
     * @param jsonString JSON string
     * @return An instance of BSBAccountIdentifier
     * @throws JsonProcessingException if the JSON string is invalid with respect to
     *     BSBAccountIdentifier
     */
    public static BSBAccountIdentifier fromJson(String jsonString) throws JsonProcessingException {
      return JSON.getMapper().readValue(jsonString, BSBAccountIdentifier.class);
    }
  
    /**
     * Convert an instance of BSBAccountIdentifier to an JSON string
     *
     * @return JSON string
     */
    public String toJson() throws JsonProcessingException {
      return JSON.getMapper().writeValueAsString(this);
    }
  }
  