/*
 * 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.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import org.openapitools.client.model.RatedTransactionDto;

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

  public static final String SERIALIZED_NAME_ACCOUNTING_CODE = "accountingCode";
  @SerializedName(SERIALIZED_NAME_ACCOUNTING_CODE)
  private String accountingCode;

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

  public static final String SERIALIZED_NAME_TAX_CODE = "taxCode";
  @SerializedName(SERIALIZED_NAME_TAX_CODE)
  private String taxCode;

  public static final String SERIALIZED_NAME_TAX_PERCENT = "taxPercent";
  @SerializedName(SERIALIZED_NAME_TAX_PERCENT)
  private BigDecimal taxPercent;

  public static final String SERIALIZED_NAME_QUANTITY = "quantity";
  @SerializedName(SERIALIZED_NAME_QUANTITY)
  private BigDecimal quantity;

  public static final String SERIALIZED_NAME_AMOUNT_WITHOUT_TAX = "amountWithoutTax";
  @SerializedName(SERIALIZED_NAME_AMOUNT_WITHOUT_TAX)
  private BigDecimal amountWithoutTax;

  public static final String SERIALIZED_NAME_AMOUNT_TAX = "amountTax";
  @SerializedName(SERIALIZED_NAME_AMOUNT_TAX)
  private BigDecimal amountTax;

  public static final String SERIALIZED_NAME_AMOUNT_WITH_TAX = "amountWithTax";
  @SerializedName(SERIALIZED_NAME_AMOUNT_WITH_TAX)
  private BigDecimal amountWithTax;

  public static final String SERIALIZED_NAME_INVOICE_SUB_CATEGORY_CODE = "invoiceSubCategoryCode";
  @SerializedName(SERIALIZED_NAME_INVOICE_SUB_CATEGORY_CODE)
  private String invoiceSubCategoryCode;

  public static final String SERIALIZED_NAME_USER_ACCOUNT_CODE = "userAccountCode";
  @SerializedName(SERIALIZED_NAME_USER_ACCOUNT_CODE)
  private String userAccountCode;

  public static final String SERIALIZED_NAME_RATED_TRANSACTIONS = "ratedTransactions";
  @SerializedName(SERIALIZED_NAME_RATED_TRANSACTIONS)
  private List<RatedTransactionDto> ratedTransactions = null;


  public SubCategoryInvoiceAgregateDto itemNumber(Integer itemNumber) {
    
    this.itemNumber = itemNumber;
    return this;
  }

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

  public Integer getItemNumber() {
    return itemNumber;
  }



  public void setItemNumber(Integer itemNumber) {
    this.itemNumber = itemNumber;
  }


  public SubCategoryInvoiceAgregateDto accountingCode(String accountingCode) {
    
    this.accountingCode = accountingCode;
    return this;
  }

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

  public String getAccountingCode() {
    return accountingCode;
  }



  public void setAccountingCode(String accountingCode) {
    this.accountingCode = accountingCode;
  }


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

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

  public String getTaxCode() {
    return taxCode;
  }



  public void setTaxCode(String taxCode) {
    this.taxCode = taxCode;
  }


  public SubCategoryInvoiceAgregateDto taxPercent(BigDecimal taxPercent) {
    
    this.taxPercent = taxPercent;
    return this;
  }

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

  public BigDecimal getTaxPercent() {
    return taxPercent;
  }



  public void setTaxPercent(BigDecimal taxPercent) {
    this.taxPercent = taxPercent;
  }


  public SubCategoryInvoiceAgregateDto quantity(BigDecimal quantity) {
    
    this.quantity = quantity;
    return this;
  }

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

  public BigDecimal getQuantity() {
    return quantity;
  }



  public void setQuantity(BigDecimal quantity) {
    this.quantity = quantity;
  }


  public SubCategoryInvoiceAgregateDto amountWithoutTax(BigDecimal amountWithoutTax) {
    
    this.amountWithoutTax = amountWithoutTax;
    return this;
  }

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

  public BigDecimal getAmountWithoutTax() {
    return amountWithoutTax;
  }



  public void setAmountWithoutTax(BigDecimal amountWithoutTax) {
    this.amountWithoutTax = amountWithoutTax;
  }


  public SubCategoryInvoiceAgregateDto amountTax(BigDecimal amountTax) {
    
    this.amountTax = amountTax;
    return this;
  }

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

  public BigDecimal getAmountTax() {
    return amountTax;
  }



  public void setAmountTax(BigDecimal amountTax) {
    this.amountTax = amountTax;
  }


  public SubCategoryInvoiceAgregateDto amountWithTax(BigDecimal amountWithTax) {
    
    this.amountWithTax = amountWithTax;
    return this;
  }

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

  public BigDecimal getAmountWithTax() {
    return amountWithTax;
  }



  public void setAmountWithTax(BigDecimal amountWithTax) {
    this.amountWithTax = amountWithTax;
  }


  public SubCategoryInvoiceAgregateDto invoiceSubCategoryCode(String invoiceSubCategoryCode) {
    
    this.invoiceSubCategoryCode = invoiceSubCategoryCode;
    return this;
  }

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

  public String getInvoiceSubCategoryCode() {
    return invoiceSubCategoryCode;
  }



  public void setInvoiceSubCategoryCode(String invoiceSubCategoryCode) {
    this.invoiceSubCategoryCode = invoiceSubCategoryCode;
  }


  public SubCategoryInvoiceAgregateDto userAccountCode(String userAccountCode) {
    
    this.userAccountCode = userAccountCode;
    return this;
  }

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

  public String getUserAccountCode() {
    return userAccountCode;
  }



  public void setUserAccountCode(String userAccountCode) {
    this.userAccountCode = userAccountCode;
  }


  public SubCategoryInvoiceAgregateDto ratedTransactions(List<RatedTransactionDto> ratedTransactions) {
    
    this.ratedTransactions = ratedTransactions;
    return this;
  }

  public SubCategoryInvoiceAgregateDto addRatedTransactionsItem(RatedTransactionDto ratedTransactionsItem) {
    if (this.ratedTransactions == null) {
      this.ratedTransactions = new ArrayList<RatedTransactionDto>();
    }
    this.ratedTransactions.add(ratedTransactionsItem);
    return this;
  }

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

  public List<RatedTransactionDto> getRatedTransactions() {
    return ratedTransactions;
  }



  public void setRatedTransactions(List<RatedTransactionDto> ratedTransactions) {
    this.ratedTransactions = ratedTransactions;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    SubCategoryInvoiceAgregateDto subCategoryInvoiceAgregateDto = (SubCategoryInvoiceAgregateDto) o;
    return Objects.equals(this.itemNumber, subCategoryInvoiceAgregateDto.itemNumber) &&
        Objects.equals(this.accountingCode, subCategoryInvoiceAgregateDto.accountingCode) &&
        Objects.equals(this.description, subCategoryInvoiceAgregateDto.description) &&
        Objects.equals(this.taxCode, subCategoryInvoiceAgregateDto.taxCode) &&
        Objects.equals(this.taxPercent, subCategoryInvoiceAgregateDto.taxPercent) &&
        Objects.equals(this.quantity, subCategoryInvoiceAgregateDto.quantity) &&
        Objects.equals(this.amountWithoutTax, subCategoryInvoiceAgregateDto.amountWithoutTax) &&
        Objects.equals(this.amountTax, subCategoryInvoiceAgregateDto.amountTax) &&
        Objects.equals(this.amountWithTax, subCategoryInvoiceAgregateDto.amountWithTax) &&
        Objects.equals(this.invoiceSubCategoryCode, subCategoryInvoiceAgregateDto.invoiceSubCategoryCode) &&
        Objects.equals(this.userAccountCode, subCategoryInvoiceAgregateDto.userAccountCode) &&
        Objects.equals(this.ratedTransactions, subCategoryInvoiceAgregateDto.ratedTransactions);
  }

  @Override
  public int hashCode() {
    return Objects.hash(itemNumber, accountingCode, description, taxCode, taxPercent, quantity, amountWithoutTax, amountTax, amountWithTax, invoiceSubCategoryCode, userAccountCode, ratedTransactions);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class SubCategoryInvoiceAgregateDto {\n");
    sb.append("    itemNumber: ").append(toIndentedString(itemNumber)).append("\n");
    sb.append("    accountingCode: ").append(toIndentedString(accountingCode)).append("\n");
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
    sb.append("    taxCode: ").append(toIndentedString(taxCode)).append("\n");
    sb.append("    taxPercent: ").append(toIndentedString(taxPercent)).append("\n");
    sb.append("    quantity: ").append(toIndentedString(quantity)).append("\n");
    sb.append("    amountWithoutTax: ").append(toIndentedString(amountWithoutTax)).append("\n");
    sb.append("    amountTax: ").append(toIndentedString(amountTax)).append("\n");
    sb.append("    amountWithTax: ").append(toIndentedString(amountWithTax)).append("\n");
    sb.append("    invoiceSubCategoryCode: ").append(toIndentedString(invoiceSubCategoryCode)).append("\n");
    sb.append("    userAccountCode: ").append(toIndentedString(userAccountCode)).append("\n");
    sb.append("    ratedTransactions: ").append(toIndentedString(ratedTransactions)).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    ");
  }

}

