org.jboss.resteasy.client.core.executors
Class ApacheHttpClient4Executor

java.lang.Object
  extended by org.jboss.resteasy.client.core.executors.ApacheHttpClient4Executor
All Implemented Interfaces:
ClientExecutor

public class ApacheHttpClient4Executor
extends Object
implements ClientExecutor

Version:
$Revision: 1 $
Author:
Bill Burke

Field Summary
protected  boolean closed
           
protected  boolean createdHttpClient
           
protected  org.apache.http.client.HttpClient httpClient
           
protected  org.apache.http.protocol.HttpContext httpContext
           
 
Constructor Summary
ApacheHttpClient4Executor()
           
ApacheHttpClient4Executor(org.apache.http.client.HttpClient httpClient)
           
ApacheHttpClient4Executor(org.apache.http.client.HttpClient httpClient, org.apache.http.protocol.HttpContext httpContext)
           
 
Method Summary
 void close()
           
 void commitHeaders(ClientRequest request, org.apache.http.client.methods.HttpRequestBase httpMethod)
           
 ClientRequest createRequest(String uriTemplate)
           
 ClientRequest createRequest(UriBuilder uriBuilder)
           
 ClientResponse execute(ClientRequest request)
           
static CaseInsensitiveMap<String> extractHeaders(org.apache.http.HttpResponse response)
           
 void finalize()
           
 org.apache.http.client.HttpClient getHttpClient()
           
 org.apache.http.protocol.HttpContext getHttpContext()
           
 boolean isClosed()
           
 void loadHttpMethod(ClientRequest request, org.apache.http.client.methods.HttpRequestBase httpMethod)
           
 void setHttpContext(org.apache.http.protocol.HttpContext httpContext)
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

httpClient

protected org.apache.http.client.HttpClient httpClient

createdHttpClient

protected boolean createdHttpClient

httpContext

protected org.apache.http.protocol.HttpContext httpContext

closed

protected boolean closed
Constructor Detail

ApacheHttpClient4Executor

public ApacheHttpClient4Executor()

ApacheHttpClient4Executor

public ApacheHttpClient4Executor(org.apache.http.client.HttpClient httpClient)

ApacheHttpClient4Executor

public ApacheHttpClient4Executor(org.apache.http.client.HttpClient httpClient,
                                 org.apache.http.protocol.HttpContext httpContext)
Method Detail

getHttpClient

public org.apache.http.client.HttpClient getHttpClient()

getHttpContext

public org.apache.http.protocol.HttpContext getHttpContext()

setHttpContext

public void setHttpContext(org.apache.http.protocol.HttpContext httpContext)

extractHeaders

public static CaseInsensitiveMap<String> extractHeaders(org.apache.http.HttpResponse response)

createRequest

public ClientRequest createRequest(String uriTemplate)
Specified by:
createRequest in interface ClientExecutor

createRequest

public ClientRequest createRequest(UriBuilder uriBuilder)
Specified by:
createRequest in interface ClientExecutor

execute

public ClientResponse execute(ClientRequest request)
                       throws Exception
Specified by:
execute in interface ClientExecutor
Throws:
Exception

loadHttpMethod

public void loadHttpMethod(ClientRequest request,
                           org.apache.http.client.methods.HttpRequestBase httpMethod)
                    throws Exception
Throws:
Exception

commitHeaders

public void commitHeaders(ClientRequest request,
                          org.apache.http.client.methods.HttpRequestBase httpMethod)

close

public void close()
Specified by:
close in interface ClientExecutor

isClosed

public boolean isClosed()

finalize

public void finalize()
              throws Throwable
Overrides:
finalize in class Object
Throws:
Throwable


Copyright © 2012. All Rights Reserved.