content: /*
   * Management API
   *
   * The version of the OpenAPI document: 3
   *
   *
   * 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.management;
  
  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.*;
  
  /** StoreLocation */
  @JsonPropertyOrder({
    StoreLocation.JSON_PROPERTY_CITY,
    StoreLocation.JSON_PROPERTY_COUNTRY,
    StoreLocation.JSON_PROPERTY_LINE1,
    StoreLocation.JSON_PROPERTY_LINE2,
    StoreLocation.JSON_PROPERTY_LINE3,
    StoreLocation.JSON_PROPERTY_POSTAL_CODE,
    StoreLocation.JSON_PROPERTY_STATE_OR_PROVINCE
  })
  public class StoreLocation {
    public static final String JSON_PROPERTY_CITY = "city";
    private String city;
  
    public static final String JSON_PROPERTY_COUNTRY = "country";
    private String country;
  
    public static final String JSON_PROPERTY_LINE1 = "line1";
    private String line1;
  
    public static final String JSON_PROPERTY_LINE2 = "line2";
    private String line2;
  
    public static final String JSON_PROPERTY_LINE3 = "line3";
    private String line3;
  
    public static final String JSON_PROPERTY_POSTAL_CODE = "postalCode";
    private String postalCode;
  
    public static final String JSON_PROPERTY_STATE_OR_PROVINCE = "stateOrProvince";
    private String stateOrProvince;
  
    public StoreLocation() {}
  
    /**
     * The name of the city.
     *
     * @param city The name of the city.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation city(String city) {
      this.city = city;
      return this;
    }
  
    /**
     * The name of the city.
     *
     * @return city The name of the city.
     */
    @JsonProperty(JSON_PROPERTY_CITY)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getCity() {
      return city;
    }
  
    /**
     * The name of the city.
     *
     * @param city The name of the city.
     */
    @JsonProperty(JSON_PROPERTY_CITY)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setCity(String city) {
      this.city = city;
    }
  
    /**
     * The two-letter country code in
     * [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     *
     * @param country The two-letter country code in
     *     [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation country(String country) {
      this.country = country;
      return this;
    }
  
    /**
     * The two-letter country code in
     * [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     *
     * @return country The two-letter country code in
     *     [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     */
    @JsonProperty(JSON_PROPERTY_COUNTRY)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getCountry() {
      return country;
    }
  
    /**
     * The two-letter country code in
     * [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     *
     * @param country The two-letter country code in
     *     [ISO_3166-1_alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
     */
    @JsonProperty(JSON_PROPERTY_COUNTRY)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setCountry(String country) {
      this.country = country;
    }
  
    /**
     * The street address.
     *
     * @param line1 The street address.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation line1(String line1) {
      this.line1 = line1;
      return this;
    }
  
    /**
     * The street address.
     *
     * @return line1 The street address.
     */
    @JsonProperty(JSON_PROPERTY_LINE1)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getLine1() {
      return line1;
    }
  
    /**
     * The street address.
     *
     * @param line1 The street address.
     */
    @JsonProperty(JSON_PROPERTY_LINE1)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setLine1(String line1) {
      this.line1 = line1;
    }
  
    /**
     * Second address line.
     *
     * @param line2 Second address line.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation line2(String line2) {
      this.line2 = line2;
      return this;
    }
  
    /**
     * Second address line.
     *
     * @return line2 Second address line.
     */
    @JsonProperty(JSON_PROPERTY_LINE2)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getLine2() {
      return line2;
    }
  
    /**
     * Second address line.
     *
     * @param line2 Second address line.
     */
    @JsonProperty(JSON_PROPERTY_LINE2)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setLine2(String line2) {
      this.line2 = line2;
    }
  
    /**
     * Third address line.
     *
     * @param line3 Third address line.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation line3(String line3) {
      this.line3 = line3;
      return this;
    }
  
    /**
     * Third address line.
     *
     * @return line3 Third address line.
     */
    @JsonProperty(JSON_PROPERTY_LINE3)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getLine3() {
      return line3;
    }
  
    /**
     * Third address line.
     *
     * @param line3 Third address line.
     */
    @JsonProperty(JSON_PROPERTY_LINE3)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setLine3(String line3) {
      this.line3 = line3;
    }
  
    /**
     * The postal code.
     *
     * @param postalCode The postal code.
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation postalCode(String postalCode) {
      this.postalCode = postalCode;
      return this;
    }
  
    /**
     * The postal code.
     *
     * @return postalCode The postal code.
     */
    @JsonProperty(JSON_PROPERTY_POSTAL_CODE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getPostalCode() {
      return postalCode;
    }
  
    /**
     * The postal code.
     *
     * @param postalCode The postal code.
     */
    @JsonProperty(JSON_PROPERTY_POSTAL_CODE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setPostalCode(String postalCode) {
      this.postalCode = postalCode;
    }
  
    /**
     * The state or province code as defined in [ISO 3166-2](https://www.iso.org/standard/72483.html).
     * For example, **ON** for Ontario, Canada. Required for the following countries: - Australia -
     * Brazil - Canada - India - Mexico - New Zealand - United States
     *
     * @param stateOrProvince The state or province code as defined in [ISO
     *     3166-2](https://www.iso.org/standard/72483.html). For example, **ON** for Ontario, Canada.
     *     Required for the following countries: - Australia - Brazil - Canada - India - Mexico - New
     *     Zealand - United States
     * @return the current {@code StoreLocation} instance, allowing for method chaining
     */
    public StoreLocation stateOrProvince(String stateOrProvince) {
      this.stateOrProvince = stateOrProvince;
      return this;
    }
  
    /**
     * The state or province code as defined in [ISO 3166-2](https://www.iso.org/standard/72483.html).
     * For example, **ON** for Ontario, Canada. Required for the following countries: - Australia -
     * Brazil - Canada - India - Mexico - New Zealand - United States
     *
     * @return stateOrProvince The state or province code as defined in [ISO
     *     3166-2](https://www.iso.org/standard/72483.html). For example, **ON** for Ontario, Canada.
     *     Required for the following countries: - Australia - Brazil - Canada - India - Mexico - New
     *     Zealand - United States
     */
    @JsonProperty(JSON_PROPERTY_STATE_OR_PROVINCE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getStateOrProvince() {
      return stateOrProvince;
    }
  
    /**
     * The state or province code as defined in [ISO 3166-2](https://www.iso.org/standard/72483.html).
     * For example, **ON** for Ontario, Canada. Required for the following countries: - Australia -
     * Brazil - Canada - India - Mexico - New Zealand - United States
     *
     * @param stateOrProvince The state or province code as defined in [ISO
     *     3166-2](https://www.iso.org/standard/72483.html). For example, **ON** for Ontario, Canada.
     *     Required for the following countries: - Australia - Brazil - Canada - India - Mexico - New
     *     Zealand - United States
     */
    @JsonProperty(JSON_PROPERTY_STATE_OR_PROVINCE)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setStateOrProvince(String stateOrProvince) {
      this.stateOrProvince = stateOrProvince;
    }
  
    /** Return true if this StoreLocation object is equal to o. */
    @Override
    public boolean equals(Object o) {
      if (this == o) {
        return true;
      }
      if (o == null || getClass() != o.getClass()) {
        return false;
      }
      StoreLocation storeLocation = (StoreLocation) o;
      return Objects.equals(this.city, storeLocation.city)
          && Objects.equals(this.country, storeLocation.country)
          && Objects.equals(this.line1, storeLocation.line1)
          && Objects.equals(this.line2, storeLocation.line2)
          && Objects.equals(this.line3, storeLocation.line3)
          && Objects.equals(this.postalCode, storeLocation.postalCode)
          && Objects.equals(this.stateOrProvince, storeLocation.stateOrProvince);
    }
  
    @Override
    public int hashCode() {
      return Objects.hash(city, country, line1, line2, line3, postalCode, stateOrProvince);
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append("class StoreLocation {\n");
      sb.append("    city: ").append(toIndentedString(city)).append("\n");
      sb.append("    country: ").append(toIndentedString(country)).append("\n");
      sb.append("    line1: ").append(toIndentedString(line1)).append("\n");
      sb.append("    line2: ").append(toIndentedString(line2)).append("\n");
      sb.append("    line3: ").append(toIndentedString(line3)).append("\n");
      sb.append("    postalCode: ").append(toIndentedString(postalCode)).append("\n");
      sb.append("    stateOrProvince: ").append(toIndentedString(stateOrProvince)).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 StoreLocation given an JSON string
     *
     * @param jsonString JSON string
     * @return An instance of StoreLocation
     * @throws JsonProcessingException if the JSON string is invalid with respect to StoreLocation
     */
    public static StoreLocation fromJson(String jsonString) throws JsonProcessingException {
      return JSON.getMapper().readValue(jsonString, StoreLocation.class);
    }
  
    /**
     * Convert an instance of StoreLocation to an JSON string
     *
     * @return JSON string
     */
    public String toJson() throws JsonProcessingException {
      return JSON.getMapper().writeValueAsString(this);
    }
  }
  