Vert.x provides you with one of these via the handler that was provided when creating the io.
or that was set on the io. instance.
It implements io. so it can be used with
io. to pipe data with flow control.
| Modifier and Type | Method and Description |
|---|---|
| public default HttpClientResponse | body(Handler<AsyncResult<Buffer>> handler)
Same as |
| public Future | Returns: a future completed with the body resultConvenience method for receiving the entire request body in one piece. |
| public default HttpClientResponse | bodyHandler(Handler<Buffer>
This handler will be called after all the body has been received bodyHandler)Convenience method for receiving the entire request body in one piece. |
| public HttpClientResponse | Returns: a reference to this, so the API can be used fluentlySet an custom frame handler. |
| public default void | end(Handler<AsyncResult<Void>> handler)
Same as |
| public Future | Returns: a future completed with the body resultReturns a future signaling when the response has been fully received successfully or failed. |
| public HttpClientResponse | |
| public HttpClientResponse | |
| public HttpClientResponse | fetch(long amount)
Redeclares io. Fetch the specified |
| public @Nullable String | Returns: the trailer valuethe trailer name trailerName)Return the first trailer value with the specified name |
| public HttpClientResponse | |
| public NetSocket | |
| public HttpClientResponse | pause()
Redeclares io. Pause the |
| public HttpClientRequest | |
| public HttpClientResponse | resume()
Redeclares io. Resume reading, and sets the buffer in |
| public HttpClientResponse | streamPriorityHandler(Handler<StreamPriority>
the handler to be called when the stream priority changes handler)Set an handler for stream priority changes. |
| public MultiMap |
| body | back to summary |
|---|---|
| public default HttpClientResponse body(Handler<AsyncResult<Buffer>> handler) Same as
| |
| body | back to summary |
|---|---|
| public Future Convenience method for receiving the entire request body in one piece. This saves you having to manually set a dataHandler and an endHandler and append the chunks of the body until the whole body received. Don't use this if your request body is large - you could potentially run out of RAM. | |
| bodyHandler | back to summary |
|---|---|
| public default HttpClientResponse bodyHandler(Handler<Buffer> bodyHandler) Convenience method for receiving the entire request body in one piece. This saves you having to manually set a dataHandler and an endHandler and append the chunks of the body until the whole body received. Don't use this if your request body is large - you could potentially run out of RAM. | |
| customFrameHandler | back to summary |
|---|---|
| public HttpClientResponse customFrameHandler(Handler<HttpFrame> handler) Set an custom frame handler. The handler will get notified when the http stream receives an custom HTTP/2 frame. HTTP/2 permits extension of the protocol.
| |
| end | back to summary |
|---|---|
| public default void end(Handler<AsyncResult<Void>> handler) Same as | |
| end | back to summary |
|---|---|
| public Future Returns a future signaling when the response has been fully received successfully or failed. | |
| endHandler | back to summary |
|---|---|
public HttpClientResponse endHandler(Handler<Void> endHandler)
| |
| exceptionHandler | back to summary |
|---|---|
public HttpClientResponse exceptionHandler(Handler<Throwable> handler)
| |
| fetch | back to summary |
|---|---|
| public HttpClientResponse fetch(long amount) Redeclares io. Doc from io. Fetch the specified
| |
| getTrailer | back to summary |
|---|---|
| public @Nullable String getTrailer(String trailerName) Return the first trailer value with the specified name | |
| handler | back to summary |
|---|---|
public HttpClientResponse handler(Handler<Buffer> handler)
| |
| netSocket | back to summary |
|---|---|
public NetSocket netSocket()
| |
| pause | back to summary |
|---|---|
| public HttpClientResponse pause() Redeclares io. Doc from io. Pause the
While it's paused, no data will be sent to the data
| |
| request | back to summary |
|---|---|
public HttpClientRequest request()
| |
| resume | back to summary |
|---|---|
| public HttpClientResponse resume() Redeclares io. Doc from io. Resume reading, and sets the buffer in
If the
| |
| streamPriorityHandler | back to summary |
|---|---|
| public HttpClientResponse streamPriorityHandler(Handler<StreamPriority> handler) Set an handler for stream priority changes. This is not implemented for HTTP/1.x.
| |
| trailers | back to summary |
|---|---|
public MultiMap trailers()
| |