Class ApacheHttpClient
- java.lang.Object
-
- org.eclipse.cbi.maven.http.apache.ApacheHttpClient
-
- All Implemented Interfaces:
HttpClient
public class ApacheHttpClient extends java.lang.Object implements HttpClient
An HttpClient implementation based on Apache HttpClient.
-
-
Constructor Summary
Constructors Constructor Description ApacheHttpClient(Logger log)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static HttpClientcreate(Logger log)private java.lang.BooleandoHandleResponse(CompletionListener completionListener, org.apache.http.HttpResponse response)booleansend(HttpRequest request, CompletionListener completionListener)booleansend(HttpRequest request, HttpRequest.Config config, CompletionListener completionListener)(package private) static org.apache.http.client.methods.HttpUriRequesttoApacheRequest(HttpRequest request, HttpRequest.Config config)
-
-
-
Field Detail
-
log
private final Logger log
The log for providingDEBUGfeedback about the process.
-
-
Constructor Detail
-
ApacheHttpClient
ApacheHttpClient(Logger log)
-
-
Method Detail
-
create
public static HttpClient create(Logger log)
-
send
public boolean send(HttpRequest request, CompletionListener completionListener) throws java.io.IOException
- Specified by:
sendin interfaceHttpClient- Throws:
java.io.IOException
-
send
public boolean send(HttpRequest request, HttpRequest.Config config, CompletionListener completionListener) throws java.io.IOException
- Specified by:
sendin interfaceHttpClient- Throws:
java.io.IOException
-
doHandleResponse
private java.lang.Boolean doHandleResponse(CompletionListener completionListener, org.apache.http.HttpResponse response) throws java.io.IOException
- Throws:
java.io.IOException
-
toApacheRequest
static org.apache.http.client.methods.HttpUriRequest toApacheRequest(HttpRequest request, HttpRequest.Config config)
-
-