Classes, interfaces and traits

HttpResponse

An HTTP response.

The usual HTTP response attributes are available:

  • @see \io\vertx\jphp\ext\web\client\HttpResponse::statusCode the HTTP status code
  • @see \io\vertx\jphp\ext\web\client\HttpResponse::statusMessage the HTTP status message
  • @see \io\vertx\jphp\ext\web\client\HttpResponse::headers the HTTP headers
  • @see \io\vertx\jphp\ext\web\client\HttpResponse::version the HTTP version

The body of the response is returned by @see \io\vertx\jphp\ext\web\client\HttpResponse::body decoded as the format specified by the @see \io\vertx\jphp\ext\web\codec\BodyCodec that built the response.

Keep in mind that using this HttpResponse impose to fully buffer the response body and should be used for payload that can fit in memory.

« More »

WebClient

An asynchronous HTTP / HTTP/2 client called <code>WebClient</code>.

The web client makes easy to do HTTP request/response interactions with a web server, and provides advanced features like:

  • Json body encoding / decoding
  • request/response pumping
  • error handling

The web client does not deprecate the , it is actually based on it and therefore inherits its configuration and great features like pooling. The HttpClient should be used when fine grained control over the HTTP requests/response is necessary.

« More »

WebClientOptions

Options describing how an @see \io\vertx\jphp\core\http\HttpClient will make connections.

« More »

Classes, interfaces and traits

ErrorConverter

Converts a @see \io\vertx\jphp\ext\web\client\predicate\ResponsePredicateResult to a <code>Throwable</code> describing the error.

« More »

ResponsePredicate

A predicate on .

By default, a Vert.x Web Client request ends with an error only if something wrong happens at the network level. In other words, a 404 Not Found response, or a response with the wrong content type, are NOT considered as failures.

« More »

ResponsePredicateResult

Represents the outcome of a @see \io\vertx\jphp\ext\web\client\predicate\ResponsePredicate applied to an .

« More »