打牌网 v4.0.4版本的 MD5 值为:e257b9ecf68b0639529ede50d4c5ca4b
以下内容为反编译后的 GetBilIdlRequest.java 源代码,内容仅作参考
package org.xianliao.im.sdk.net.model;
import android.text.TextUtils;
import android.util.Log;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.HashMap;
import java.util.Map;
import org.json.JSONException;
import org.json.JSONObject;
import org.xianliao.im.sdk.net.GetReq;
import org.xianliao.im.sdk.net.NetBaseResp;
class GetBilIdlRequest {
GetBilIdlRequest() {
}
public static class Req extends GetReq {
private NetBaseResp resp;
private String userId;
private String url = "http://120.24.210.161:52234/gateway/red/dispatcher";
private Map<String, String> argsMap = new HashMap();
private int cmdId = 805441569;
public Req(NetBaseResp resp) {
this.resp = resp;
}
public void setUerOpenId(String userId) {
this.userId = userId;
}
@Override
public URL getUrl() {
try {
String query = handleRequestArgs();
String urlString = this.url;
if (!TextUtils.isEmpty(query)) {
urlString = urlString + "?" + query;
}
return new URL(urlString);
} catch (MalformedURLException e) {
e.printStackTrace();
return null;
}
}
@Override
public NetBaseResp getResp() {
return this.resp;
}
@Override
public Map<String, String> getRequestArgs() {
this.argsMap.put("cmdId", this.cmdId + "");
if (!TextUtils.isEmpty(this.userId)) {
String json = "{\"uin\" : \"" + this.userId + "\"}";
this.argsMap.put("request", json);
}
return this.argsMap;
}
}
public static class Resp extends NetBaseResp {
static final String TAG = "GetBilIdlRequest.Resp";
public long billId;
public long constructor;
@Override
public void response(String result) {
Log.i(TAG, "result: " + result);
try {
JSONObject object = new JSONObject(result);
this.billId = object.getLong("billId");
this.constructor = object.getLong("constructor");
} catch (JSONException e) {
e.printStackTrace();
}
}
}
}