Class HttpRequest


  • public class HttpRequest
    extends Object
    Represents a "disconnected" request, i.e. containing the full payload.
    Author:
    https://github.com/lbovet [Laurent Bovet]
    • Constructor Detail

      • HttpRequest

        public HttpRequest​(io.vertx.core.http.HttpMethod method,
                           String uri,
                           io.vertx.core.MultiMap headers,
                           byte[] payload)
      • HttpRequest

        public HttpRequest​(io.vertx.core.json.JsonObject object)
        Parameters:
        object - object
        Throws:
        IllegalArgumentException - When passed in JSON is not in expected format.
        ClassCastException - IMO, this should be a IllegalArgumentException. Because this happens when impl tries to cast something we got from passed in JSON.
    • Method Detail

      • toJsonObject

        public io.vertx.core.json.JsonObject toJsonObject()
      • getMethod

        public io.vertx.core.http.HttpMethod getMethod()
      • getUri

        public String getUri()
      • getPayload

        public byte[] getPayload()
      • getHeaders

        public io.vertx.core.MultiMap getHeaders()
      • setHeaders

        public void setHeaders​(io.vertx.core.MultiMap headers)