文字列をアクティビティに送信したい:
public class MyHttpClientUsage {
public MyHttpClientUsage(){}
public void getInfoAbout() throws HttpException{
RequestParams params = new RequestParams();
params.put("a", "Static");
params.put("content", "47");
MyHttpClient.get("", params, new AsyncHttpResponseHandler(){
@Override
public void onSuccess(String response) {
System.out.println(response);
//How can I send this response
}
});
}
}
メソッドが静的であるため、インテントを使用できget()
ません。そのため、コンテキストなどをインスタンス化できませんMyHttpClient
。