/*
 * 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.CustomFieldsDto;
import org.openapitools.client.model.ServiceChargeTemplateRecurringsDto;
import org.openapitools.client.model.ServiceChargeTemplateSubscriptionsDto;
import org.openapitools.client.model.ServiceChargeTemplateTerminationsDto;
import org.openapitools.client.model.ServiceChargeTemplateUsagesDto;
import org.openapitools.client.model.SubscriptionRenewalDto;

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

  public static final String SERIALIZED_NAME_LONG_DESCRIPTION = "longDescription";
  @SerializedName(SERIALIZED_NAME_LONG_DESCRIPTION)
  private String longDescription;

  public static final String SERIALIZED_NAME_INVOICING_CALENDAR = "invoicingCalendar";
  @SerializedName(SERIALIZED_NAME_INVOICING_CALENDAR)
  private String invoicingCalendar;

  public static final String SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_RECURRINGS = "serviceChargeTemplateRecurrings";
  @SerializedName(SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_RECURRINGS)
  private ServiceChargeTemplateRecurringsDto serviceChargeTemplateRecurrings;

  public static final String SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_SUBSCRIPTIONS = "serviceChargeTemplateSubscriptions";
  @SerializedName(SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_SUBSCRIPTIONS)
  private ServiceChargeTemplateSubscriptionsDto serviceChargeTemplateSubscriptions;

  public static final String SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_TERMINATIONS = "serviceChargeTemplateTerminations";
  @SerializedName(SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_TERMINATIONS)
  private ServiceChargeTemplateTerminationsDto serviceChargeTemplateTerminations;

  public static final String SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_USAGES = "serviceChargeTemplateUsages";
  @SerializedName(SERIALIZED_NAME_SERVICE_CHARGE_TEMPLATE_USAGES)
  private ServiceChargeTemplateUsagesDto serviceChargeTemplateUsages;

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

  public static final String SERIALIZED_NAME_MANDATORY = "mandatory";
  @SerializedName(SERIALIZED_NAME_MANDATORY)
  private Boolean mandatory;

  public static final String SERIALIZED_NAME_SOM_CODE = "somCode";
  @SerializedName(SERIALIZED_NAME_SOM_CODE)
  private String somCode;

  public static final String SERIALIZED_NAME_IMAGE_PATH = "imagePath";
  @SerializedName(SERIALIZED_NAME_IMAGE_PATH)
  private String imagePath;

  public static final String SERIALIZED_NAME_IMAGE_BASE64 = "imageBase64";
  @SerializedName(SERIALIZED_NAME_IMAGE_BASE64)
  private String imageBase64;

  public static final String SERIALIZED_NAME_MINIMUM_AMOUNT_EL = "minimumAmountEl";
  @SerializedName(SERIALIZED_NAME_MINIMUM_AMOUNT_EL)
  private String minimumAmountEl;

  public static final String SERIALIZED_NAME_MINIMUM_AMOUNT_EL_SPARK = "minimumAmountElSpark";
  @SerializedName(SERIALIZED_NAME_MINIMUM_AMOUNT_EL_SPARK)
  private String minimumAmountElSpark;

  public static final String SERIALIZED_NAME_MINIMUM_LABEL_EL = "minimumLabelEl";
  @SerializedName(SERIALIZED_NAME_MINIMUM_LABEL_EL)
  private String minimumLabelEl;

  public static final String SERIALIZED_NAME_MINIMUM_LABEL_EL_SPARK = "minimumLabelElSpark";
  @SerializedName(SERIALIZED_NAME_MINIMUM_LABEL_EL_SPARK)
  private String minimumLabelElSpark;

  public static final String SERIALIZED_NAME_AUTO_END_OF_ENGAGEMENT = "autoEndOfEngagement";
  @SerializedName(SERIALIZED_NAME_AUTO_END_OF_ENGAGEMENT)
  private Boolean autoEndOfEngagement;

  public static final String SERIALIZED_NAME_RENEWAL_RULE = "renewalRule";
  @SerializedName(SERIALIZED_NAME_RENEWAL_RULE)
  private SubscriptionRenewalDto renewalRule;

  public static final String SERIALIZED_NAME_CODE_ONLY = "codeOnly";
  @SerializedName(SERIALIZED_NAME_CODE_ONLY)
  private Boolean codeOnly;


  public ServiceTemplateDto 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 ServiceTemplateDto 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 ServiceTemplateDto 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 ServiceTemplateDto 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 ServiceTemplateDto disabled(Boolean disabled) {
    
    this.disabled = disabled;
    return this;
  }

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

  public Boolean getDisabled() {
    return disabled;
  }



  public void setDisabled(Boolean disabled) {
    this.disabled = disabled;
  }


  public ServiceTemplateDto longDescription(String longDescription) {
    
    this.longDescription = longDescription;
    return this;
  }

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

  public String getLongDescription() {
    return longDescription;
  }



  public void setLongDescription(String longDescription) {
    this.longDescription = longDescription;
  }


  public ServiceTemplateDto invoicingCalendar(String invoicingCalendar) {
    
    this.invoicingCalendar = invoicingCalendar;
    return this;
  }

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

  public String getInvoicingCalendar() {
    return invoicingCalendar;
  }



  public void setInvoicingCalendar(String invoicingCalendar) {
    this.invoicingCalendar = invoicingCalendar;
  }


  public ServiceTemplateDto serviceChargeTemplateRecurrings(ServiceChargeTemplateRecurringsDto serviceChargeTemplateRecurrings) {
    
    this.serviceChargeTemplateRecurrings = serviceChargeTemplateRecurrings;
    return this;
  }

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

  public ServiceChargeTemplateRecurringsDto getServiceChargeTemplateRecurrings() {
    return serviceChargeTemplateRecurrings;
  }



  public void setServiceChargeTemplateRecurrings(ServiceChargeTemplateRecurringsDto serviceChargeTemplateRecurrings) {
    this.serviceChargeTemplateRecurrings = serviceChargeTemplateRecurrings;
  }


  public ServiceTemplateDto serviceChargeTemplateSubscriptions(ServiceChargeTemplateSubscriptionsDto serviceChargeTemplateSubscriptions) {
    
    this.serviceChargeTemplateSubscriptions = serviceChargeTemplateSubscriptions;
    return this;
  }

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

  public ServiceChargeTemplateSubscriptionsDto getServiceChargeTemplateSubscriptions() {
    return serviceChargeTemplateSubscriptions;
  }



  public void setServiceChargeTemplateSubscriptions(ServiceChargeTemplateSubscriptionsDto serviceChargeTemplateSubscriptions) {
    this.serviceChargeTemplateSubscriptions = serviceChargeTemplateSubscriptions;
  }


  public ServiceTemplateDto serviceChargeTemplateTerminations(ServiceChargeTemplateTerminationsDto serviceChargeTemplateTerminations) {
    
    this.serviceChargeTemplateTerminations = serviceChargeTemplateTerminations;
    return this;
  }

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

  public ServiceChargeTemplateTerminationsDto getServiceChargeTemplateTerminations() {
    return serviceChargeTemplateTerminations;
  }



  public void setServiceChargeTemplateTerminations(ServiceChargeTemplateTerminationsDto serviceChargeTemplateTerminations) {
    this.serviceChargeTemplateTerminations = serviceChargeTemplateTerminations;
  }


  public ServiceTemplateDto serviceChargeTemplateUsages(ServiceChargeTemplateUsagesDto serviceChargeTemplateUsages) {
    
    this.serviceChargeTemplateUsages = serviceChargeTemplateUsages;
    return this;
  }

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

  public ServiceChargeTemplateUsagesDto getServiceChargeTemplateUsages() {
    return serviceChargeTemplateUsages;
  }



  public void setServiceChargeTemplateUsages(ServiceChargeTemplateUsagesDto serviceChargeTemplateUsages) {
    this.serviceChargeTemplateUsages = serviceChargeTemplateUsages;
  }


  public ServiceTemplateDto 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 ServiceTemplateDto mandatory(Boolean mandatory) {
    
    this.mandatory = mandatory;
    return this;
  }

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

  public Boolean getMandatory() {
    return mandatory;
  }



  public void setMandatory(Boolean mandatory) {
    this.mandatory = mandatory;
  }


  public ServiceTemplateDto somCode(String somCode) {
    
    this.somCode = somCode;
    return this;
  }

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

  public String getSomCode() {
    return somCode;
  }



  public void setSomCode(String somCode) {
    this.somCode = somCode;
  }


  public ServiceTemplateDto imagePath(String imagePath) {
    
    this.imagePath = imagePath;
    return this;
  }

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

  public String getImagePath() {
    return imagePath;
  }



  public void setImagePath(String imagePath) {
    this.imagePath = imagePath;
  }


  public ServiceTemplateDto imageBase64(String imageBase64) {
    
    this.imageBase64 = imageBase64;
    return this;
  }

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

  public String getImageBase64() {
    return imageBase64;
  }



  public void setImageBase64(String imageBase64) {
    this.imageBase64 = imageBase64;
  }


  public ServiceTemplateDto minimumAmountEl(String minimumAmountEl) {
    
    this.minimumAmountEl = minimumAmountEl;
    return this;
  }

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

  public String getMinimumAmountEl() {
    return minimumAmountEl;
  }



  public void setMinimumAmountEl(String minimumAmountEl) {
    this.minimumAmountEl = minimumAmountEl;
  }


  public ServiceTemplateDto minimumAmountElSpark(String minimumAmountElSpark) {
    
    this.minimumAmountElSpark = minimumAmountElSpark;
    return this;
  }

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

  public String getMinimumAmountElSpark() {
    return minimumAmountElSpark;
  }



  public void setMinimumAmountElSpark(String minimumAmountElSpark) {
    this.minimumAmountElSpark = minimumAmountElSpark;
  }


  public ServiceTemplateDto minimumLabelEl(String minimumLabelEl) {
    
    this.minimumLabelEl = minimumLabelEl;
    return this;
  }

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

  public String getMinimumLabelEl() {
    return minimumLabelEl;
  }



  public void setMinimumLabelEl(String minimumLabelEl) {
    this.minimumLabelEl = minimumLabelEl;
  }


  public ServiceTemplateDto minimumLabelElSpark(String minimumLabelElSpark) {
    
    this.minimumLabelElSpark = minimumLabelElSpark;
    return this;
  }

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

  public String getMinimumLabelElSpark() {
    return minimumLabelElSpark;
  }



  public void setMinimumLabelElSpark(String minimumLabelElSpark) {
    this.minimumLabelElSpark = minimumLabelElSpark;
  }


  public ServiceTemplateDto autoEndOfEngagement(Boolean autoEndOfEngagement) {
    
    this.autoEndOfEngagement = autoEndOfEngagement;
    return this;
  }

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

  public Boolean getAutoEndOfEngagement() {
    return autoEndOfEngagement;
  }



  public void setAutoEndOfEngagement(Boolean autoEndOfEngagement) {
    this.autoEndOfEngagement = autoEndOfEngagement;
  }


  public ServiceTemplateDto renewalRule(SubscriptionRenewalDto renewalRule) {
    
    this.renewalRule = renewalRule;
    return this;
  }

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

  public SubscriptionRenewalDto getRenewalRule() {
    return renewalRule;
  }



  public void setRenewalRule(SubscriptionRenewalDto renewalRule) {
    this.renewalRule = renewalRule;
  }


  public ServiceTemplateDto codeOnly(Boolean codeOnly) {
    
    this.codeOnly = codeOnly;
    return this;
  }

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

  public Boolean getCodeOnly() {
    return codeOnly;
  }



  public void setCodeOnly(Boolean codeOnly) {
    this.codeOnly = codeOnly;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ServiceTemplateDto serviceTemplateDto = (ServiceTemplateDto) o;
    return Objects.equals(this.id, serviceTemplateDto.id) &&
        Objects.equals(this.code, serviceTemplateDto.code) &&
        Objects.equals(this.description, serviceTemplateDto.description) &&
        Objects.equals(this.updatedCode, serviceTemplateDto.updatedCode) &&
        Objects.equals(this.disabled, serviceTemplateDto.disabled) &&
        Objects.equals(this.longDescription, serviceTemplateDto.longDescription) &&
        Objects.equals(this.invoicingCalendar, serviceTemplateDto.invoicingCalendar) &&
        Objects.equals(this.serviceChargeTemplateRecurrings, serviceTemplateDto.serviceChargeTemplateRecurrings) &&
        Objects.equals(this.serviceChargeTemplateSubscriptions, serviceTemplateDto.serviceChargeTemplateSubscriptions) &&
        Objects.equals(this.serviceChargeTemplateTerminations, serviceTemplateDto.serviceChargeTemplateTerminations) &&
        Objects.equals(this.serviceChargeTemplateUsages, serviceTemplateDto.serviceChargeTemplateUsages) &&
        Objects.equals(this.customFields, serviceTemplateDto.customFields) &&
        Objects.equals(this.mandatory, serviceTemplateDto.mandatory) &&
        Objects.equals(this.somCode, serviceTemplateDto.somCode) &&
        Objects.equals(this.imagePath, serviceTemplateDto.imagePath) &&
        Objects.equals(this.imageBase64, serviceTemplateDto.imageBase64) &&
        Objects.equals(this.minimumAmountEl, serviceTemplateDto.minimumAmountEl) &&
        Objects.equals(this.minimumAmountElSpark, serviceTemplateDto.minimumAmountElSpark) &&
        Objects.equals(this.minimumLabelEl, serviceTemplateDto.minimumLabelEl) &&
        Objects.equals(this.minimumLabelElSpark, serviceTemplateDto.minimumLabelElSpark) &&
        Objects.equals(this.autoEndOfEngagement, serviceTemplateDto.autoEndOfEngagement) &&
        Objects.equals(this.renewalRule, serviceTemplateDto.renewalRule) &&
        Objects.equals(this.codeOnly, serviceTemplateDto.codeOnly);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, code, description, updatedCode, disabled, longDescription, invoicingCalendar, serviceChargeTemplateRecurrings, serviceChargeTemplateSubscriptions, serviceChargeTemplateTerminations, serviceChargeTemplateUsages, customFields, mandatory, somCode, imagePath, imageBase64, minimumAmountEl, minimumAmountElSpark, minimumLabelEl, minimumLabelElSpark, autoEndOfEngagement, renewalRule, codeOnly);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ServiceTemplateDto {\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("    disabled: ").append(toIndentedString(disabled)).append("\n");
    sb.append("    longDescription: ").append(toIndentedString(longDescription)).append("\n");
    sb.append("    invoicingCalendar: ").append(toIndentedString(invoicingCalendar)).append("\n");
    sb.append("    serviceChargeTemplateRecurrings: ").append(toIndentedString(serviceChargeTemplateRecurrings)).append("\n");
    sb.append("    serviceChargeTemplateSubscriptions: ").append(toIndentedString(serviceChargeTemplateSubscriptions)).append("\n");
    sb.append("    serviceChargeTemplateTerminations: ").append(toIndentedString(serviceChargeTemplateTerminations)).append("\n");
    sb.append("    serviceChargeTemplateUsages: ").append(toIndentedString(serviceChargeTemplateUsages)).append("\n");
    sb.append("    customFields: ").append(toIndentedString(customFields)).append("\n");
    sb.append("    mandatory: ").append(toIndentedString(mandatory)).append("\n");
    sb.append("    somCode: ").append(toIndentedString(somCode)).append("\n");
    sb.append("    imagePath: ").append(toIndentedString(imagePath)).append("\n");
    sb.append("    imageBase64: ").append(toIndentedString(imageBase64)).append("\n");
    sb.append("    minimumAmountEl: ").append(toIndentedString(minimumAmountEl)).append("\n");
    sb.append("    minimumAmountElSpark: ").append(toIndentedString(minimumAmountElSpark)).append("\n");
    sb.append("    minimumLabelEl: ").append(toIndentedString(minimumLabelEl)).append("\n");
    sb.append("    minimumLabelElSpark: ").append(toIndentedString(minimumLabelElSpark)).append("\n");
    sb.append("    autoEndOfEngagement: ").append(toIndentedString(autoEndOfEngagement)).append("\n");
    sb.append("    renewalRule: ").append(toIndentedString(renewalRule)).append("\n");
    sb.append("    codeOnly: ").append(toIndentedString(codeOnly)).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    ");
  }

}

