| Modifier and Type | Class and Description |
|---|---|
| private static class | HttpClientImpl.
A weak ref to the client so it can be finalized. |
| Modifier and Type | Field and Description |
|---|---|
| private static final Pattern | |
| private volatile Handler | |
| private static final Function | |
| private static final Consumer | |
| private final ConnectionManager | |
| private final PoolOptions | |
| private volatile Function | |
| private long |
| Access | Constructor and Description |
|---|---|
| public | HttpClientImpl(VertxInternal vertx, HttpClientOptions options, PoolOptions poolOptions, CloseFuture closeFuture)
|
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| private void | |
| public void | close(Promise<Void>
the promise to signal when close has completed completion)Overrides io. Implements io. Close this resource, the |
| public Future | connect(SocketAddress
the server address server)Overrides default io. Connect to a server. |
| public Future | connect(SocketAddress
the server address server, SocketAddress the peer peer)Implements io. Connect to a server. |
| public HttpClient | connectionHandler(Handler<HttpConnection> handler)
Implements io. Set a connection handler for the client. |
| public Handler | |
| pack-priv Future | |
| private HttpClientRequest | |
| private void | |
| private void | doRequest(HttpMethod method, SocketAddress server, String host, int port, Boolean useSSL, String requestURI, MultiMap headers, String traceOperation, long connectTimeout, long idleTimeout, Boolean followRedirects, ProxyOptions proxyOptions, EndpointKey key, PromiseInternal<HttpClientRequest> requestPromise)
|
| private ConnectionManager | |
| public NetClient | |
| private static SocketAddress | |
| public HttpClient | redirectHandler(Function<HttpClientResponse, Future<RequestOptions>>
the new redirect handler handler)Implements io. Set a redirect handler for the http client. |
| public Function | |
| public void | request(RequestOptions
the request options options, Handler<AsyncResult<HttpClientRequest>> the handler called when the request is ready to be sent handler)Implements io. Create an HTTP request to send to the server. |
| public Future | request(RequestOptions options)
Implements io. Like |
| public void | request(HttpMethod
the HTTP method method, int the port port, String the host host, String the relative URI requestURI, Handler<AsyncResult<HttpClientRequest>> the handler called when the request is ready to be sent handler)Implements io. Create an HTTP request to send to the server at the |
| public Future | request(HttpMethod method, int port, String host, String requestURI)
Overrides default io. Like |
| public void | request(HttpMethod
the HTTP method method, String the host host, String the relative URI requestURI, Handler<AsyncResult<HttpClientRequest>> the handler called when the request is ready to be sent handler)Implements io. Create an HTTP request to send to the server at the |
| public Future | request(HttpMethod method, String host, String requestURI)
Overrides default io. Like |
| public void | request(HttpMethod
the HTTP method method, String the relative URI requestURI, Handler<AsyncResult<HttpClientRequest>> the handler called when the request is ready to be sent handler)Implements io. Create an HTTP request to send to the server at the default host and port. |
| public Future | request(HttpMethod method, String requestURI)
Overrides default io. Like |
| ABS_URI_START_PATTERN | back to summary |
|---|---|
| private static final Pattern ABS_URI_START_PATTERN | |
| connectionHandler | back to summary |
|---|---|
| private volatile Handler<HttpConnection> connectionHandler | |
| DEFAULT_HANDLER | back to summary |
|---|---|
| private static final Function<HttpClientResponse, Future<RequestOptions>> DEFAULT_HANDLER | |
| EXPIRED_CHECKER | back to summary |
|---|---|
| private static final Consumer<Endpoint<Lease<HttpClientConnection>>> EXPIRED_CHECKER | |
| httpCM | back to summary |
|---|---|
| private final ConnectionManager<EndpointKey, Lease<HttpClientConnection>> httpCM | |
| poolOptions | back to summary |
|---|---|
| private final PoolOptions poolOptions | |
| redirectHandler | back to summary |
|---|---|
| private volatile Function<HttpClientResponse, Future<RequestOptions>> redirectHandler | |
| timerID | back to summary |
|---|---|
| private long timerID | |
| HttpClientImpl | back to summary |
|---|---|
| public HttpClientImpl(VertxInternal vertx, HttpClientOptions options, PoolOptions poolOptions, CloseFuture closeFuture) | |
| checkClosed | back to summary |
|---|---|
| private void checkClosed() | |
| checkExpired | back to summary |
|---|---|
| private void checkExpired(Handler<Long> checker) | |
| close | back to summary |
|---|---|
| public void close(Promise<Void> completion) Overrides io. Implements io. Doc from io. Close this resource, the | |
| connect | back to summary |
|---|---|
| public Future Overrides default io. Connect to a server.
| |
| connect | back to summary |
|---|---|
| public Future Implements io. Connect to a server.
| |
| connectionHandler | back to summary |
|---|---|
| public HttpClient connectionHandler(Handler<HttpConnection> handler) Implements io. Doc from io. Set a connection handler for the client. This handler is called when a new connection is established.
| |
| connectionHandler | back to summary |
|---|---|
| public Handler | |
| createRequest | back to summary |
|---|---|
| pack-priv Future | |
| createRequest | back to summary |
|---|---|
| private HttpClientRequest createRequest(HttpClientStream stream) | |
| doRequest | back to summary |
|---|---|
| private void doRequest(RequestOptions request, PromiseInternal<HttpClientRequest> promise) | |
| doRequest | back to summary |
|---|---|
| private void doRequest(HttpMethod method, SocketAddress server, String host, int port, Boolean useSSL, String requestURI, MultiMap headers, String traceOperation, long connectTimeout, long idleTimeout, Boolean followRedirects, ProxyOptions proxyOptions, EndpointKey key, PromiseInternal<HttpClientRequest> requestPromise) | |
| httpConnectionManager | back to summary |
|---|---|
| private ConnectionManager | |
| netClient | back to summary |
|---|---|
| public NetClient netClient() | |
| peerAddress | back to summary |
|---|---|
| private static SocketAddress peerAddress(SocketAddress remoteAddress, final String peerHost, int peerPort) | |
| redirectHandler | back to summary |
|---|---|
| public HttpClient redirectHandler(Function<HttpClientResponse, Future<RequestOptions>> handler) Implements io. Doc from io. Set a redirect handler for the http client.
The redirect handler is called when a
The redirect handler is passed the
The handler must return a
| |
| redirectHandler | back to summary |
|---|---|
| public Function Implements io.
| |
| request | back to summary |
|---|---|
| public void request(RequestOptions options, Handler<AsyncResult<HttpClientRequest>> handler) Implements io. Doc from io. Create an HTTP request to send to the server. The
| |
| request | back to summary |
|---|---|
| public Future Implements io. Doc from io. Like
| |
| request | back to summary |
|---|---|
| public void request(HttpMethod method, int port, String host, String requestURI, Handler<AsyncResult<HttpClientRequest>> handler) Implements io. Doc from io. Create an HTTP request to send to the server at the
| |
| request | back to summary |
|---|---|
| public Future Overrides default io. Doc from io. Like
| |
| request | back to summary |
|---|---|
| public void request(HttpMethod method, String host, String requestURI, Handler<AsyncResult<HttpClientRequest>> handler) Implements io. Doc from io. Create an HTTP request to send to the server at the
| |
| request | back to summary |
|---|---|
| public Future Overrides default io. Doc from io. Like
| |
| request | back to summary |
|---|---|
| public void request(HttpMethod method, String requestURI, Handler<AsyncResult<HttpClientRequest>> handler) Implements io. Doc from io. Create an HTTP request to send to the server at the default host and port. The
| |
| request | back to summary |
|---|---|
| public Future Overrides default io. Doc from io. Like
| |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final WeakReference |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | handle(Long
the event to handle event)Implements io. Something has happened, so handle it. |
| ref | back to summary |
|---|---|
| pack-priv final WeakReference<HttpClientImpl> ref | |
| PoolChecker | back to summary |
|---|---|
| private PoolChecker(HttpClientImpl client) | |
| handle | back to summary |
|---|---|
| public void handle(Long event) Implements io. Doc from io. Something has happened, so handle it. | |