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.JsonCreator;
  import com.fasterxml.jackson.annotation.JsonInclude;
  import com.fasterxml.jackson.annotation.JsonProperty;
  import com.fasterxml.jackson.annotation.JsonPropertyOrder;
  import com.fasterxml.jackson.annotation.JsonValue;
  import com.fasterxml.jackson.core.JsonProcessingException;
  import java.util.*;
  import java.util.ArrayList;
  import java.util.Arrays;
  import java.util.List;
  import java.util.logging.Logger;
  
  /** UpdateStoreRequest */
  @JsonPropertyOrder({
    UpdateStoreRequest.JSON_PROPERTY_ADDRESS,
    UpdateStoreRequest.JSON_PROPERTY_BUSINESS_LINE_IDS,
    UpdateStoreRequest.JSON_PROPERTY_DESCRIPTION,
    UpdateStoreRequest.JSON_PROPERTY_EXTERNAL_REFERENCE_ID,
    UpdateStoreRequest.JSON_PROPERTY_PHONE_NUMBER,
    UpdateStoreRequest.JSON_PROPERTY_SPLIT_CONFIGURATION,
    UpdateStoreRequest.JSON_PROPERTY_STATUS,
    UpdateStoreRequest.JSON_PROPERTY_SUB_MERCHANT_DATA
  })
  public class UpdateStoreRequest {
    public static final String JSON_PROPERTY_ADDRESS = "address";
    private UpdatableAddress address;
  
    public static final String JSON_PROPERTY_BUSINESS_LINE_IDS = "businessLineIds";
    private List<String> businessLineIds;
  
    public static final String JSON_PROPERTY_DESCRIPTION = "description";
    private String description;
  
    public static final String JSON_PROPERTY_EXTERNAL_REFERENCE_ID = "externalReferenceId";
    private String externalReferenceId;
  
    public static final String JSON_PROPERTY_PHONE_NUMBER = "phoneNumber";
    private String phoneNumber;
  
    public static final String JSON_PROPERTY_SPLIT_CONFIGURATION = "splitConfiguration";
    private StoreSplitConfiguration splitConfiguration;
  
    /**
     * The status of the store. Possible values are: - **active**: This value is assigned
     * automatically when a store is created. - **inactive**: The maximum [transaction limits and
     * number of Store-and-Forward
     * transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     * for the store are set to 0. This blocks new transactions, but captures are still possible. -
     * **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     * can&#39;t process payments. You can change the status from **active** to **inactive**, and from
     * **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be reopened.
     */
    public enum StatusEnum {
      ACTIVE(String.valueOf("active")),
  
      CLOSED(String.valueOf("closed")),
  
      INACTIVE(String.valueOf("inactive"));
  
      private static final Logger LOG = Logger.getLogger(StatusEnum.class.getName());
  
      private String value;
  
      StatusEnum(String value) {
        this.value = value;
      }
  
      @JsonValue
      public String getValue() {
        return value;
      }
  
      @Override
      public String toString() {
        return String.valueOf(value);
      }
  
      @JsonCreator
      public static StatusEnum fromValue(String value) {
        for (StatusEnum b : StatusEnum.values()) {
          if (b.value.equals(value)) {
            return b;
          }
        }
        // handling unexpected value
        LOG.warning(
            "StatusEnum: unexpected enum value '"
                + value
                + "' - Supported values are "
                + Arrays.toString(StatusEnum.values()));
        return null;
      }
    }
  
    public static final String JSON_PROPERTY_STATUS = "status";
    private StatusEnum status;
  
    public static final String JSON_PROPERTY_SUB_MERCHANT_DATA = "subMerchantData";
    private SubMerchantData subMerchantData;
  
    public UpdateStoreRequest() {}
  
    /**
     * address
     *
     * @param address
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest address(UpdatableAddress address) {
      this.address = address;
      return this;
    }
  
    /**
     * Get address
     *
     * @return address
     */
    @JsonProperty(JSON_PROPERTY_ADDRESS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public UpdatableAddress getAddress() {
      return address;
    }
  
    /**
     * address
     *
     * @param address
     */
    @JsonProperty(JSON_PROPERTY_ADDRESS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setAddress(UpdatableAddress address) {
      this.address = address;
    }
  
    /**
     * The unique identifiers of the [business
     * lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     * that the store is associated with.
     *
     * @param businessLineIds The unique identifiers of the [business
     *     lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     *     that the store is associated with.
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest businessLineIds(List<String> businessLineIds) {
      this.businessLineIds = businessLineIds;
      return this;
    }
  
    public UpdateStoreRequest addBusinessLineIdsItem(String businessLineIdsItem) {
      if (this.businessLineIds == null) {
        this.businessLineIds = new ArrayList<>();
      }
      this.businessLineIds.add(businessLineIdsItem);
      return this;
    }
  
    /**
     * The unique identifiers of the [business
     * lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     * that the store is associated with.
     *
     * @return businessLineIds The unique identifiers of the [business
     *     lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     *     that the store is associated with.
     */
    @JsonProperty(JSON_PROPERTY_BUSINESS_LINE_IDS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public List<String> getBusinessLineIds() {
      return businessLineIds;
    }
  
    /**
     * The unique identifiers of the [business
     * lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     * that the store is associated with.
     *
     * @param businessLineIds The unique identifiers of the [business
     *     lines](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/businessLines__resParam_id)
     *     that the store is associated with.
     */
    @JsonProperty(JSON_PROPERTY_BUSINESS_LINE_IDS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setBusinessLineIds(List<String> businessLineIds) {
      this.businessLineIds = businessLineIds;
    }
  
    /**
     * The description of the store.
     *
     * @param description The description of the store.
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest description(String description) {
      this.description = description;
      return this;
    }
  
    /**
     * The description of the store.
     *
     * @return description The description of the store.
     */
    @JsonProperty(JSON_PROPERTY_DESCRIPTION)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getDescription() {
      return description;
    }
  
    /**
     * The description of the store.
     *
     * @param description The description of the store.
     */
    @JsonProperty(JSON_PROPERTY_DESCRIPTION)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setDescription(String description) {
      this.description = description;
    }
  
    /**
     * The unique identifier of the store, used by certain payment methods and tax authorities.
     * Required for CNPJ in Brazil, in the format 00.000.000/0000-00 separated by dots, slashes,
     * hyphens, or without separators. Optional for SIRET in France, up to 14 digits. Optional for Zip
     * in Australia, up to 50 digits.
     *
     * @param externalReferenceId The unique identifier of the store, used by certain payment methods
     *     and tax authorities. Required for CNPJ in Brazil, in the format 00.000.000/0000-00
     *     separated by dots, slashes, hyphens, or without separators. Optional for SIRET in France,
     *     up to 14 digits. Optional for Zip in Australia, up to 50 digits.
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest externalReferenceId(String externalReferenceId) {
      this.externalReferenceId = externalReferenceId;
      return this;
    }
  
    /**
     * The unique identifier of the store, used by certain payment methods and tax authorities.
     * Required for CNPJ in Brazil, in the format 00.000.000/0000-00 separated by dots, slashes,
     * hyphens, or without separators. Optional for SIRET in France, up to 14 digits. Optional for Zip
     * in Australia, up to 50 digits.
     *
     * @return externalReferenceId The unique identifier of the store, used by certain payment methods
     *     and tax authorities. Required for CNPJ in Brazil, in the format 00.000.000/0000-00
     *     separated by dots, slashes, hyphens, or without separators. Optional for SIRET in France,
     *     up to 14 digits. Optional for Zip in Australia, up to 50 digits.
     */
    @JsonProperty(JSON_PROPERTY_EXTERNAL_REFERENCE_ID)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getExternalReferenceId() {
      return externalReferenceId;
    }
  
    /**
     * The unique identifier of the store, used by certain payment methods and tax authorities.
     * Required for CNPJ in Brazil, in the format 00.000.000/0000-00 separated by dots, slashes,
     * hyphens, or without separators. Optional for SIRET in France, up to 14 digits. Optional for Zip
     * in Australia, up to 50 digits.
     *
     * @param externalReferenceId The unique identifier of the store, used by certain payment methods
     *     and tax authorities. Required for CNPJ in Brazil, in the format 00.000.000/0000-00
     *     separated by dots, slashes, hyphens, or without separators. Optional for SIRET in France,
     *     up to 14 digits. Optional for Zip in Australia, up to 50 digits.
     */
    @JsonProperty(JSON_PROPERTY_EXTERNAL_REFERENCE_ID)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setExternalReferenceId(String externalReferenceId) {
      this.externalReferenceId = externalReferenceId;
    }
  
    /**
     * The phone number of the store, including &#39;+&#39; and country code in the
     * [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format, we
     * convert and validate the phone number against E.164.
     *
     * @param phoneNumber The phone number of the store, including &#39;+&#39; and country code in the
     *     [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format, we
     *     convert and validate the phone number against E.164.
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest phoneNumber(String phoneNumber) {
      this.phoneNumber = phoneNumber;
      return this;
    }
  
    /**
     * The phone number of the store, including &#39;+&#39; and country code in the
     * [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format, we
     * convert and validate the phone number against E.164.
     *
     * @return phoneNumber The phone number of the store, including &#39;+&#39; and country code in
     *     the [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format,
     *     we convert and validate the phone number against E.164.
     */
    @JsonProperty(JSON_PROPERTY_PHONE_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public String getPhoneNumber() {
      return phoneNumber;
    }
  
    /**
     * The phone number of the store, including &#39;+&#39; and country code in the
     * [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format, we
     * convert and validate the phone number against E.164.
     *
     * @param phoneNumber The phone number of the store, including &#39;+&#39; and country code in the
     *     [E.164](https://en.wikipedia.org/wiki/E.164) format. If passed in a different format, we
     *     convert and validate the phone number against E.164.
     */
    @JsonProperty(JSON_PROPERTY_PHONE_NUMBER)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setPhoneNumber(String phoneNumber) {
      this.phoneNumber = phoneNumber;
    }
  
    /**
     * splitConfiguration
     *
     * @param splitConfiguration
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest splitConfiguration(StoreSplitConfiguration splitConfiguration) {
      this.splitConfiguration = splitConfiguration;
      return this;
    }
  
    /**
     * Get splitConfiguration
     *
     * @return splitConfiguration
     */
    @JsonProperty(JSON_PROPERTY_SPLIT_CONFIGURATION)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public StoreSplitConfiguration getSplitConfiguration() {
      return splitConfiguration;
    }
  
    /**
     * splitConfiguration
     *
     * @param splitConfiguration
     */
    @JsonProperty(JSON_PROPERTY_SPLIT_CONFIGURATION)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setSplitConfiguration(StoreSplitConfiguration splitConfiguration) {
      this.splitConfiguration = splitConfiguration;
    }
  
    /**
     * The status of the store. Possible values are: - **active**: This value is assigned
     * automatically when a store is created. - **inactive**: The maximum [transaction limits and
     * number of Store-and-Forward
     * transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     * for the store are set to 0. This blocks new transactions, but captures are still possible. -
     * **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     * can&#39;t process payments. You can change the status from **active** to **inactive**, and from
     * **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be reopened.
     *
     * @param status The status of the store. Possible values are: - **active**: This value is
     *     assigned automatically when a store is created. - **inactive**: The maximum [transaction
     *     limits and number of Store-and-Forward
     *     transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     *     for the store are set to 0. This blocks new transactions, but captures are still possible.
     *     - **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     *     can&#39;t process payments. You can change the status from **active** to **inactive**, and
     *     from **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be
     *     reopened.
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest status(StatusEnum status) {
      this.status = status;
      return this;
    }
  
    /**
     * The status of the store. Possible values are: - **active**: This value is assigned
     * automatically when a store is created. - **inactive**: The maximum [transaction limits and
     * number of Store-and-Forward
     * transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     * for the store are set to 0. This blocks new transactions, but captures are still possible. -
     * **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     * can&#39;t process payments. You can change the status from **active** to **inactive**, and from
     * **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be reopened.
     *
     * @return status The status of the store. Possible values are: - **active**: This value is
     *     assigned automatically when a store is created. - **inactive**: The maximum [transaction
     *     limits and number of Store-and-Forward
     *     transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     *     for the store are set to 0. This blocks new transactions, but captures are still possible.
     *     - **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     *     can&#39;t process payments. You can change the status from **active** to **inactive**, and
     *     from **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be
     *     reopened.
     */
    @JsonProperty(JSON_PROPERTY_STATUS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public StatusEnum getStatus() {
      return status;
    }
  
    /**
     * The status of the store. Possible values are: - **active**: This value is assigned
     * automatically when a store is created. - **inactive**: The maximum [transaction limits and
     * number of Store-and-Forward
     * transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     * for the store are set to 0. This blocks new transactions, but captures are still possible. -
     * **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     * can&#39;t process payments. You can change the status from **active** to **inactive**, and from
     * **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be reopened.
     *
     * @param status The status of the store. Possible values are: - **active**: This value is
     *     assigned automatically when a store is created. - **inactive**: The maximum [transaction
     *     limits and number of Store-and-Forward
     *     transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features)
     *     for the store are set to 0. This blocks new transactions, but captures are still possible.
     *     - **closed**: The terminals of the store are reassigned to the merchant inventory, so they
     *     can&#39;t process payments. You can change the status from **active** to **inactive**, and
     *     from **inactive** to **active** or **closed**. Once **closed**, a store can&#39;t be
     *     reopened.
     */
    @JsonProperty(JSON_PROPERTY_STATUS)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setStatus(StatusEnum status) {
      this.status = status;
    }
  
    /**
     * subMerchantData
     *
     * @param subMerchantData
     * @return the current {@code UpdateStoreRequest} instance, allowing for method chaining
     */
    public UpdateStoreRequest subMerchantData(SubMerchantData subMerchantData) {
      this.subMerchantData = subMerchantData;
      return this;
    }
  
    /**
     * Get subMerchantData
     *
     * @return subMerchantData
     */
    @JsonProperty(JSON_PROPERTY_SUB_MERCHANT_DATA)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public SubMerchantData getSubMerchantData() {
      return subMerchantData;
    }
  
    /**
     * subMerchantData
     *
     * @param subMerchantData
     */
    @JsonProperty(JSON_PROPERTY_SUB_MERCHANT_DATA)
    @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
    public void setSubMerchantData(SubMerchantData subMerchantData) {
      this.subMerchantData = subMerchantData;
    }
  
    /** Return true if this UpdateStoreRequest object is equal to o. */
    @Override
    public boolean equals(Object o) {
      if (this == o) {
        return true;
      }
      if (o == null || getClass() != o.getClass()) {
        return false;
      }
      UpdateStoreRequest updateStoreRequest = (UpdateStoreRequest) o;
      return Objects.equals(this.address, updateStoreRequest.address)
          && Objects.equals(this.businessLineIds, updateStoreRequest.businessLineIds)
          && Objects.equals(this.description, updateStoreRequest.description)
          && Objects.equals(this.externalReferenceId, updateStoreRequest.externalReferenceId)
          && Objects.equals(this.phoneNumber, updateStoreRequest.phoneNumber)
          && Objects.equals(this.splitConfiguration, updateStoreRequest.splitConfiguration)
          && Objects.equals(this.status, updateStoreRequest.status)
          && Objects.equals(this.subMerchantData, updateStoreRequest.subMerchantData);
    }
  
    @Override
    public int hashCode() {
      return Objects.hash(
          address,
          businessLineIds,
          description,
          externalReferenceId,
          phoneNumber,
          splitConfiguration,
          status,
          subMerchantData);
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append("class UpdateStoreRequest {\n");
      sb.append("    address: ").append(toIndentedString(address)).append("\n");
      sb.append("    businessLineIds: ").append(toIndentedString(businessLineIds)).append("\n");
      sb.append("    description: ").append(toIndentedString(description)).append("\n");
      sb.append("    externalReferenceId: ")
          .append(toIndentedString(externalReferenceId))
          .append("\n");
      sb.append("    phoneNumber: ").append(toIndentedString(phoneNumber)).append("\n");
      sb.append("    splitConfiguration: ").append(toIndentedString(splitConfiguration)).append("\n");
      sb.append("    status: ").append(toIndentedString(status)).append("\n");
      sb.append("    subMerchantData: ").append(toIndentedString(subMerchantData)).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 UpdateStoreRequest given an JSON string
     *
     * @param jsonString JSON string
     * @return An instance of UpdateStoreRequest
     * @throws JsonProcessingException if the JSON string is invalid with respect to
     *     UpdateStoreRequest
     */
    public static UpdateStoreRequest fromJson(String jsonString) throws JsonProcessingException {
      return JSON.getMapper().readValue(jsonString, UpdateStoreRequest.class);
    }
  
    /**
     * Convert an instance of UpdateStoreRequest to an JSON string
     *
     * @return JSON string
     */
    public String toJson() throws JsonProcessingException {
      return JSON.getMapper().writeValueAsString(this);
    }
  }
  