All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openapitools.client.model.RefundTransactions Maven / Gradle / Ivy

There is a newer version: 3.2.1
Show newest version
/*
* Quickstart API Reference
* Zuora Quickstart API is the API that helps you achieve fundamental use cases.
* It provides a much simplified object model and improved performance, enabling developers to easily learn and use.
*/

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.Refund;
import org.openapitools.jackson.nullable.JsonNullable;

import org.openapitools.client.JSON.CustomFieldAdapter;
import org.openapitools.client.JSON.NullableFieldAdapter;
/**
 * RefundTransactions
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class RefundTransactions {
  public static final String SERIALIZED_NAME_REFUND_NUMBER = "refund_number";
  @SerializedName(SERIALIZED_NAME_REFUND_NUMBER)
  private String refundNumber;

  public static final String SERIALIZED_NAME_INVOICE_NUMBERS = "invoice_numbers";
  @SerializedName(SERIALIZED_NAME_INVOICE_NUMBERS)
  private List invoiceNumbers = null;

  public static final String SERIALIZED_NAME_STATE = "state";
  @SerializedName(SERIALIZED_NAME_STATE)
  private Object state;

  public static final String SERIALIZED_NAME_REFUNDS = "refunds";
  @SerializedName(SERIALIZED_NAME_REFUNDS)
  private Refund refunds;

  public RefundTransactions() { 
  }

  public RefundTransactions refundNumber(String refundNumber) {
    
    this.refundNumber = refundNumber;
    return this;
  }

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

  public String getRefundNumber() {
    return refundNumber;
  }


  public void setRefundNumber(String refundNumber) {
    this.refundNumber = refundNumber;
  }


  public RefundTransactions invoiceNumbers(List invoiceNumbers) {
    
    this.invoiceNumbers = invoiceNumbers;
    return this;
  }

  public RefundTransactions addInvoiceNumbersItem(String invoiceNumbersItem) {
    if (this.invoiceNumbers == null) {
      this.invoiceNumbers = new ArrayList();
    }
    this.invoiceNumbers.add(invoiceNumbersItem);
    return this;
  }

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

  public List getInvoiceNumbers() {
    return invoiceNumbers;
  }


  public void setInvoiceNumbers(List invoiceNumbers) {
    this.invoiceNumbers = invoiceNumbers;
  }


  public RefundTransactions state(Object state) {
    
    this.state = state;
    return this;
  }

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

  public Object getState() {
    return state;
  }


  public void setState(Object state) {
    this.state = state;
  }


  public RefundTransactions refunds(Refund refunds) {
    
    this.refunds = refunds;
    return this;
  }

   /**
   * The related invoices.
   * @return refunds
  **/
  @javax.annotation.Nullable
  @ApiModelProperty(value = "The related invoices.")

  public Refund getRefunds() {
    return refunds;
  }


  public void setRefunds(Refund refunds) {
    this.refunds = refunds;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    RefundTransactions refundTransactions = (RefundTransactions) o;
    return Objects.equals(this.refundNumber, refundTransactions.refundNumber) &&
        Objects.equals(this.invoiceNumbers, refundTransactions.invoiceNumbers) &&
        Objects.equals(this.state, refundTransactions.state) &&
        Objects.equals(this.refunds, refundTransactions.refunds);
  }

  private static  boolean equalsNullable(JsonNullable a, JsonNullable b) {
    return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get()));
  }

  @Override
  public int hashCode() {
    return Objects.hash(refundNumber, invoiceNumbers, state, refunds);
  }

  private static  int hashCodeNullable(JsonNullable a) {
    if (a == null) {
      return 1;
    }
    return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31;
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class RefundTransactions {\n");
    sb.append("    refundNumber: ").append(toIndentedString(refundNumber)).append("\n");
    sb.append("    invoiceNumbers: ").append(toIndentedString(invoiceNumbers)).append("\n");
    sb.append("    state: ").append(toIndentedString(state)).append("\n");
    sb.append("    refunds: ").append(toIndentedString(refunds)).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    ");
  }

}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy