org.fishwife.jrugged.httpclient
Class ServiceWrappedHttpClient
java.lang.Object
org.fishwife.jrugged.httpclient.AbstractHttpClientDecorator
org.fishwife.jrugged.httpclient.ServiceWrappedHttpClient
- All Implemented Interfaces:
- org.apache.http.client.HttpClient
public class ServiceWrappedHttpClient
- extends AbstractHttpClientDecorator
Facade class for assembling an HttpClient that will feed request
executions through a ServiceWrapper, while exposing 4XX and 5XX
responses as exceptions so that the ServiceWrapper can experience them
as failures, but unwrapping those exceptions before getting up to
the original caller.
|
Method Summary |
org.apache.http.HttpResponse |
execute(org.apache.http.HttpHost host,
org.apache.http.HttpRequest req,
org.apache.http.protocol.HttpContext ctx)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ServiceWrappedHttpClient
public ServiceWrappedHttpClient(org.apache.http.client.HttpClient backend,
ServiceWrapper wrapper)
ServiceWrappedHttpClient
public ServiceWrappedHttpClient(org.apache.http.client.HttpClient backend,
ServiceWrapper wrapper,
ResponseFailureAssessor assessor)
execute
public org.apache.http.HttpResponse execute(org.apache.http.HttpHost host,
org.apache.http.HttpRequest req,
org.apache.http.protocol.HttpContext ctx)
throws IOException,
org.apache.http.client.ClientProtocolException
- Specified by:
execute in interface org.apache.http.client.HttpClient- Specified by:
execute in class AbstractHttpClientDecorator
- Throws:
IOException
org.apache.http.client.ClientProtocolException
Copyright © 2013. All Rights Reserved.