content: /*
   * 支付宝开放平台API
   * 支付宝开放平台v3协议文档
   *
   * The version of the OpenAPI document: 2024-01-10
   * 
   *
   * 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.alipay.v3.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 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 java.lang.reflect.Type;
  import java.util.HashMap;
  import java.util.HashSet;
  import java.util.Map;
  import java.util.Map.Entry;
  import java.util.Set;
  
  import com.alipay.v3.JSON;
  
  /**
   * AlipayEbppBillGetModel
   */
  @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
  public class AlipayEbppBillGetModel {
    public static final String SERIALIZED_NAME_MERCHANT_ORDER_NO = "merchant_order_no";
    @SerializedName(SERIALIZED_NAME_MERCHANT_ORDER_NO)
    private String merchantOrderNo;
  
    public static final String SERIALIZED_NAME_ORDER_TYPE = "order_type";
    @SerializedName(SERIALIZED_NAME_ORDER_TYPE)
    private String orderType;
  
    public AlipayEbppBillGetModel() { 
    }
  
    public AlipayEbppBillGetModel merchantOrderNo(String merchantOrderNo) {
      
      this.merchantOrderNo = merchantOrderNo;
      return this;
    }
  
     /**
     * 输出机构的业务流水号，需要保证唯一性。
     * @return merchantOrderNo
    **/
    @javax.annotation.Nullable
    @ApiModelProperty(example = "201203031234567", value = "输出机构的业务流水号，需要保证唯一性。")
  
    public String getMerchantOrderNo() {
      return merchantOrderNo;
    }
  
  
    public void setMerchantOrderNo(String merchantOrderNo) {
      this.merchantOrderNo = merchantOrderNo;
    }
  
  
    public AlipayEbppBillGetModel orderType(String orderType) {
      
      this.orderType = orderType;
      return this;
    }
  
     /**
     * 支付宝订单类型。公共事业缴纳JF,信用卡还款HK
     * @return orderType
    **/
    @javax.annotation.Nullable
    @ApiModelProperty(example = "JF", value = "支付宝订单类型。公共事业缴纳JF,信用卡还款HK")
  
    public String getOrderType() {
      return orderType;
    }
  
  
    public void setOrderType(String orderType) {
      this.orderType = orderType;
    }
  
  
  
    @Override
    public boolean equals(Object o) {
      if (this == o) {
        return true;
      }
      if (o == null || getClass() != o.getClass()) {
        return false;
      }
      AlipayEbppBillGetModel alipayEbppBillGetModel = (AlipayEbppBillGetModel) o;
      return Objects.equals(this.merchantOrderNo, alipayEbppBillGetModel.merchantOrderNo) &&
          Objects.equals(this.orderType, alipayEbppBillGetModel.orderType);
    }
  
    @Override
    public int hashCode() {
      return Objects.hash(merchantOrderNo, orderType);
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append("class AlipayEbppBillGetModel {\n");
      sb.append("    merchantOrderNo: ").append(toIndentedString(merchantOrderNo)).append("\n");
      sb.append("    orderType: ").append(toIndentedString(orderType)).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>();
      openapiFields.add("merchant_order_no");
      openapiFields.add("order_type");
  
      // a set of required properties/fields (JSON key names)
      openapiRequiredFields = new HashSet<String>();
    }
  
   /**
    * Validates the JSON Object and throws an exception if issues found
    *
    * @param jsonObj JSON Object
    * @throws IOException if the JSON Object is invalid with respect to AlipayEbppBillGetModel
    */
    public static void validateJsonObject(JsonObject jsonObj) throws IOException {
        if (jsonObj == null) {
          if (AlipayEbppBillGetModel.openapiRequiredFields.isEmpty()) {
            return;
          } else { // has required fields
            throw new IllegalArgumentException(String.format("The required field(s) %s in AlipayEbppBillGetModel is not found in the empty JSON string", AlipayEbppBillGetModel.openapiRequiredFields.toString()));
          }
        }
  
        Set<Entry<String, JsonElement>> entries = jsonObj.entrySet();
        // check to see if the JSON string contains additional fields
        for (Entry<String, JsonElement> entry : entries) {
          if (!AlipayEbppBillGetModel.openapiFields.contains(entry.getKey())) {
            throw new IllegalArgumentException(String.format("The field `%s` in the JSON string is not defined in the `AlipayEbppBillGetModel` properties. JSON: %s", entry.getKey(), jsonObj.toString()));
          }
        }
        if (jsonObj.get("merchant_order_no") != null && !jsonObj.get("merchant_order_no").isJsonPrimitive()) {
          throw new IllegalArgumentException(String.format("Expected the field `merchant_order_no` to be a primitive type in the JSON string but got `%s`", jsonObj.get("merchant_order_no").toString()));
        }
        if (jsonObj.get("order_type") != null && !jsonObj.get("order_type").isJsonPrimitive()) {
          throw new IllegalArgumentException(String.format("Expected the field `order_type` to be a primitive type in the JSON string but got `%s`", jsonObj.get("order_type").toString()));
        }
    }
  
    public static class CustomTypeAdapterFactory implements TypeAdapterFactory {
      @SuppressWarnings("unchecked")
      @Override
      public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) {
         if (!AlipayEbppBillGetModel.class.isAssignableFrom(type.getRawType())) {
           return null; // this class only serializes 'AlipayEbppBillGetModel' and its subtypes
         }
         final TypeAdapter<JsonElement> elementAdapter = gson.getAdapter(JsonElement.class);
         final TypeAdapter<AlipayEbppBillGetModel> thisAdapter
                          = gson.getDelegateAdapter(this, TypeToken.get(AlipayEbppBillGetModel.class));
  
         return (TypeAdapter<T>) new TypeAdapter<AlipayEbppBillGetModel>() {
             @Override
             public void write(JsonWriter out, AlipayEbppBillGetModel value) throws IOException {
               JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject();
               elementAdapter.write(out, obj);
             }
  
             @Override
             public AlipayEbppBillGetModel read(JsonReader in) throws IOException {
               JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject();
               validateJsonObject(jsonObj);
               return thisAdapter.fromJsonTree(jsonObj);
             }
  
         }.nullSafe();
      }
    }
  
   /**
    * Create an instance of AlipayEbppBillGetModel given an JSON string
    *
    * @param jsonString JSON string
    * @return An instance of AlipayEbppBillGetModel
    * @throws IOException if the JSON string is invalid with respect to AlipayEbppBillGetModel
    */
    public static AlipayEbppBillGetModel fromJson(String jsonString) throws IOException {
      return JSON.getGson().fromJson(jsonString, AlipayEbppBillGetModel.class);
    }
  
   /**
    * Convert an instance of AlipayEbppBillGetModel to an JSON string
    *
    * @return JSON string
    */
    public String toJson() {
      return JSON.getGson().toJson(this);
    }
  }
  
  