@Test public void test500(){ StringHttpClient http = new StringHttpClient(new StatusCodeReplyHttpAsyncEngine()); try{ http.request(Requests.get("500")).await(); }catch (HttpException ex){ assertEquals(500, ex.getStatusCode()); }catch (Exception ex){ fail("An HttpException exception should have been thrown"); } }
public Future<HttpResponse<T>> request(final HttpRequest.Builder request) { return this.request(request.build()); }
BaseHttpClient { public Future<HttpResponse<T>> request(final HttpRequest.Builder request) { return this.request(request.build()); } }
BaseHttpClient { public Future<HttpResponse<T>> request(final HttpRequest.Builder request) { return this.request(request.build()); } BaseHttpClient(HttpAsyncEngine engine); }
BaseHttpClient { public Future<HttpResponse<T>> request(final HttpRequest.Builder request) { return this.request(request.build()); } BaseHttpClient(HttpAsyncEngine engine); void addDefaultHeader(String key, String value); Future<HttpResponse<T>> request(final HttpRequest.Builder request); Future<HttpResponse<T>> request(final HttpRequest request); }
BaseHttpClient { public Future<HttpResponse<T>> request(final HttpRequest.Builder request) { return this.request(request.build()); } BaseHttpClient(HttpAsyncEngine engine); void addDefaultHeader(String key, String value); Future<HttpResponse<T>> request(final HttpRequest.Builder request); Future<HttpResponse<T>> request(final HttpRequest request);  }