/*
 * The Plaid API
 * The Plaid REST API. Please see https://plaid.com/docs/api for more details.
 *
 * The version of the OpenAPI document: 2020-09-14_1.680.0
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package com.plaid.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 com.plaid.client.model.AmountWithCurrency;
import com.plaid.client.model.AmountWithCurrencyWithMonthlyAverage;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;

/**
 * Comprehensive income analysis including total income, income excluding transfers, and inbound transfer amounts.
 */
@ApiModel(description = "Comprehensive income analysis including total income, income excluding transfers, and inbound transfer amounts.")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2025-12-11T18:58:39.328614Z[Etc/UTC]")
public class IncomeInsights {
  public static final String SERIALIZED_NAME_TOTAL_INCOME = "total_income";
  @SerializedName(SERIALIZED_NAME_TOTAL_INCOME)
  private AmountWithCurrency totalIncome;

  public static final String SERIALIZED_NAME_INCOME_EXCLUDING_TRANSFERS = "income_excluding_transfers";
  @SerializedName(SERIALIZED_NAME_INCOME_EXCLUDING_TRANSFERS)
  private AmountWithCurrencyWithMonthlyAverage incomeExcludingTransfers;

  public static final String SERIALIZED_NAME_TRANSFERS_IN = "transfers_in";
  @SerializedName(SERIALIZED_NAME_TRANSFERS_IN)
  private AmountWithCurrencyWithMonthlyAverage transfersIn;


  public IncomeInsights totalIncome(AmountWithCurrency totalIncome) {
    
    this.totalIncome = totalIncome;
    return this;
  }

   /**
   * The total amount of all income transactions in the given time period.
   * @return totalIncome
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "The total amount of all income transactions in the given time period.")

  public AmountWithCurrency getTotalIncome() {
    return totalIncome;
  }


  public void setTotalIncome(AmountWithCurrency totalIncome) {
    this.totalIncome = totalIncome;
  }


  public IncomeInsights incomeExcludingTransfers(AmountWithCurrencyWithMonthlyAverage incomeExcludingTransfers) {
    
    this.incomeExcludingTransfers = incomeExcludingTransfers;
    return this;
  }

   /**
   * Income excluding account transfer transactions for the period, including a monthly average.
   * @return incomeExcludingTransfers
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "Income excluding account transfer transactions for the period, including a monthly average.")

  public AmountWithCurrencyWithMonthlyAverage getIncomeExcludingTransfers() {
    return incomeExcludingTransfers;
  }


  public void setIncomeExcludingTransfers(AmountWithCurrencyWithMonthlyAverage incomeExcludingTransfers) {
    this.incomeExcludingTransfers = incomeExcludingTransfers;
  }


  public IncomeInsights transfersIn(AmountWithCurrencyWithMonthlyAverage transfersIn) {
    
    this.transfersIn = transfersIn;
    return this;
  }

   /**
   * Sum of inbound transfer transactions for the period, including a monthly average.
   * @return transfersIn
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "Sum of inbound transfer transactions for the period, including a monthly average.")

  public AmountWithCurrencyWithMonthlyAverage getTransfersIn() {
    return transfersIn;
  }


  public void setTransfersIn(AmountWithCurrencyWithMonthlyAverage transfersIn) {
    this.transfersIn = transfersIn;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    IncomeInsights incomeInsights = (IncomeInsights) o;
    return Objects.equals(this.totalIncome, incomeInsights.totalIncome) &&
        Objects.equals(this.incomeExcludingTransfers, incomeInsights.incomeExcludingTransfers) &&
        Objects.equals(this.transfersIn, incomeInsights.transfersIn);
  }

  @Override
  public int hashCode() {
    return Objects.hash(totalIncome, incomeExcludingTransfers, transfersIn);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class IncomeInsights {\n");
    sb.append("    totalIncome: ").append(toIndentedString(totalIncome)).append("\n");
    sb.append("    incomeExcludingTransfers: ").append(toIndentedString(incomeExcludingTransfers)).append("\n");
    sb.append("    transfersIn: ").append(toIndentedString(transfersIn)).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(Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}

