Code example for HttpResponse

Methods: getFirstHeadergetEntitygetStatusLine

0
      @Override 
      public String handleResponse(HttpResponse resp) 
        throws org.apache.http.client.HttpResponseException, 
               java.io.IOException { 
 
        if (resp.getStatusLine().getStatusCode() >= 300) return null; 
        FileWatcher.this.lastEtag = resp.getFirstHeader("ETag").getValue(); 
        HttpEntity entity = resp.getEntity(); 
        return entity == null ? null : EntityUtils.toString(entity); 
      } 
    }; 
 
 
    public void pause()  { paused = true; }
    public void resume() { paused = false; }
 
    @Override 
    protected void onPreExecute() {} 
 
    @Override 
Stop searching for code, let great code find you!  Add Codota to your java IDE