// Path: app/src/main/java/com/bytetobyte/xwallet/network/api/models/CexCharItem.java
// public class CexCharItem {
//     private String tmsp;
//     private String price;
// 
//     /**
//      *
//      * @return
//      */
//     public String getTmsp() {
//         return tmsp;
//     }
// 
//     /**
//      *
//      * @return
//      */
//     public String getPrice() {
//         return price;
//     }
// }


import android.os.AsyncTask;
import com.bytetobyte.xwallet.network.api.models.CexCharItem;
import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;
import com.squareup.okhttp.FormEncodingBuilder;
import com.squareup.okhttp.HttpUrl;
import com.squareup.okhttp.OkHttpClient;
import com.squareup.okhttp.Request;
import com.squareup.okhttp.Response;
import com.squareup.okhttp.ResponseBody;
import java.io.IOException;
import java.lang.reflect.Type;
import java.util.List;
import okio.GzipSource;
import okio.Okio;
        try {
            Response response = client.newCall(request).execute();
            ResponseBody body = response.body();

            if (isZipped(response)) {
                content = unzip(body);
            } else {
                content = body.string();
            }

            body.close();
        } catch (IOException e) {
            e.printStackTrace();
        }

        return content;
    }

    /**
     *
     * @param s
     */
    @Override
    protected void onPostExecute(String s) {
        super.onPostExecute(s);

        //System.out.println("CexChartApi result : " + s);

        try {
            Gson gson = new Gson();
// Path: app/src/main/java/com/bytetobyte/xwallet/network/api/models/CexCharItem.java
// public class CexCharItem {
//     private String tmsp;
//     private String price;
// 
//     /**
//      *
//      * @return
//      */
//     public String getTmsp() {
//         return tmsp;
//     }
// 
//     /**
//      *
//      * @return
//      */
//     public String getPrice() {
//         return price;
//     }
// }


// Path: app/src/main/java/com/bytetobyte/xwallet/network/api/CexChartAPI.java
import android.os.AsyncTask;
import com.bytetobyte.xwallet.network.api.models.CexCharItem;
import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;
import com.squareup.okhttp.FormEncodingBuilder;
import com.squareup.okhttp.HttpUrl;
import com.squareup.okhttp.OkHttpClient;
import com.squareup.okhttp.Request;
import com.squareup.okhttp.Response;
import com.squareup.okhttp.ResponseBody;
import java.io.IOException;
import java.lang.reflect.Type;
import java.util.List;
import okio.GzipSource;
import okio.Okio;

        try {
            Response response = client.newCall(request).execute();
            ResponseBody body = response.body();

            if (isZipped(response)) {
                content = unzip(body);
            } else {
                content = body.string();
            }

            body.close();
        } catch (IOException e) {
            e.printStackTrace();
        }

        return content;
    }

    /**
     *
     * @param s
     */
    @Override
    protected void onPostExecute(String s) {
        super.onPostExecute(s);

        //System.out.println("CexChartApi result : " + s);

        try {
            Gson gson = new Gson();
            Type listType = new TypeToken<List<CexCharItem>>(){}.getType();