/*
 * Lethean Blockchain API
 * OpenAPI for Lethean Blockchain
 *
 * The version of the OpenAPI document: 6.0.1
 * 
 *
 * 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.Locale;
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 java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.JsonArray;
import com.google.gson.JsonDeserializationContext;
import com.google.gson.JsonDeserializer;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
import com.google.gson.JsonParseException;
import com.google.gson.TypeAdapterFactory;
import com.google.gson.reflect.TypeToken;
import com.google.gson.TypeAdapter;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import java.io.IOException;

import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.Locale;

import invalidPackageName.JSON;

/**
 * TxGenerationContextModel
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2025-10-19T15:35:02.750468+01:00[Europe/London]", comments = "Generator version: 7.16.0")
public class TxGenerationContextModel {
  public static final String SERIALIZED_NAME_ASSET_IDS = "asset_ids";
  @SerializedName(SERIALIZED_NAME_ASSET_IDS)
  @javax.annotation.Nullable
  private List<String> assetIds = new ArrayList<>();

  public static final String SERIALIZED_NAME_BLINDED_ASSET_IDS = "blinded_asset_ids";
  @SerializedName(SERIALIZED_NAME_BLINDED_ASSET_IDS)
  @javax.annotation.Nullable
  private List<String> blindedAssetIds = new ArrayList<>();

  public static final String SERIALIZED_NAME_AMOUNT_COMMITMENTS = "amount_commitments";
  @SerializedName(SERIALIZED_NAME_AMOUNT_COMMITMENTS)
  @javax.annotation.Nullable
  private List<String> amountCommitments = new ArrayList<>();

  public static final String SERIALIZED_NAME_ASSET_ID_BLINDING_MASKS = "asset_id_blinding_masks";
  @SerializedName(SERIALIZED_NAME_ASSET_ID_BLINDING_MASKS)
  @javax.annotation.Nullable
  private List<String> assetIdBlindingMasks = new ArrayList<>();

  public static final String SERIALIZED_NAME_AMOUNTS = "amounts";
  @SerializedName(SERIALIZED_NAME_AMOUNTS)
  @javax.annotation.Nullable
  private List<String> amounts = new ArrayList<>();

  public static final String SERIALIZED_NAME_AMOUNT_BLINDING_MASKS = "amount_blinding_masks";
  @SerializedName(SERIALIZED_NAME_AMOUNT_BLINDING_MASKS)
  @javax.annotation.Nullable
  private List<String> amountBlindingMasks = new ArrayList<>();

  public static final String SERIALIZED_NAME_PSEUDO_OUTS_BLINDED_ASSET_IDS = "pseudo_outs_blinded_asset_ids";
  @SerializedName(SERIALIZED_NAME_PSEUDO_OUTS_BLINDED_ASSET_IDS)
  @javax.annotation.Nullable
  private List<String> pseudoOutsBlindedAssetIds = new ArrayList<>();

  public static final String SERIALIZED_NAME_PSEUDO_OUTS_PLUS_REAL_OUT_BLINDING_MASKS = "pseudo_outs_plus_real_out_blinding_masks";
  @SerializedName(SERIALIZED_NAME_PSEUDO_OUTS_PLUS_REAL_OUT_BLINDING_MASKS)
  @javax.annotation.Nullable
  private List<String> pseudoOutsPlusRealOutBlindingMasks = new ArrayList<>();

  public static final String SERIALIZED_NAME_REAL_ZC_INS_ASSET_IDS = "real_zc_ins_asset_ids";
  @SerializedName(SERIALIZED_NAME_REAL_ZC_INS_ASSET_IDS)
  @javax.annotation.Nullable
  private List<String> realZcInsAssetIds = new ArrayList<>();

  public static final String SERIALIZED_NAME_ZC_INPUT_AMOUNTS = "zc_input_amounts";
  @SerializedName(SERIALIZED_NAME_ZC_INPUT_AMOUNTS)
  @javax.annotation.Nullable
  private List<Integer> zcInputAmounts = new ArrayList<>();

  public static final String SERIALIZED_NAME_PSEUDO_OUT_AMOUNT_COMMITMENTS_SUM = "pseudo_out_amount_commitments_sum";
  @SerializedName(SERIALIZED_NAME_PSEUDO_OUT_AMOUNT_COMMITMENTS_SUM)
  @javax.annotation.Nullable
  private String pseudoOutAmountCommitmentsSum;

  public static final String SERIALIZED_NAME_PSEUDO_OUT_AMOUNT_BLINDING_MASKS_SUM = "pseudo_out_amount_blinding_masks_sum";
  @SerializedName(SERIALIZED_NAME_PSEUDO_OUT_AMOUNT_BLINDING_MASKS_SUM)
  @javax.annotation.Nullable
  private String pseudoOutAmountBlindingMasksSum;

  public static final String SERIALIZED_NAME_REAL_IN_ASSET_ID_BLINDING_MASK_X_AMOUNT_SUM = "real_in_asset_id_blinding_mask_x_amount_sum";
  @SerializedName(SERIALIZED_NAME_REAL_IN_ASSET_ID_BLINDING_MASK_X_AMOUNT_SUM)
  @javax.annotation.Nullable
  private String realInAssetIdBlindingMaskXAmountSum;

  public static final String SERIALIZED_NAME_AMOUNT_COMMITMENTS_SUM = "amount_commitments_sum";
  @SerializedName(SERIALIZED_NAME_AMOUNT_COMMITMENTS_SUM)
  @javax.annotation.Nullable
  private String amountCommitmentsSum;

  public static final String SERIALIZED_NAME_AMOUNT_BLINDING_MASKS_SUM = "amount_blinding_masks_sum";
  @SerializedName(SERIALIZED_NAME_AMOUNT_BLINDING_MASKS_SUM)
  @javax.annotation.Nullable
  private String amountBlindingMasksSum;

  public static final String SERIALIZED_NAME_ASSET_ID_BLINDING_MASK_X_AMOUNT_SUM = "asset_id_blinding_mask_x_amount_sum";
  @SerializedName(SERIALIZED_NAME_ASSET_ID_BLINDING_MASK_X_AMOUNT_SUM)
  @javax.annotation.Nullable
  private String assetIdBlindingMaskXAmountSum;

  public static final String SERIALIZED_NAME_AO_ASSET_ID = "ao_asset_id";
  @SerializedName(SERIALIZED_NAME_AO_ASSET_ID)
  @javax.annotation.Nullable
  private String aoAssetId;

  public static final String SERIALIZED_NAME_AO_ASSET_ID_PT = "ao_asset_id_pt";
  @SerializedName(SERIALIZED_NAME_AO_ASSET_ID_PT)
  @javax.annotation.Nullable
  private String aoAssetIdPt;

  public static final String SERIALIZED_NAME_AO_AMOUNT_COMMITMENT = "ao_amount_commitment";
  @SerializedName(SERIALIZED_NAME_AO_AMOUNT_COMMITMENT)
  @javax.annotation.Nullable
  private String aoAmountCommitment;

  public static final String SERIALIZED_NAME_AO_AMOUNT_BLINDING_MASK = "ao_amount_blinding_mask";
  @SerializedName(SERIALIZED_NAME_AO_AMOUNT_BLINDING_MASK)
  @javax.annotation.Nullable
  private String aoAmountBlindingMask;

  public static final String SERIALIZED_NAME_AO_COMMITMENT_IN_OUTPUTS = "ao_commitment_in_outputs";
  @SerializedName(SERIALIZED_NAME_AO_COMMITMENT_IN_OUTPUTS)
  @javax.annotation.Nullable
  private Boolean aoCommitmentInOutputs;

  public static final String SERIALIZED_NAME_TX_KEY_PUB = "tx_key_pub";
  @SerializedName(SERIALIZED_NAME_TX_KEY_PUB)
  @javax.annotation.Nullable
  private String txKeyPub;

  public static final String SERIALIZED_NAME_TX_KEY_SEC = "tx_key_sec";
  @SerializedName(SERIALIZED_NAME_TX_KEY_SEC)
  @javax.annotation.Nullable
  private String txKeySec;

  public static final String SERIALIZED_NAME_TX_PUB_KEY_P = "tx_pub_key_p";
  @SerializedName(SERIALIZED_NAME_TX_PUB_KEY_P)
  @javax.annotation.Nullable
  private String txPubKeyP;

  public TxGenerationContextModel() {
  }

  public TxGenerationContextModel assetIds(@javax.annotation.Nullable List<String> assetIds) {
    this.assetIds = assetIds;
    return this;
  }

  public TxGenerationContextModel addAssetIdsItem(String assetIdsItem) {
    if (this.assetIds == null) {
      this.assetIds = new ArrayList<>();
    }
    this.assetIds.add(assetIdsItem);
    return this;
  }

  /**
   * Get assetIds
   * @return assetIds
   */
  @javax.annotation.Nullable
  public List<String> getAssetIds() {
    return assetIds;
  }

  public void setAssetIds(@javax.annotation.Nullable List<String> assetIds) {
    this.assetIds = assetIds;
  }


  public TxGenerationContextModel blindedAssetIds(@javax.annotation.Nullable List<String> blindedAssetIds) {
    this.blindedAssetIds = blindedAssetIds;
    return this;
  }

  public TxGenerationContextModel addBlindedAssetIdsItem(String blindedAssetIdsItem) {
    if (this.blindedAssetIds == null) {
      this.blindedAssetIds = new ArrayList<>();
    }
    this.blindedAssetIds.add(blindedAssetIdsItem);
    return this;
  }

  /**
   * Get blindedAssetIds
   * @return blindedAssetIds
   */
  @javax.annotation.Nullable
  public List<String> getBlindedAssetIds() {
    return blindedAssetIds;
  }

  public void setBlindedAssetIds(@javax.annotation.Nullable List<String> blindedAssetIds) {
    this.blindedAssetIds = blindedAssetIds;
  }


  public TxGenerationContextModel amountCommitments(@javax.annotation.Nullable List<String> amountCommitments) {
    this.amountCommitments = amountCommitments;
    return this;
  }

  public TxGenerationContextModel addAmountCommitmentsItem(String amountCommitmentsItem) {
    if (this.amountCommitments == null) {
      this.amountCommitments = new ArrayList<>();
    }
    this.amountCommitments.add(amountCommitmentsItem);
    return this;
  }

  /**
   * Get amountCommitments
   * @return amountCommitments
   */
  @javax.annotation.Nullable
  public List<String> getAmountCommitments() {
    return amountCommitments;
  }

  public void setAmountCommitments(@javax.annotation.Nullable List<String> amountCommitments) {
    this.amountCommitments = amountCommitments;
  }


  public TxGenerationContextModel assetIdBlindingMasks(@javax.annotation.Nullable List<String> assetIdBlindingMasks) {
    this.assetIdBlindingMasks = assetIdBlindingMasks;
    return this;
  }

  public TxGenerationContextModel addAssetIdBlindingMasksItem(String assetIdBlindingMasksItem) {
    if (this.assetIdBlindingMasks == null) {
      this.assetIdBlindingMasks = new ArrayList<>();
    }
    this.assetIdBlindingMasks.add(assetIdBlindingMasksItem);
    return this;
  }

  /**
   * Get assetIdBlindingMasks
   * @return assetIdBlindingMasks
   */
  @javax.annotation.Nullable
  public List<String> getAssetIdBlindingMasks() {
    return assetIdBlindingMasks;
  }

  public void setAssetIdBlindingMasks(@javax.annotation.Nullable List<String> assetIdBlindingMasks) {
    this.assetIdBlindingMasks = assetIdBlindingMasks;
  }


  public TxGenerationContextModel amounts(@javax.annotation.Nullable List<String> amounts) {
    this.amounts = amounts;
    return this;
  }

  public TxGenerationContextModel addAmountsItem(String amountsItem) {
    if (this.amounts == null) {
      this.amounts = new ArrayList<>();
    }
    this.amounts.add(amountsItem);
    return this;
  }

  /**
   * Get amounts
   * @return amounts
   */
  @javax.annotation.Nullable
  public List<String> getAmounts() {
    return amounts;
  }

  public void setAmounts(@javax.annotation.Nullable List<String> amounts) {
    this.amounts = amounts;
  }


  public TxGenerationContextModel amountBlindingMasks(@javax.annotation.Nullable List<String> amountBlindingMasks) {
    this.amountBlindingMasks = amountBlindingMasks;
    return this;
  }

  public TxGenerationContextModel addAmountBlindingMasksItem(String amountBlindingMasksItem) {
    if (this.amountBlindingMasks == null) {
      this.amountBlindingMasks = new ArrayList<>();
    }
    this.amountBlindingMasks.add(amountBlindingMasksItem);
    return this;
  }

  /**
   * Get amountBlindingMasks
   * @return amountBlindingMasks
   */
  @javax.annotation.Nullable
  public List<String> getAmountBlindingMasks() {
    return amountBlindingMasks;
  }

  public void setAmountBlindingMasks(@javax.annotation.Nullable List<String> amountBlindingMasks) {
    this.amountBlindingMasks = amountBlindingMasks;
  }


  public TxGenerationContextModel pseudoOutsBlindedAssetIds(@javax.annotation.Nullable List<String> pseudoOutsBlindedAssetIds) {
    this.pseudoOutsBlindedAssetIds = pseudoOutsBlindedAssetIds;
    return this;
  }

  public TxGenerationContextModel addPseudoOutsBlindedAssetIdsItem(String pseudoOutsBlindedAssetIdsItem) {
    if (this.pseudoOutsBlindedAssetIds == null) {
      this.pseudoOutsBlindedAssetIds = new ArrayList<>();
    }
    this.pseudoOutsBlindedAssetIds.add(pseudoOutsBlindedAssetIdsItem);
    return this;
  }

  /**
   * Get pseudoOutsBlindedAssetIds
   * @return pseudoOutsBlindedAssetIds
   */
  @javax.annotation.Nullable
  public List<String> getPseudoOutsBlindedAssetIds() {
    return pseudoOutsBlindedAssetIds;
  }

  public void setPseudoOutsBlindedAssetIds(@javax.annotation.Nullable List<String> pseudoOutsBlindedAssetIds) {
    this.pseudoOutsBlindedAssetIds = pseudoOutsBlindedAssetIds;
  }


  public TxGenerationContextModel pseudoOutsPlusRealOutBlindingMasks(@javax.annotation.Nullable List<String> pseudoOutsPlusRealOutBlindingMasks) {
    this.pseudoOutsPlusRealOutBlindingMasks = pseudoOutsPlusRealOutBlindingMasks;
    return this;
  }

  public TxGenerationContextModel addPseudoOutsPlusRealOutBlindingMasksItem(String pseudoOutsPlusRealOutBlindingMasksItem) {
    if (this.pseudoOutsPlusRealOutBlindingMasks == null) {
      this.pseudoOutsPlusRealOutBlindingMasks = new ArrayList<>();
    }
    this.pseudoOutsPlusRealOutBlindingMasks.add(pseudoOutsPlusRealOutBlindingMasksItem);
    return this;
  }

  /**
   * Get pseudoOutsPlusRealOutBlindingMasks
   * @return pseudoOutsPlusRealOutBlindingMasks
   */
  @javax.annotation.Nullable
  public List<String> getPseudoOutsPlusRealOutBlindingMasks() {
    return pseudoOutsPlusRealOutBlindingMasks;
  }

  public void setPseudoOutsPlusRealOutBlindingMasks(@javax.annotation.Nullable List<String> pseudoOutsPlusRealOutBlindingMasks) {
    this.pseudoOutsPlusRealOutBlindingMasks = pseudoOutsPlusRealOutBlindingMasks;
  }


  public TxGenerationContextModel realZcInsAssetIds(@javax.annotation.Nullable List<String> realZcInsAssetIds) {
    this.realZcInsAssetIds = realZcInsAssetIds;
    return this;
  }

  public TxGenerationContextModel addRealZcInsAssetIdsItem(String realZcInsAssetIdsItem) {
    if (this.realZcInsAssetIds == null) {
      this.realZcInsAssetIds = new ArrayList<>();
    }
    this.realZcInsAssetIds.add(realZcInsAssetIdsItem);
    return this;
  }

  /**
   * Get realZcInsAssetIds
   * @return realZcInsAssetIds
   */
  @javax.annotation.Nullable
  public List<String> getRealZcInsAssetIds() {
    return realZcInsAssetIds;
  }

  public void setRealZcInsAssetIds(@javax.annotation.Nullable List<String> realZcInsAssetIds) {
    this.realZcInsAssetIds = realZcInsAssetIds;
  }


  public TxGenerationContextModel zcInputAmounts(@javax.annotation.Nullable List<Integer> zcInputAmounts) {
    this.zcInputAmounts = zcInputAmounts;
    return this;
  }

  public TxGenerationContextModel addZcInputAmountsItem(Integer zcInputAmountsItem) {
    if (this.zcInputAmounts == null) {
      this.zcInputAmounts = new ArrayList<>();
    }
    this.zcInputAmounts.add(zcInputAmountsItem);
    return this;
  }

  /**
   * Get zcInputAmounts
   * @return zcInputAmounts
   */
  @javax.annotation.Nullable
  public List<Integer> getZcInputAmounts() {
    return zcInputAmounts;
  }

  public void setZcInputAmounts(@javax.annotation.Nullable List<Integer> zcInputAmounts) {
    this.zcInputAmounts = zcInputAmounts;
  }


  public TxGenerationContextModel pseudoOutAmountCommitmentsSum(@javax.annotation.Nullable String pseudoOutAmountCommitmentsSum) {
    this.pseudoOutAmountCommitmentsSum = pseudoOutAmountCommitmentsSum;
    return this;
  }

  /**
   * Get pseudoOutAmountCommitmentsSum
   * @return pseudoOutAmountCommitmentsSum
   */
  @javax.annotation.Nullable
  public String getPseudoOutAmountCommitmentsSum() {
    return pseudoOutAmountCommitmentsSum;
  }

  public void setPseudoOutAmountCommitmentsSum(@javax.annotation.Nullable String pseudoOutAmountCommitmentsSum) {
    this.pseudoOutAmountCommitmentsSum = pseudoOutAmountCommitmentsSum;
  }


  public TxGenerationContextModel pseudoOutAmountBlindingMasksSum(@javax.annotation.Nullable String pseudoOutAmountBlindingMasksSum) {
    this.pseudoOutAmountBlindingMasksSum = pseudoOutAmountBlindingMasksSum;
    return this;
  }

  /**
   * Get pseudoOutAmountBlindingMasksSum
   * @return pseudoOutAmountBlindingMasksSum
   */
  @javax.annotation.Nullable
  public String getPseudoOutAmountBlindingMasksSum() {
    return pseudoOutAmountBlindingMasksSum;
  }

  public void setPseudoOutAmountBlindingMasksSum(@javax.annotation.Nullable String pseudoOutAmountBlindingMasksSum) {
    this.pseudoOutAmountBlindingMasksSum = pseudoOutAmountBlindingMasksSum;
  }


  public TxGenerationContextModel realInAssetIdBlindingMaskXAmountSum(@javax.annotation.Nullable String realInAssetIdBlindingMaskXAmountSum) {
    this.realInAssetIdBlindingMaskXAmountSum = realInAssetIdBlindingMaskXAmountSum;
    return this;
  }

  /**
   * Get realInAssetIdBlindingMaskXAmountSum
   * @return realInAssetIdBlindingMaskXAmountSum
   */
  @javax.annotation.Nullable
  public String getRealInAssetIdBlindingMaskXAmountSum() {
    return realInAssetIdBlindingMaskXAmountSum;
  }

  public void setRealInAssetIdBlindingMaskXAmountSum(@javax.annotation.Nullable String realInAssetIdBlindingMaskXAmountSum) {
    this.realInAssetIdBlindingMaskXAmountSum = realInAssetIdBlindingMaskXAmountSum;
  }


  public TxGenerationContextModel amountCommitmentsSum(@javax.annotation.Nullable String amountCommitmentsSum) {
    this.amountCommitmentsSum = amountCommitmentsSum;
    return this;
  }

  /**
   * Get amountCommitmentsSum
   * @return amountCommitmentsSum
   */
  @javax.annotation.Nullable
  public String getAmountCommitmentsSum() {
    return amountCommitmentsSum;
  }

  public void setAmountCommitmentsSum(@javax.annotation.Nullable String amountCommitmentsSum) {
    this.amountCommitmentsSum = amountCommitmentsSum;
  }


  public TxGenerationContextModel amountBlindingMasksSum(@javax.annotation.Nullable String amountBlindingMasksSum) {
    this.amountBlindingMasksSum = amountBlindingMasksSum;
    return this;
  }

  /**
   * Get amountBlindingMasksSum
   * @return amountBlindingMasksSum
   */
  @javax.annotation.Nullable
  public String getAmountBlindingMasksSum() {
    return amountBlindingMasksSum;
  }

  public void setAmountBlindingMasksSum(@javax.annotation.Nullable String amountBlindingMasksSum) {
    this.amountBlindingMasksSum = amountBlindingMasksSum;
  }


  public TxGenerationContextModel assetIdBlindingMaskXAmountSum(@javax.annotation.Nullable String assetIdBlindingMaskXAmountSum) {
    this.assetIdBlindingMaskXAmountSum = assetIdBlindingMaskXAmountSum;
    return this;
  }

  /**
   * Get assetIdBlindingMaskXAmountSum
   * @return assetIdBlindingMaskXAmountSum
   */
  @javax.annotation.Nullable
  public String getAssetIdBlindingMaskXAmountSum() {
    return assetIdBlindingMaskXAmountSum;
  }

  public void setAssetIdBlindingMaskXAmountSum(@javax.annotation.Nullable String assetIdBlindingMaskXAmountSum) {
    this.assetIdBlindingMaskXAmountSum = assetIdBlindingMaskXAmountSum;
  }


  public TxGenerationContextModel aoAssetId(@javax.annotation.Nullable String aoAssetId) {
    this.aoAssetId = aoAssetId;
    return this;
  }

  /**
   * Get aoAssetId
   * @return aoAssetId
   */
  @javax.annotation.Nullable
  public String getAoAssetId() {
    return aoAssetId;
  }

  public void setAoAssetId(@javax.annotation.Nullable String aoAssetId) {
    this.aoAssetId = aoAssetId;
  }


  public TxGenerationContextModel aoAssetIdPt(@javax.annotation.Nullable String aoAssetIdPt) {
    this.aoAssetIdPt = aoAssetIdPt;
    return this;
  }

  /**
   * Get aoAssetIdPt
   * @return aoAssetIdPt
   */
  @javax.annotation.Nullable
  public String getAoAssetIdPt() {
    return aoAssetIdPt;
  }

  public void setAoAssetIdPt(@javax.annotation.Nullable String aoAssetIdPt) {
    this.aoAssetIdPt = aoAssetIdPt;
  }


  public TxGenerationContextModel aoAmountCommitment(@javax.annotation.Nullable String aoAmountCommitment) {
    this.aoAmountCommitment = aoAmountCommitment;
    return this;
  }

  /**
   * Get aoAmountCommitment
   * @return aoAmountCommitment
   */
  @javax.annotation.Nullable
  public String getAoAmountCommitment() {
    return aoAmountCommitment;
  }

  public void setAoAmountCommitment(@javax.annotation.Nullable String aoAmountCommitment) {
    this.aoAmountCommitment = aoAmountCommitment;
  }


  public TxGenerationContextModel aoAmountBlindingMask(@javax.annotation.Nullable String aoAmountBlindingMask) {
    this.aoAmountBlindingMask = aoAmountBlindingMask;
    return this;
  }

  /**
   * Get aoAmountBlindingMask
   * @return aoAmountBlindingMask
   */
  @javax.annotation.Nullable
  public String getAoAmountBlindingMask() {
    return aoAmountBlindingMask;
  }

  public void setAoAmountBlindingMask(@javax.annotation.Nullable String aoAmountBlindingMask) {
    this.aoAmountBlindingMask = aoAmountBlindingMask;
  }


  public TxGenerationContextModel aoCommitmentInOutputs(@javax.annotation.Nullable Boolean aoCommitmentInOutputs) {
    this.aoCommitmentInOutputs = aoCommitmentInOutputs;
    return this;
  }

  /**
   * Get aoCommitmentInOutputs
   * @return aoCommitmentInOutputs
   */
  @javax.annotation.Nullable
  public Boolean getAoCommitmentInOutputs() {
    return aoCommitmentInOutputs;
  }

  public void setAoCommitmentInOutputs(@javax.annotation.Nullable Boolean aoCommitmentInOutputs) {
    this.aoCommitmentInOutputs = aoCommitmentInOutputs;
  }


  public TxGenerationContextModel txKeyPub(@javax.annotation.Nullable String txKeyPub) {
    this.txKeyPub = txKeyPub;
    return this;
  }

  /**
   * Get txKeyPub
   * @return txKeyPub
   */
  @javax.annotation.Nullable
  public String getTxKeyPub() {
    return txKeyPub;
  }

  public void setTxKeyPub(@javax.annotation.Nullable String txKeyPub) {
    this.txKeyPub = txKeyPub;
  }


  public TxGenerationContextModel txKeySec(@javax.annotation.Nullable String txKeySec) {
    this.txKeySec = txKeySec;
    return this;
  }

  /**
   * Get txKeySec
   * @return txKeySec
   */
  @javax.annotation.Nullable
  public String getTxKeySec() {
    return txKeySec;
  }

  public void setTxKeySec(@javax.annotation.Nullable String txKeySec) {
    this.txKeySec = txKeySec;
  }


  public TxGenerationContextModel txPubKeyP(@javax.annotation.Nullable String txPubKeyP) {
    this.txPubKeyP = txPubKeyP;
    return this;
  }

  /**
   * Get txPubKeyP
   * @return txPubKeyP
   */
  @javax.annotation.Nullable
  public String getTxPubKeyP() {
    return txPubKeyP;
  }

  public void setTxPubKeyP(@javax.annotation.Nullable String txPubKeyP) {
    this.txPubKeyP = txPubKeyP;
  }



  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    TxGenerationContextModel txGenerationContextModel = (TxGenerationContextModel) o;
    return Objects.equals(this.assetIds, txGenerationContextModel.assetIds) &&
        Objects.equals(this.blindedAssetIds, txGenerationContextModel.blindedAssetIds) &&
        Objects.equals(this.amountCommitments, txGenerationContextModel.amountCommitments) &&
        Objects.equals(this.assetIdBlindingMasks, txGenerationContextModel.assetIdBlindingMasks) &&
        Objects.equals(this.amounts, txGenerationContextModel.amounts) &&
        Objects.equals(this.amountBlindingMasks, txGenerationContextModel.amountBlindingMasks) &&
        Objects.equals(this.pseudoOutsBlindedAssetIds, txGenerationContextModel.pseudoOutsBlindedAssetIds) &&
        Objects.equals(this.pseudoOutsPlusRealOutBlindingMasks, txGenerationContextModel.pseudoOutsPlusRealOutBlindingMasks) &&
        Objects.equals(this.realZcInsAssetIds, txGenerationContextModel.realZcInsAssetIds) &&
        Objects.equals(this.zcInputAmounts, txGenerationContextModel.zcInputAmounts) &&
        Objects.equals(this.pseudoOutAmountCommitmentsSum, txGenerationContextModel.pseudoOutAmountCommitmentsSum) &&
        Objects.equals(this.pseudoOutAmountBlindingMasksSum, txGenerationContextModel.pseudoOutAmountBlindingMasksSum) &&
        Objects.equals(this.realInAssetIdBlindingMaskXAmountSum, txGenerationContextModel.realInAssetIdBlindingMaskXAmountSum) &&
        Objects.equals(this.amountCommitmentsSum, txGenerationContextModel.amountCommitmentsSum) &&
        Objects.equals(this.amountBlindingMasksSum, txGenerationContextModel.amountBlindingMasksSum) &&
        Objects.equals(this.assetIdBlindingMaskXAmountSum, txGenerationContextModel.assetIdBlindingMaskXAmountSum) &&
        Objects.equals(this.aoAssetId, txGenerationContextModel.aoAssetId) &&
        Objects.equals(this.aoAssetIdPt, txGenerationContextModel.aoAssetIdPt) &&
        Objects.equals(this.aoAmountCommitment, txGenerationContextModel.aoAmountCommitment) &&
        Objects.equals(this.aoAmountBlindingMask, txGenerationContextModel.aoAmountBlindingMask) &&
        Objects.equals(this.aoCommitmentInOutputs, txGenerationContextModel.aoCommitmentInOutputs) &&
        Objects.equals(this.txKeyPub, txGenerationContextModel.txKeyPub) &&
        Objects.equals(this.txKeySec, txGenerationContextModel.txKeySec) &&
        Objects.equals(this.txPubKeyP, txGenerationContextModel.txPubKeyP);
  }

  @Override
  public int hashCode() {
    return Objects.hash(assetIds, blindedAssetIds, amountCommitments, assetIdBlindingMasks, amounts, amountBlindingMasks, pseudoOutsBlindedAssetIds, pseudoOutsPlusRealOutBlindingMasks, realZcInsAssetIds, zcInputAmounts, pseudoOutAmountCommitmentsSum, pseudoOutAmountBlindingMasksSum, realInAssetIdBlindingMaskXAmountSum, amountCommitmentsSum, amountBlindingMasksSum, assetIdBlindingMaskXAmountSum, aoAssetId, aoAssetIdPt, aoAmountCommitment, aoAmountBlindingMask, aoCommitmentInOutputs, txKeyPub, txKeySec, txPubKeyP);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class TxGenerationContextModel {\n");
    sb.append("    assetIds: ").append(toIndentedString(assetIds)).append("\n");
    sb.append("    blindedAssetIds: ").append(toIndentedString(blindedAssetIds)).append("\n");
    sb.append("    amountCommitments: ").append(toIndentedString(amountCommitments)).append("\n");
    sb.append("    assetIdBlindingMasks: ").append(toIndentedString(assetIdBlindingMasks)).append("\n");
    sb.append("    amounts: ").append(toIndentedString(amounts)).append("\n");
    sb.append("    amountBlindingMasks: ").append(toIndentedString(amountBlindingMasks)).append("\n");
    sb.append("    pseudoOutsBlindedAssetIds: ").append(toIndentedString(pseudoOutsBlindedAssetIds)).append("\n");
    sb.append("    pseudoOutsPlusRealOutBlindingMasks: ").append(toIndentedString(pseudoOutsPlusRealOutBlindingMasks)).append("\n");
    sb.append("    realZcInsAssetIds: ").append(toIndentedString(realZcInsAssetIds)).append("\n");
    sb.append("    zcInputAmounts: ").append(toIndentedString(zcInputAmounts)).append("\n");
    sb.append("    pseudoOutAmountCommitmentsSum: ").append(toIndentedString(pseudoOutAmountCommitmentsSum)).append("\n");
    sb.append("    pseudoOutAmountBlindingMasksSum: ").append(toIndentedString(pseudoOutAmountBlindingMasksSum)).append("\n");
    sb.append("    realInAssetIdBlindingMaskXAmountSum: ").append(toIndentedString(realInAssetIdBlindingMaskXAmountSum)).append("\n");
    sb.append("    amountCommitmentsSum: ").append(toIndentedString(amountCommitmentsSum)).append("\n");
    sb.append("    amountBlindingMasksSum: ").append(toIndentedString(amountBlindingMasksSum)).append("\n");
    sb.append("    assetIdBlindingMaskXAmountSum: ").append(toIndentedString(assetIdBlindingMaskXAmountSum)).append("\n");
    sb.append("    aoAssetId: ").append(toIndentedString(aoAssetId)).append("\n");
    sb.append("    aoAssetIdPt: ").append(toIndentedString(aoAssetIdPt)).append("\n");
    sb.append("    aoAmountCommitment: ").append(toIndentedString(aoAmountCommitment)).append("\n");
    sb.append("    aoAmountBlindingMask: ").append(toIndentedString(aoAmountBlindingMask)).append("\n");
    sb.append("    aoCommitmentInOutputs: ").append(toIndentedString(aoCommitmentInOutputs)).append("\n");
    sb.append("    txKeyPub: ").append(toIndentedString(txKeyPub)).append("\n");
    sb.append("    txKeySec: ").append(toIndentedString(txKeySec)).append("\n");
    sb.append("    txPubKeyP: ").append(toIndentedString(txPubKeyP)).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    ");
  }


  public static HashSet<String> openapiFields;
  public static HashSet<String> openapiRequiredFields;

  static {
    // a set of all properties/fields (JSON key names)
    openapiFields = new HashSet<String>(Arrays.asList("asset_ids", "blinded_asset_ids", "amount_commitments", "asset_id_blinding_masks", "amounts", "amount_blinding_masks", "pseudo_outs_blinded_asset_ids", "pseudo_outs_plus_real_out_blinding_masks", "real_zc_ins_asset_ids", "zc_input_amounts", "pseudo_out_amount_commitments_sum", "pseudo_out_amount_blinding_masks_sum", "real_in_asset_id_blinding_mask_x_amount_sum", "amount_commitments_sum", "amount_blinding_masks_sum", "asset_id_blinding_mask_x_amount_sum", "ao_asset_id", "ao_asset_id_pt", "ao_amount_commitment", "ao_amount_blinding_mask", "ao_commitment_in_outputs", "tx_key_pub", "tx_key_sec", "tx_pub_key_p"));

    // a set of required properties/fields (JSON key names)
    openapiRequiredFields = new HashSet<String>(0);
  }

  /**
   * Validates the JSON Element and throws an exception if issues found
   *
   * @param jsonElement JSON Element
   * @throws IOException if the JSON Element is invalid with respect to TxGenerationContextModel
   */
  public static void validateJsonElement(JsonElement jsonElement) throws IOException {
      if (jsonElement == null) {
        if (!TxGenerationContextModel.openapiRequiredFields.isEmpty()) { // has required fields but JSON element is null
          throw new IllegalArgumentException(String.format(Locale.ROOT, "The required field(s) %s in TxGenerationContextModel is not found in the empty JSON string", TxGenerationContextModel.openapiRequiredFields.toString()));
        }
      }

      Set<Map.Entry<String, JsonElement>> entries = jsonElement.getAsJsonObject().entrySet();
      // check to see if the JSON string contains additional fields
      for (Map.Entry<String, JsonElement> entry : entries) {
        if (!TxGenerationContextModel.openapiFields.contains(entry.getKey())) {
          throw new IllegalArgumentException(String.format(Locale.ROOT, "The field `%s` in the JSON string is not defined in the `TxGenerationContextModel` properties. JSON: %s", entry.getKey(), jsonElement.toString()));
        }
      }
        JsonObject jsonObj = jsonElement.getAsJsonObject();
      // ensure the optional json data is an array if present
      if (jsonObj.get("asset_ids") != null && !jsonObj.get("asset_ids").isJsonNull() && !jsonObj.get("asset_ids").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `asset_ids` to be an array in the JSON string but got `%s`", jsonObj.get("asset_ids").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("blinded_asset_ids") != null && !jsonObj.get("blinded_asset_ids").isJsonNull() && !jsonObj.get("blinded_asset_ids").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `blinded_asset_ids` to be an array in the JSON string but got `%s`", jsonObj.get("blinded_asset_ids").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("amount_commitments") != null && !jsonObj.get("amount_commitments").isJsonNull() && !jsonObj.get("amount_commitments").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `amount_commitments` to be an array in the JSON string but got `%s`", jsonObj.get("amount_commitments").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("asset_id_blinding_masks") != null && !jsonObj.get("asset_id_blinding_masks").isJsonNull() && !jsonObj.get("asset_id_blinding_masks").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `asset_id_blinding_masks` to be an array in the JSON string but got `%s`", jsonObj.get("asset_id_blinding_masks").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("amounts") != null && !jsonObj.get("amounts").isJsonNull() && !jsonObj.get("amounts").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `amounts` to be an array in the JSON string but got `%s`", jsonObj.get("amounts").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("amount_blinding_masks") != null && !jsonObj.get("amount_blinding_masks").isJsonNull() && !jsonObj.get("amount_blinding_masks").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `amount_blinding_masks` to be an array in the JSON string but got `%s`", jsonObj.get("amount_blinding_masks").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("pseudo_outs_blinded_asset_ids") != null && !jsonObj.get("pseudo_outs_blinded_asset_ids").isJsonNull() && !jsonObj.get("pseudo_outs_blinded_asset_ids").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `pseudo_outs_blinded_asset_ids` to be an array in the JSON string but got `%s`", jsonObj.get("pseudo_outs_blinded_asset_ids").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("pseudo_outs_plus_real_out_blinding_masks") != null && !jsonObj.get("pseudo_outs_plus_real_out_blinding_masks").isJsonNull() && !jsonObj.get("pseudo_outs_plus_real_out_blinding_masks").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `pseudo_outs_plus_real_out_blinding_masks` to be an array in the JSON string but got `%s`", jsonObj.get("pseudo_outs_plus_real_out_blinding_masks").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("real_zc_ins_asset_ids") != null && !jsonObj.get("real_zc_ins_asset_ids").isJsonNull() && !jsonObj.get("real_zc_ins_asset_ids").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `real_zc_ins_asset_ids` to be an array in the JSON string but got `%s`", jsonObj.get("real_zc_ins_asset_ids").toString()));
      }
      // ensure the optional json data is an array if present
      if (jsonObj.get("zc_input_amounts") != null && !jsonObj.get("zc_input_amounts").isJsonNull() && !jsonObj.get("zc_input_amounts").isJsonArray()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `zc_input_amounts` to be an array in the JSON string but got `%s`", jsonObj.get("zc_input_amounts").toString()));
      }
      if ((jsonObj.get("pseudo_out_amount_commitments_sum") != null && !jsonObj.get("pseudo_out_amount_commitments_sum").isJsonNull()) && !jsonObj.get("pseudo_out_amount_commitments_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `pseudo_out_amount_commitments_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("pseudo_out_amount_commitments_sum").toString()));
      }
      if ((jsonObj.get("pseudo_out_amount_blinding_masks_sum") != null && !jsonObj.get("pseudo_out_amount_blinding_masks_sum").isJsonNull()) && !jsonObj.get("pseudo_out_amount_blinding_masks_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `pseudo_out_amount_blinding_masks_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("pseudo_out_amount_blinding_masks_sum").toString()));
      }
      if ((jsonObj.get("real_in_asset_id_blinding_mask_x_amount_sum") != null && !jsonObj.get("real_in_asset_id_blinding_mask_x_amount_sum").isJsonNull()) && !jsonObj.get("real_in_asset_id_blinding_mask_x_amount_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `real_in_asset_id_blinding_mask_x_amount_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("real_in_asset_id_blinding_mask_x_amount_sum").toString()));
      }
      if ((jsonObj.get("amount_commitments_sum") != null && !jsonObj.get("amount_commitments_sum").isJsonNull()) && !jsonObj.get("amount_commitments_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `amount_commitments_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("amount_commitments_sum").toString()));
      }
      if ((jsonObj.get("amount_blinding_masks_sum") != null && !jsonObj.get("amount_blinding_masks_sum").isJsonNull()) && !jsonObj.get("amount_blinding_masks_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `amount_blinding_masks_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("amount_blinding_masks_sum").toString()));
      }
      if ((jsonObj.get("asset_id_blinding_mask_x_amount_sum") != null && !jsonObj.get("asset_id_blinding_mask_x_amount_sum").isJsonNull()) && !jsonObj.get("asset_id_blinding_mask_x_amount_sum").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `asset_id_blinding_mask_x_amount_sum` to be a primitive type in the JSON string but got `%s`", jsonObj.get("asset_id_blinding_mask_x_amount_sum").toString()));
      }
      if ((jsonObj.get("ao_asset_id") != null && !jsonObj.get("ao_asset_id").isJsonNull()) && !jsonObj.get("ao_asset_id").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `ao_asset_id` to be a primitive type in the JSON string but got `%s`", jsonObj.get("ao_asset_id").toString()));
      }
      if ((jsonObj.get("ao_asset_id_pt") != null && !jsonObj.get("ao_asset_id_pt").isJsonNull()) && !jsonObj.get("ao_asset_id_pt").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `ao_asset_id_pt` to be a primitive type in the JSON string but got `%s`", jsonObj.get("ao_asset_id_pt").toString()));
      }
      if ((jsonObj.get("ao_amount_commitment") != null && !jsonObj.get("ao_amount_commitment").isJsonNull()) && !jsonObj.get("ao_amount_commitment").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `ao_amount_commitment` to be a primitive type in the JSON string but got `%s`", jsonObj.get("ao_amount_commitment").toString()));
      }
      if ((jsonObj.get("ao_amount_blinding_mask") != null && !jsonObj.get("ao_amount_blinding_mask").isJsonNull()) && !jsonObj.get("ao_amount_blinding_mask").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `ao_amount_blinding_mask` to be a primitive type in the JSON string but got `%s`", jsonObj.get("ao_amount_blinding_mask").toString()));
      }
      if ((jsonObj.get("tx_key_pub") != null && !jsonObj.get("tx_key_pub").isJsonNull()) && !jsonObj.get("tx_key_pub").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `tx_key_pub` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tx_key_pub").toString()));
      }
      if ((jsonObj.get("tx_key_sec") != null && !jsonObj.get("tx_key_sec").isJsonNull()) && !jsonObj.get("tx_key_sec").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `tx_key_sec` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tx_key_sec").toString()));
      }
      if ((jsonObj.get("tx_pub_key_p") != null && !jsonObj.get("tx_pub_key_p").isJsonNull()) && !jsonObj.get("tx_pub_key_p").isJsonPrimitive()) {
        throw new IllegalArgumentException(String.format(Locale.ROOT, "Expected the field `tx_pub_key_p` to be a primitive type in the JSON string but got `%s`", jsonObj.get("tx_pub_key_p").toString()));
      }
  }

  public static class CustomTypeAdapterFactory implements TypeAdapterFactory {
    @SuppressWarnings("unchecked")
    @Override
    public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) {
       if (!TxGenerationContextModel.class.isAssignableFrom(type.getRawType())) {
         return null; // this class only serializes 'TxGenerationContextModel' and its subtypes
       }
       final TypeAdapter<JsonElement> elementAdapter = gson.getAdapter(JsonElement.class);
       final TypeAdapter<TxGenerationContextModel> thisAdapter
                        = gson.getDelegateAdapter(this, TypeToken.get(TxGenerationContextModel.class));

       return (TypeAdapter<T>) new TypeAdapter<TxGenerationContextModel>() {
           @Override
           public void write(JsonWriter out, TxGenerationContextModel value) throws IOException {
             JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject();
             elementAdapter.write(out, obj);
           }

           @Override
           public TxGenerationContextModel read(JsonReader in) throws IOException {
             JsonElement jsonElement = elementAdapter.read(in);
             validateJsonElement(jsonElement);
             return thisAdapter.fromJsonTree(jsonElement);
           }

       }.nullSafe();
    }
  }

  /**
   * Create an instance of TxGenerationContextModel given an JSON string
   *
   * @param jsonString JSON string
   * @return An instance of TxGenerationContextModel
   * @throws IOException if the JSON string is invalid with respect to TxGenerationContextModel
   */
  public static TxGenerationContextModel fromJson(String jsonString) throws IOException {
    return JSON.getGson().fromJson(jsonString, TxGenerationContextModel.class);
  }

  /**
   * Convert an instance of TxGenerationContextModel to an JSON string
   *
   * @return JSON string
   */
  public String toJson() {
    return JSON.getGson().toJson(this);
  }
}

