/*
 * 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 java.util.ArrayList;
import java.util.List;
import org.openapitools.client.model.AddressDto;
import org.openapitools.client.model.BusinessEntityDto;
import org.openapitools.client.model.CommunicationPolicy;
import org.openapitools.client.model.ContactInformationDto;
import org.openapitools.client.model.CustomFieldsDto;
import org.openapitools.client.model.NameDto;

/**
 * ContactDto
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2019-09-13T10:03:17.753Z[GMT]")
public class ContactDto {
  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_EMAIL = "email";
  @SerializedName(SERIALIZED_NAME_EMAIL)
  private String email;

  public static final String SERIALIZED_NAME_ASSISTANT_NAME = "assistantName";
  @SerializedName(SERIALIZED_NAME_ASSISTANT_NAME)
  private String assistantName;

  public static final String SERIALIZED_NAME_ASSISTANT_PHONE = "assistantPhone";
  @SerializedName(SERIALIZED_NAME_ASSISTANT_PHONE)
  private String assistantPhone;

  public static final String SERIALIZED_NAME_POSITION = "position";
  @SerializedName(SERIALIZED_NAME_POSITION)
  private String position;

  public static final String SERIALIZED_NAME_COMPANY = "company";
  @SerializedName(SERIALIZED_NAME_COMPANY)
  private String company;

  public static final String SERIALIZED_NAME_MOBILE = "mobile";
  @SerializedName(SERIALIZED_NAME_MOBILE)
  private String mobile;

  public static final String SERIALIZED_NAME_PHONE = "phone";
  @SerializedName(SERIALIZED_NAME_PHONE)
  private String phone;

  public static final String SERIALIZED_NAME_WEBSITE_URL = "websiteUrl";
  @SerializedName(SERIALIZED_NAME_WEBSITE_URL)
  private String websiteUrl;

  public static final String SERIALIZED_NAME_IMPORTED_FROM = "importedFrom";
  @SerializedName(SERIALIZED_NAME_IMPORTED_FROM)
  private String importedFrom;

  public static final String SERIALIZED_NAME_IMPORTED_BY = "importedBy";
  @SerializedName(SERIALIZED_NAME_IMPORTED_BY)
  private String importedBy;

  public static final String SERIALIZED_NAME_SOCIAL_IDENTIFIER = "socialIdentifier";
  @SerializedName(SERIALIZED_NAME_SOCIAL_IDENTIFIER)
  private String socialIdentifier;

  public static final String SERIALIZED_NAME_AGREED_TO_U_A = "agreedToUA";
  @SerializedName(SERIALIZED_NAME_AGREED_TO_U_A)
  private Boolean agreedToUA;

  public static final String SERIALIZED_NAME_CONTACT_POLICY = "contactPolicy";
  @SerializedName(SERIALIZED_NAME_CONTACT_POLICY)
  private CommunicationPolicy contactPolicy;

  public static final String SERIALIZED_NAME_TAGS = "tags";
  @SerializedName(SERIALIZED_NAME_TAGS)
  private List<String> tags = null;

  public static final String SERIALIZED_NAME_VIP = "vip";
  @SerializedName(SERIALIZED_NAME_VIP)
  private Boolean vip;

  public static final String SERIALIZED_NAME_PROSPECT = "prospect";
  @SerializedName(SERIALIZED_NAME_PROSPECT)
  private Boolean prospect;


  public ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto 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 ContactDto email(String email) {
    
    this.email = email;
    return this;
  }

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

  public String getEmail() {
    return email;
  }



  public void setEmail(String email) {
    this.email = email;
  }


  public ContactDto assistantName(String assistantName) {
    
    this.assistantName = assistantName;
    return this;
  }

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

  public String getAssistantName() {
    return assistantName;
  }



  public void setAssistantName(String assistantName) {
    this.assistantName = assistantName;
  }


  public ContactDto assistantPhone(String assistantPhone) {
    
    this.assistantPhone = assistantPhone;
    return this;
  }

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

  public String getAssistantPhone() {
    return assistantPhone;
  }



  public void setAssistantPhone(String assistantPhone) {
    this.assistantPhone = assistantPhone;
  }


  public ContactDto position(String position) {
    
    this.position = position;
    return this;
  }

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

  public String getPosition() {
    return position;
  }



  public void setPosition(String position) {
    this.position = position;
  }


  public ContactDto company(String company) {
    
    this.company = company;
    return this;
  }

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

  public String getCompany() {
    return company;
  }



  public void setCompany(String company) {
    this.company = company;
  }


  public ContactDto mobile(String mobile) {
    
    this.mobile = mobile;
    return this;
  }

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

  public String getMobile() {
    return mobile;
  }



  public void setMobile(String mobile) {
    this.mobile = mobile;
  }


  public ContactDto phone(String phone) {
    
    this.phone = phone;
    return this;
  }

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

  public String getPhone() {
    return phone;
  }



  public void setPhone(String phone) {
    this.phone = phone;
  }


  public ContactDto websiteUrl(String websiteUrl) {
    
    this.websiteUrl = websiteUrl;
    return this;
  }

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

  public String getWebsiteUrl() {
    return websiteUrl;
  }



  public void setWebsiteUrl(String websiteUrl) {
    this.websiteUrl = websiteUrl;
  }


  public ContactDto importedFrom(String importedFrom) {
    
    this.importedFrom = importedFrom;
    return this;
  }

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

  public String getImportedFrom() {
    return importedFrom;
  }



  public void setImportedFrom(String importedFrom) {
    this.importedFrom = importedFrom;
  }


  public ContactDto importedBy(String importedBy) {
    
    this.importedBy = importedBy;
    return this;
  }

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

  public String getImportedBy() {
    return importedBy;
  }



  public void setImportedBy(String importedBy) {
    this.importedBy = importedBy;
  }


  public ContactDto socialIdentifier(String socialIdentifier) {
    
    this.socialIdentifier = socialIdentifier;
    return this;
  }

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

  public String getSocialIdentifier() {
    return socialIdentifier;
  }



  public void setSocialIdentifier(String socialIdentifier) {
    this.socialIdentifier = socialIdentifier;
  }


  public ContactDto agreedToUA(Boolean agreedToUA) {
    
    this.agreedToUA = agreedToUA;
    return this;
  }

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

  public Boolean getAgreedToUA() {
    return agreedToUA;
  }



  public void setAgreedToUA(Boolean agreedToUA) {
    this.agreedToUA = agreedToUA;
  }


  public ContactDto contactPolicy(CommunicationPolicy contactPolicy) {
    
    this.contactPolicy = contactPolicy;
    return this;
  }

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

  public CommunicationPolicy getContactPolicy() {
    return contactPolicy;
  }



  public void setContactPolicy(CommunicationPolicy contactPolicy) {
    this.contactPolicy = contactPolicy;
  }


  public ContactDto tags(List<String> tags) {
    
    this.tags = tags;
    return this;
  }

  public ContactDto addTagsItem(String tagsItem) {
    if (this.tags == null) {
      this.tags = new ArrayList<String>();
    }
    this.tags.add(tagsItem);
    return this;
  }

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

  public List<String> getTags() {
    return tags;
  }



  public void setTags(List<String> tags) {
    this.tags = tags;
  }


  public ContactDto vip(Boolean vip) {
    
    this.vip = vip;
    return this;
  }

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

  public Boolean getVip() {
    return vip;
  }



  public void setVip(Boolean vip) {
    this.vip = vip;
  }


  public ContactDto prospect(Boolean prospect) {
    
    this.prospect = prospect;
    return this;
  }

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

  public Boolean getProspect() {
    return prospect;
  }



  public void setProspect(Boolean prospect) {
    this.prospect = prospect;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ContactDto contactDto = (ContactDto) o;
    return Objects.equals(this.id, contactDto.id) &&
        Objects.equals(this.code, contactDto.code) &&
        Objects.equals(this.description, contactDto.description) &&
        Objects.equals(this.updatedCode, contactDto.updatedCode) &&
        Objects.equals(this.externalRef1, contactDto.externalRef1) &&
        Objects.equals(this.externalRef2, contactDto.externalRef2) &&
        Objects.equals(this.name, contactDto.name) &&
        Objects.equals(this.address, contactDto.address) &&
        Objects.equals(this.jobTitle, contactDto.jobTitle) &&
        Objects.equals(this.businessAccountModel, contactDto.businessAccountModel) &&
        Objects.equals(this.customFields, contactDto.customFields) &&
        Objects.equals(this.loaded, contactDto.loaded) &&
        Objects.equals(this.vatNo, contactDto.vatNo) &&
        Objects.equals(this.registrationNo, contactDto.registrationNo) &&
        Objects.equals(this.contactInformation, contactDto.contactInformation) &&
        Objects.equals(this.email, contactDto.email) &&
        Objects.equals(this.assistantName, contactDto.assistantName) &&
        Objects.equals(this.assistantPhone, contactDto.assistantPhone) &&
        Objects.equals(this.position, contactDto.position) &&
        Objects.equals(this.company, contactDto.company) &&
        Objects.equals(this.mobile, contactDto.mobile) &&
        Objects.equals(this.phone, contactDto.phone) &&
        Objects.equals(this.websiteUrl, contactDto.websiteUrl) &&
        Objects.equals(this.importedFrom, contactDto.importedFrom) &&
        Objects.equals(this.importedBy, contactDto.importedBy) &&
        Objects.equals(this.socialIdentifier, contactDto.socialIdentifier) &&
        Objects.equals(this.agreedToUA, contactDto.agreedToUA) &&
        Objects.equals(this.contactPolicy, contactDto.contactPolicy) &&
        Objects.equals(this.tags, contactDto.tags) &&
        Objects.equals(this.vip, contactDto.vip) &&
        Objects.equals(this.prospect, contactDto.prospect);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, code, description, updatedCode, externalRef1, externalRef2, name, address, jobTitle, businessAccountModel, customFields, loaded, vatNo, registrationNo, contactInformation, email, assistantName, assistantPhone, position, company, mobile, phone, websiteUrl, importedFrom, importedBy, socialIdentifier, agreedToUA, contactPolicy, tags, vip, prospect);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ContactDto {\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("    email: ").append(toIndentedString(email)).append("\n");
    sb.append("    assistantName: ").append(toIndentedString(assistantName)).append("\n");
    sb.append("    assistantPhone: ").append(toIndentedString(assistantPhone)).append("\n");
    sb.append("    position: ").append(toIndentedString(position)).append("\n");
    sb.append("    company: ").append(toIndentedString(company)).append("\n");
    sb.append("    mobile: ").append(toIndentedString(mobile)).append("\n");
    sb.append("    phone: ").append(toIndentedString(phone)).append("\n");
    sb.append("    websiteUrl: ").append(toIndentedString(websiteUrl)).append("\n");
    sb.append("    importedFrom: ").append(toIndentedString(importedFrom)).append("\n");
    sb.append("    importedBy: ").append(toIndentedString(importedBy)).append("\n");
    sb.append("    socialIdentifier: ").append(toIndentedString(socialIdentifier)).append("\n");
    sb.append("    agreedToUA: ").append(toIndentedString(agreedToUA)).append("\n");
    sb.append("    contactPolicy: ").append(toIndentedString(contactPolicy)).append("\n");
    sb.append("    tags: ").append(toIndentedString(tags)).append("\n");
    sb.append("    vip: ").append(toIndentedString(vip)).append("\n");
    sb.append("    prospect: ").append(toIndentedString(prospect)).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    ");
  }

}

