我试图使用
try {
HttpClient client = new DefaultHttpClient();
String getURL = "https://api.foursquare.com/v2/venues/4cbd52efd78f46881cf1cc73";
HttpGet get = new HttpGet(getURL);
HttpResponse responseGet = client.execute(get);
HttpEntity resEntityGet = responseGet.getEntity();
if (resEntityGet != null) {
// do something with the response
String response = EntityUtils.toString(resEntityGet);
Log.i("GET RESPONSE", response);
}
} catch (Exception e) {
e.printStackTrace();
}
如何使用这个?
请救救我
谢谢