package com.gingersoft.gsa.cloud.pay;

import android.os.Parcel;
import android.os.Parcelable;

import com.gingersoft.gsa.cloud.pay.Callback;
import com.gingersoft.gsa.cloud.pay.PayAction;
import com.gingersoft.gsa.cloud.pay.bean.PayMethod;
import com.google.gson.annotations.SerializedName;

import java.io.Serializable;
import java.util.List;

import lombok.Builder;
import lombok.Data;
import lombok.Getter;

/**
 * @作者: bin
 * @創建時間: 2021-04-15 16:46
 * @更新時間: 2021-04-15 16:46
 * @描述:
 */
@Data
@Builder
public class RequestParms implements Serializable {

    private PayAction action;
    private final int resturantId;
    private final List<PayMethod> payMethods;
    private final int payType;
    private final long orderId;
    private final double payMoney;
    /**
     * 退款相关
     */
    private final String refundReason;
    /**
     * 操作行为回调如支付，退款等
     */
    private Callback callback;
    /**
     * 结果回调
     */
    private ResultCallback resultCallback;

//    @Override
//    public int describeContents() {
//        return 0;
//    }
//
//    @Override
//    public void writeToParcel(Parcel dest, int flags) {
//        dest.writeInt(this.payType);
//        dest.writeLong(this.orderId);
//        dest.writeDouble(this.payMoney);
//    }
//
//    protected RequestParms(Parcel in) {
//        this.payType = in.readInt();
//        this.orderId = in.readLong();
//        this.payMoney = in.readDouble();
//    }
//
//    public static final Creator<RequestParms> CREATOR = new Creator<RequestParms>() {
//        @Override
//        public RequestParms createFromParcel(Parcel source) {
//            return new RequestParms(source);
//        }
//
//        @Override
//        public RequestParms[] newArray(int size) {
//            return new RequestParms[size];
//        }
//    };
}
