/*
 * Swagger of Opencellsoft Api
 * @#Introduction
 *
 * The version of the OpenAPI document: 7.3.1-SNAPSHOT
 * Contact: contact@opencellsoft.fr
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package org.openapitools.client.model;

import java.util.Objects;
import java.util.Arrays;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
import org.openapitools.client.model.AddressDto;
import org.openapitools.client.model.BusinessEntityDto;
import org.openapitools.client.model.ContactInformationDto;
import org.openapitools.client.model.CustomFieldsDto;
import org.openapitools.client.model.NameDto;
import org.openapitools.client.model.SubscriptionsDto;
import org.threeten.bp.OffsetDateTime;

/**
 * UserAccountDto
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2019-09-13T10:03:17.753Z[GMT]")
public class UserAccountDto {
  public static final String SERIALIZED_NAME_ID = "id";
  @SerializedName(SERIALIZED_NAME_ID)
  private Long id;

  public static final String SERIALIZED_NAME_CODE = "code";
  @SerializedName(SERIALIZED_NAME_CODE)
  private String code;

  public static final String SERIALIZED_NAME_DESCRIPTION = "description";
  @SerializedName(SERIALIZED_NAME_DESCRIPTION)
  private String description;

  public static final String SERIALIZED_NAME_UPDATED_CODE = "updatedCode";
  @SerializedName(SERIALIZED_NAME_UPDATED_CODE)
  private String updatedCode;

  public static final String SERIALIZED_NAME_EXTERNAL_REF1 = "externalRef1";
  @SerializedName(SERIALIZED_NAME_EXTERNAL_REF1)
  private String externalRef1;

  public static final String SERIALIZED_NAME_EXTERNAL_REF2 = "externalRef2";
  @SerializedName(SERIALIZED_NAME_EXTERNAL_REF2)
  private String externalRef2;

  public static final String SERIALIZED_NAME_NAME = "name";
  @SerializedName(SERIALIZED_NAME_NAME)
  private NameDto name;

  public static final String SERIALIZED_NAME_ADDRESS = "address";
  @SerializedName(SERIALIZED_NAME_ADDRESS)
  private AddressDto address;

  public static final String SERIALIZED_NAME_JOB_TITLE = "jobTitle";
  @SerializedName(SERIALIZED_NAME_JOB_TITLE)
  private String jobTitle;

  public static final String SERIALIZED_NAME_BUSINESS_ACCOUNT_MODEL = "businessAccountModel";
  @SerializedName(SERIALIZED_NAME_BUSINESS_ACCOUNT_MODEL)
  private BusinessEntityDto businessAccountModel;

  public static final String SERIALIZED_NAME_CUSTOM_FIELDS = "customFields";
  @SerializedName(SERIALIZED_NAME_CUSTOM_FIELDS)
  private CustomFieldsDto customFields;

  public static final String SERIALIZED_NAME_LOADED = "loaded";
  @SerializedName(SERIALIZED_NAME_LOADED)
  private Boolean loaded;

  public static final String SERIALIZED_NAME_VAT_NO = "vatNo";
  @SerializedName(SERIALIZED_NAME_VAT_NO)
  private String vatNo;

  public static final String SERIALIZED_NAME_REGISTRATION_NO = "registrationNo";
  @SerializedName(SERIALIZED_NAME_REGISTRATION_NO)
  private String registrationNo;

  public static final String SERIALIZED_NAME_CONTACT_INFORMATION = "contactInformation";
  @SerializedName(SERIALIZED_NAME_CONTACT_INFORMATION)
  private ContactInformationDto contactInformation;

  public static final String SERIALIZED_NAME_BILLING_ACCOUNT = "billingAccount";
  @SerializedName(SERIALIZED_NAME_BILLING_ACCOUNT)
  private String billingAccount;

  public static final String SERIALIZED_NAME_BILLING_ACCOUNT_DESCRIPTION = "billingAccountDescription";
  @SerializedName(SERIALIZED_NAME_BILLING_ACCOUNT_DESCRIPTION)
  private String billingAccountDescription;

  public static final String SERIALIZED_NAME_CUSTOMER_ACCOUNT = "customerAccount";
  @SerializedName(SERIALIZED_NAME_CUSTOMER_ACCOUNT)
  private String customerAccount;

  public static final String SERIALIZED_NAME_CUSTOMER_ACCOUNT_DESCRIPTION = "customerAccountDescription";
  @SerializedName(SERIALIZED_NAME_CUSTOMER_ACCOUNT_DESCRIPTION)
  private String customerAccountDescription;

  public static final String SERIALIZED_NAME_CUSTOMER = "customer";
  @SerializedName(SERIALIZED_NAME_CUSTOMER)
  private String customer;

  public static final String SERIALIZED_NAME_CUSTOMER_DESCRIPTION = "customerDescription";
  @SerializedName(SERIALIZED_NAME_CUSTOMER_DESCRIPTION)
  private String customerDescription;

  public static final String SERIALIZED_NAME_SUBSCRIPTION_DATE = "subscriptionDate";
  @SerializedName(SERIALIZED_NAME_SUBSCRIPTION_DATE)
  private OffsetDateTime subscriptionDate;

  public static final String SERIALIZED_NAME_TERMINATION_DATE = "terminationDate";
  @SerializedName(SERIALIZED_NAME_TERMINATION_DATE)
  private OffsetDateTime terminationDate;

  /**
   * Gets or Sets status
   */
  @JsonAdapter(StatusEnum.Adapter.class)
  public enum StatusEnum {
    ACTIVE("ACTIVE"),
    
    CANCELED("CANCELED"),
    
    TERMINATED("TERMINATED"),
    
    CLOSED("CLOSED");

    private String value;

    StatusEnum(String value) {
      this.value = value;
    }

    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }

    public static StatusEnum fromValue(String value) {
      for (StatusEnum b : StatusEnum.values()) {
        if (b.value.equals(value)) {
          return b;
        }
      }
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
    }

    public static class Adapter extends TypeAdapter<StatusEnum> {
      @Override
      public void write(final JsonWriter jsonWriter, final StatusEnum enumeration) throws IOException {
        jsonWriter.value(enumeration.getValue());
      }

      @Override
      public StatusEnum read(final JsonReader jsonReader) throws IOException {
        String value = jsonReader.nextString();
        return StatusEnum.fromValue(value);
      }
    }
  }

  public static final String SERIALIZED_NAME_STATUS = "status";
  @SerializedName(SERIALIZED_NAME_STATUS)
  private StatusEnum status;

  public static final String SERIALIZED_NAME_STATUS_DATE = "statusDate";
  @SerializedName(SERIALIZED_NAME_STATUS_DATE)
  private OffsetDateTime statusDate;

  public static final String SERIALIZED_NAME_TERMINATION_REASON = "terminationReason";
  @SerializedName(SERIALIZED_NAME_TERMINATION_REASON)
  private String terminationReason;

  public static final String SERIALIZED_NAME_SUBSCRIPTIONS = "subscriptions";
  @SerializedName(SERIALIZED_NAME_SUBSCRIPTIONS)
  private SubscriptionsDto subscriptions;


  public UserAccountDto id(Long id) {
    
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public Long getId() {
    return id;
  }



  public void setId(Long id) {
    this.id = id;
  }


  public UserAccountDto code(String code) {
    
    this.code = code;
    return this;
  }

   /**
   * Get code
   * @return code
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCode() {
    return code;
  }



  public void setCode(String code) {
    this.code = code;
  }


  public UserAccountDto description(String description) {
    
    this.description = description;
    return this;
  }

   /**
   * Get description
   * @return description
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getDescription() {
    return description;
  }



  public void setDescription(String description) {
    this.description = description;
  }


  public UserAccountDto updatedCode(String updatedCode) {
    
    this.updatedCode = updatedCode;
    return this;
  }

   /**
   * Get updatedCode
   * @return updatedCode
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getUpdatedCode() {
    return updatedCode;
  }



  public void setUpdatedCode(String updatedCode) {
    this.updatedCode = updatedCode;
  }


  public UserAccountDto externalRef1(String externalRef1) {
    
    this.externalRef1 = externalRef1;
    return this;
  }

   /**
   * Get externalRef1
   * @return externalRef1
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getExternalRef1() {
    return externalRef1;
  }



  public void setExternalRef1(String externalRef1) {
    this.externalRef1 = externalRef1;
  }


  public UserAccountDto externalRef2(String externalRef2) {
    
    this.externalRef2 = externalRef2;
    return this;
  }

   /**
   * Get externalRef2
   * @return externalRef2
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getExternalRef2() {
    return externalRef2;
  }



  public void setExternalRef2(String externalRef2) {
    this.externalRef2 = externalRef2;
  }


  public UserAccountDto name(NameDto name) {
    
    this.name = name;
    return this;
  }

   /**
   * Get name
   * @return name
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public NameDto getName() {
    return name;
  }



  public void setName(NameDto name) {
    this.name = name;
  }


  public UserAccountDto address(AddressDto address) {
    
    this.address = address;
    return this;
  }

   /**
   * Get address
   * @return address
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public AddressDto getAddress() {
    return address;
  }



  public void setAddress(AddressDto address) {
    this.address = address;
  }


  public UserAccountDto jobTitle(String jobTitle) {
    
    this.jobTitle = jobTitle;
    return this;
  }

   /**
   * Get jobTitle
   * @return jobTitle
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getJobTitle() {
    return jobTitle;
  }



  public void setJobTitle(String jobTitle) {
    this.jobTitle = jobTitle;
  }


  public UserAccountDto businessAccountModel(BusinessEntityDto businessAccountModel) {
    
    this.businessAccountModel = businessAccountModel;
    return this;
  }

   /**
   * Get businessAccountModel
   * @return businessAccountModel
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public BusinessEntityDto getBusinessAccountModel() {
    return businessAccountModel;
  }



  public void setBusinessAccountModel(BusinessEntityDto businessAccountModel) {
    this.businessAccountModel = businessAccountModel;
  }


  public UserAccountDto customFields(CustomFieldsDto customFields) {
    
    this.customFields = customFields;
    return this;
  }

   /**
   * Get customFields
   * @return customFields
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public CustomFieldsDto getCustomFields() {
    return customFields;
  }



  public void setCustomFields(CustomFieldsDto customFields) {
    this.customFields = customFields;
  }


  public UserAccountDto loaded(Boolean loaded) {
    
    this.loaded = loaded;
    return this;
  }

   /**
   * Get loaded
   * @return loaded
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public Boolean getLoaded() {
    return loaded;
  }



  public void setLoaded(Boolean loaded) {
    this.loaded = loaded;
  }


  public UserAccountDto vatNo(String vatNo) {
    
    this.vatNo = vatNo;
    return this;
  }

   /**
   * Get vatNo
   * @return vatNo
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getVatNo() {
    return vatNo;
  }



  public void setVatNo(String vatNo) {
    this.vatNo = vatNo;
  }


  public UserAccountDto registrationNo(String registrationNo) {
    
    this.registrationNo = registrationNo;
    return this;
  }

   /**
   * Get registrationNo
   * @return registrationNo
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getRegistrationNo() {
    return registrationNo;
  }



  public void setRegistrationNo(String registrationNo) {
    this.registrationNo = registrationNo;
  }


  public UserAccountDto contactInformation(ContactInformationDto contactInformation) {
    
    this.contactInformation = contactInformation;
    return this;
  }

   /**
   * Get contactInformation
   * @return contactInformation
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public ContactInformationDto getContactInformation() {
    return contactInformation;
  }



  public void setContactInformation(ContactInformationDto contactInformation) {
    this.contactInformation = contactInformation;
  }


  public UserAccountDto billingAccount(String billingAccount) {
    
    this.billingAccount = billingAccount;
    return this;
  }

   /**
   * Get billingAccount
   * @return billingAccount
  **/
  @ApiModelProperty(required = true, value = "")

  public String getBillingAccount() {
    return billingAccount;
  }



  public void setBillingAccount(String billingAccount) {
    this.billingAccount = billingAccount;
  }


  public UserAccountDto billingAccountDescription(String billingAccountDescription) {
    
    this.billingAccountDescription = billingAccountDescription;
    return this;
  }

   /**
   * Get billingAccountDescription
   * @return billingAccountDescription
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getBillingAccountDescription() {
    return billingAccountDescription;
  }



  public void setBillingAccountDescription(String billingAccountDescription) {
    this.billingAccountDescription = billingAccountDescription;
  }


  public UserAccountDto customerAccount(String customerAccount) {
    
    this.customerAccount = customerAccount;
    return this;
  }

   /**
   * Get customerAccount
   * @return customerAccount
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCustomerAccount() {
    return customerAccount;
  }



  public void setCustomerAccount(String customerAccount) {
    this.customerAccount = customerAccount;
  }


  public UserAccountDto customerAccountDescription(String customerAccountDescription) {
    
    this.customerAccountDescription = customerAccountDescription;
    return this;
  }

   /**
   * Get customerAccountDescription
   * @return customerAccountDescription
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCustomerAccountDescription() {
    return customerAccountDescription;
  }



  public void setCustomerAccountDescription(String customerAccountDescription) {
    this.customerAccountDescription = customerAccountDescription;
  }


  public UserAccountDto customer(String customer) {
    
    this.customer = customer;
    return this;
  }

   /**
   * Get customer
   * @return customer
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCustomer() {
    return customer;
  }



  public void setCustomer(String customer) {
    this.customer = customer;
  }


  public UserAccountDto customerDescription(String customerDescription) {
    
    this.customerDescription = customerDescription;
    return this;
  }

   /**
   * Get customerDescription
   * @return customerDescription
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getCustomerDescription() {
    return customerDescription;
  }



  public void setCustomerDescription(String customerDescription) {
    this.customerDescription = customerDescription;
  }


  public UserAccountDto subscriptionDate(OffsetDateTime subscriptionDate) {
    
    this.subscriptionDate = subscriptionDate;
    return this;
  }

   /**
   * Get subscriptionDate
   * @return subscriptionDate
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public OffsetDateTime getSubscriptionDate() {
    return subscriptionDate;
  }



  public void setSubscriptionDate(OffsetDateTime subscriptionDate) {
    this.subscriptionDate = subscriptionDate;
  }


  public UserAccountDto terminationDate(OffsetDateTime terminationDate) {
    
    this.terminationDate = terminationDate;
    return this;
  }

   /**
   * Get terminationDate
   * @return terminationDate
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public OffsetDateTime getTerminationDate() {
    return terminationDate;
  }



  public void setTerminationDate(OffsetDateTime terminationDate) {
    this.terminationDate = terminationDate;
  }


  public UserAccountDto status(StatusEnum status) {
    
    this.status = status;
    return this;
  }

   /**
   * Get status
   * @return status
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public StatusEnum getStatus() {
    return status;
  }



  public void setStatus(StatusEnum status) {
    this.status = status;
  }


  public UserAccountDto statusDate(OffsetDateTime statusDate) {
    
    this.statusDate = statusDate;
    return this;
  }

   /**
   * Get statusDate
   * @return statusDate
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public OffsetDateTime getStatusDate() {
    return statusDate;
  }



  public void setStatusDate(OffsetDateTime statusDate) {
    this.statusDate = statusDate;
  }


  public UserAccountDto terminationReason(String terminationReason) {
    
    this.terminationReason = terminationReason;
    return this;
  }

   /**
   * Get terminationReason
   * @return terminationReason
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public String getTerminationReason() {
    return terminationReason;
  }



  public void setTerminationReason(String terminationReason) {
    this.terminationReason = terminationReason;
  }


  public UserAccountDto subscriptions(SubscriptionsDto subscriptions) {
    
    this.subscriptions = subscriptions;
    return this;
  }

   /**
   * Get subscriptions
   * @return subscriptions
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "")

  public SubscriptionsDto getSubscriptions() {
    return subscriptions;
  }



  public void setSubscriptions(SubscriptionsDto subscriptions) {
    this.subscriptions = subscriptions;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    UserAccountDto userAccountDto = (UserAccountDto) o;
    return Objects.equals(this.id, userAccountDto.id) &&
        Objects.equals(this.code, userAccountDto.code) &&
        Objects.equals(this.description, userAccountDto.description) &&
        Objects.equals(this.updatedCode, userAccountDto.updatedCode) &&
        Objects.equals(this.externalRef1, userAccountDto.externalRef1) &&
        Objects.equals(this.externalRef2, userAccountDto.externalRef2) &&
        Objects.equals(this.name, userAccountDto.name) &&
        Objects.equals(this.address, userAccountDto.address) &&
        Objects.equals(this.jobTitle, userAccountDto.jobTitle) &&
        Objects.equals(this.businessAccountModel, userAccountDto.businessAccountModel) &&
        Objects.equals(this.customFields, userAccountDto.customFields) &&
        Objects.equals(this.loaded, userAccountDto.loaded) &&
        Objects.equals(this.vatNo, userAccountDto.vatNo) &&
        Objects.equals(this.registrationNo, userAccountDto.registrationNo) &&
        Objects.equals(this.contactInformation, userAccountDto.contactInformation) &&
        Objects.equals(this.billingAccount, userAccountDto.billingAccount) &&
        Objects.equals(this.billingAccountDescription, userAccountDto.billingAccountDescription) &&
        Objects.equals(this.customerAccount, userAccountDto.customerAccount) &&
        Objects.equals(this.customerAccountDescription, userAccountDto.customerAccountDescription) &&
        Objects.equals(this.customer, userAccountDto.customer) &&
        Objects.equals(this.customerDescription, userAccountDto.customerDescription) &&
        Objects.equals(this.subscriptionDate, userAccountDto.subscriptionDate) &&
        Objects.equals(this.terminationDate, userAccountDto.terminationDate) &&
        Objects.equals(this.status, userAccountDto.status) &&
        Objects.equals(this.statusDate, userAccountDto.statusDate) &&
        Objects.equals(this.terminationReason, userAccountDto.terminationReason) &&
        Objects.equals(this.subscriptions, userAccountDto.subscriptions);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, code, description, updatedCode, externalRef1, externalRef2, name, address, jobTitle, businessAccountModel, customFields, loaded, vatNo, registrationNo, contactInformation, billingAccount, billingAccountDescription, customerAccount, customerAccountDescription, customer, customerDescription, subscriptionDate, terminationDate, status, statusDate, terminationReason, subscriptions);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class UserAccountDto {\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    code: ").append(toIndentedString(code)).append("\n");
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
    sb.append("    updatedCode: ").append(toIndentedString(updatedCode)).append("\n");
    sb.append("    externalRef1: ").append(toIndentedString(externalRef1)).append("\n");
    sb.append("    externalRef2: ").append(toIndentedString(externalRef2)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    address: ").append(toIndentedString(address)).append("\n");
    sb.append("    jobTitle: ").append(toIndentedString(jobTitle)).append("\n");
    sb.append("    businessAccountModel: ").append(toIndentedString(businessAccountModel)).append("\n");
    sb.append("    customFields: ").append(toIndentedString(customFields)).append("\n");
    sb.append("    loaded: ").append(toIndentedString(loaded)).append("\n");
    sb.append("    vatNo: ").append(toIndentedString(vatNo)).append("\n");
    sb.append("    registrationNo: ").append(toIndentedString(registrationNo)).append("\n");
    sb.append("    contactInformation: ").append(toIndentedString(contactInformation)).append("\n");
    sb.append("    billingAccount: ").append(toIndentedString(billingAccount)).append("\n");
    sb.append("    billingAccountDescription: ").append(toIndentedString(billingAccountDescription)).append("\n");
    sb.append("    customerAccount: ").append(toIndentedString(customerAccount)).append("\n");
    sb.append("    customerAccountDescription: ").append(toIndentedString(customerAccountDescription)).append("\n");
    sb.append("    customer: ").append(toIndentedString(customer)).append("\n");
    sb.append("    customerDescription: ").append(toIndentedString(customerDescription)).append("\n");
    sb.append("    subscriptionDate: ").append(toIndentedString(subscriptionDate)).append("\n");
    sb.append("    terminationDate: ").append(toIndentedString(terminationDate)).append("\n");
    sb.append("    status: ").append(toIndentedString(status)).append("\n");
    sb.append("    statusDate: ").append(toIndentedString(statusDate)).append("\n");
    sb.append("    terminationReason: ").append(toIndentedString(terminationReason)).append("\n");
    sb.append("    subscriptions: ").append(toIndentedString(subscriptions)).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(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}

