Back to project page Weather-app.
The source code is released under:
Apache License
If you think the Android project Weather-app listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package app.sunshine.juanjo.network; /* w w w . j a v a 2s .c om*/ import com.squareup.okhttp.OkHttpClient; import com.squareup.okhttp.Request; import com.squareup.okhttp.Response; import java.io.IOException; /** * Created by juanjo on 03/08/14. */ public class APIHTTP { OkHttpClient client = new OkHttpClient(); public String run(String url) throws IOException { Request request = new Request.Builder() .url(url) .build(); Response response = client.newCall(request).execute(); return response.body().string(); } }