/*
 * 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.CounterTemplate;
import org.openapitools.client.model.RecurringChargeTemplate;
import org.openapitools.client.model.ServiceTemplate;
import org.openapitools.client.model.WalletTemplate;

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

  public static final String SERIALIZED_NAME_VERSION = "version";
  @SerializedName(SERIALIZED_NAME_VERSION)
  private Integer version;

  public static final String SERIALIZED_NAME_SERVICE_TEMPLATE = "serviceTemplate";
  @SerializedName(SERIALIZED_NAME_SERVICE_TEMPLATE)
  private ServiceTemplate serviceTemplate;

  public static final String SERIALIZED_NAME_CHARGE_TEMPLATE = "chargeTemplate";
  @SerializedName(SERIALIZED_NAME_CHARGE_TEMPLATE)
  private RecurringChargeTemplate chargeTemplate;

  public static final String SERIALIZED_NAME_COUNTER_TEMPLATE = "counterTemplate";
  @SerializedName(SERIALIZED_NAME_COUNTER_TEMPLATE)
  private CounterTemplate counterTemplate;

  public static final String SERIALIZED_NAME_WALLET_TEMPLATES = "walletTemplates";
  @SerializedName(SERIALIZED_NAME_WALLET_TEMPLATES)
  private List<WalletTemplate> walletTemplates = null;

  public static final String SERIALIZED_NAME_TRANSIENT = "transient";
  @SerializedName(SERIALIZED_NAME_TRANSIENT)
  private Boolean _transient;


  public ServiceChargeTemplateRecurring 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 ServiceChargeTemplateRecurring version(Integer version) {
    
    this.version = version;
    return this;
  }

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

  public Integer getVersion() {
    return version;
  }



  public void setVersion(Integer version) {
    this.version = version;
  }


  public ServiceChargeTemplateRecurring serviceTemplate(ServiceTemplate serviceTemplate) {
    
    this.serviceTemplate = serviceTemplate;
    return this;
  }

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

  public ServiceTemplate getServiceTemplate() {
    return serviceTemplate;
  }



  public void setServiceTemplate(ServiceTemplate serviceTemplate) {
    this.serviceTemplate = serviceTemplate;
  }


  public ServiceChargeTemplateRecurring chargeTemplate(RecurringChargeTemplate chargeTemplate) {
    
    this.chargeTemplate = chargeTemplate;
    return this;
  }

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

  public RecurringChargeTemplate getChargeTemplate() {
    return chargeTemplate;
  }



  public void setChargeTemplate(RecurringChargeTemplate chargeTemplate) {
    this.chargeTemplate = chargeTemplate;
  }


  public ServiceChargeTemplateRecurring counterTemplate(CounterTemplate counterTemplate) {
    
    this.counterTemplate = counterTemplate;
    return this;
  }

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

  public CounterTemplate getCounterTemplate() {
    return counterTemplate;
  }



  public void setCounterTemplate(CounterTemplate counterTemplate) {
    this.counterTemplate = counterTemplate;
  }


  public ServiceChargeTemplateRecurring walletTemplates(List<WalletTemplate> walletTemplates) {
    
    this.walletTemplates = walletTemplates;
    return this;
  }

  public ServiceChargeTemplateRecurring addWalletTemplatesItem(WalletTemplate walletTemplatesItem) {
    if (this.walletTemplates == null) {
      this.walletTemplates = new ArrayList<WalletTemplate>();
    }
    this.walletTemplates.add(walletTemplatesItem);
    return this;
  }

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

  public List<WalletTemplate> getWalletTemplates() {
    return walletTemplates;
  }



  public void setWalletTemplates(List<WalletTemplate> walletTemplates) {
    this.walletTemplates = walletTemplates;
  }


  public ServiceChargeTemplateRecurring _transient(Boolean _transient) {
    
    this._transient = _transient;
    return this;
  }

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

  public Boolean getTransient() {
    return _transient;
  }



  public void setTransient(Boolean _transient) {
    this._transient = _transient;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ServiceChargeTemplateRecurring serviceChargeTemplateRecurring = (ServiceChargeTemplateRecurring) o;
    return Objects.equals(this.id, serviceChargeTemplateRecurring.id) &&
        Objects.equals(this.version, serviceChargeTemplateRecurring.version) &&
        Objects.equals(this.serviceTemplate, serviceChargeTemplateRecurring.serviceTemplate) &&
        Objects.equals(this.chargeTemplate, serviceChargeTemplateRecurring.chargeTemplate) &&
        Objects.equals(this.counterTemplate, serviceChargeTemplateRecurring.counterTemplate) &&
        Objects.equals(this.walletTemplates, serviceChargeTemplateRecurring.walletTemplates) &&
        Objects.equals(this._transient, serviceChargeTemplateRecurring._transient);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, version, serviceTemplate, chargeTemplate, counterTemplate, walletTemplates, _transient);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ServiceChargeTemplateRecurring {\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    version: ").append(toIndentedString(version)).append("\n");
    sb.append("    serviceTemplate: ").append(toIndentedString(serviceTemplate)).append("\n");
    sb.append("    chargeTemplate: ").append(toIndentedString(chargeTemplate)).append("\n");
    sb.append("    counterTemplate: ").append(toIndentedString(counterTemplate)).append("\n");
    sb.append("    walletTemplates: ").append(toIndentedString(walletTemplates)).append("\n");
    sb.append("    _transient: ").append(toIndentedString(_transient)).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    ");
  }

}

