package com.mgw.member.uitls;
import com.loopj.android.http.AsyncHttpClient;
import com.loopj.android.http.AsyncHttpResponseHandler;
import com.loopj.android.http.RequestParams;
public class MgqRestClient {
public final static String TAG = "MgqRestClient";
private static AsyncHttpClient client = new AsyncHttpClient();
public static void get(String url, RequestParams params,
AsyncHttpResponseHandler responseHandler) {
client.setTimeout(10000);
client.get(getAbsoluteUrl(url), params, responseHandler);
}
public static void post(String url, RequestParams params,
AsyncHttpResponseHandler responseHandler) {
client.setTimeout(20000);
client.post(getAbsoluteUrl(url), params, responseHandler);
}
private static String getAbsoluteUrl(String relativeUrl) {
return relativeUrl;
}
}