Code example for HttpResponse

Methods: getEntitysetEntity

     * Executes a fully formed request, and returns the results. 
     * @param req The request. 
     * @return The execution resonse. 
     * @throws ClientProtocolException 
     * @throws IOException 
    protected Execution execute(HttpRequestBase req) throws ClientProtocolException, IOException {
        HttpResponse res = http.execute(req);
        HttpEntity entity = res.getEntity();
        if (entity != null) {
            // Wrapping response entity to handle gzip decompression transparently 
            // Note: AndroidHttpClient doesn't let you add response interceptors to the underlying DefaultHttpClient 
            res.setEntity(new GzipDecompressingEntity(res.getEntity()));
        return new Execution(req, res);
Contextual code suggestions in your IDE  Get Codota for Java