1
返回值我有这样的代码:从一个匿名类
public Dictionary<Object, Object> call(String method, Iterable args)
{
AsyncHttpClient client = new AsyncHttpClient();
client.get(getUrl(method, args), new AsyncHttpResponseHandler() {
@Override
public void onSuccess(String response)
{
Gson gson = new GsonBuilder().create();
}
});
}
我希望能够返回(Dictionary<Object, Object>) gson.fromJson(response, Dictionary.class)
我call
方法,但如何做?我使用http://loopj.com/android-async-http/有一个易于使用的异步HTTP请求系统。
谢谢!