Make HttpRequestImpl properties readable
@@ -32,7 +32,6 @@ import io.vertx.ext.web.client.WebClientOptions;
import io.vertx.ext.web.client.predicate.ResponsePredicate;
import io.vertx.ext.web.codec.BodyCodec;
import io.vertx.ext.web.multipart.MultipartForm;
-import io.vertx.ext.web.multipart.impl.MultipartFormImpl;
import java.util.ArrayList;
import java.util.Base64;
@@ -115,6 +114,10 @@ public class HttpRequestImpl<T> implements HttpRequest<T> {
return this;
}
+ public HttpMethod method() {
+ return method;
+ }
+
@Override
public HttpRequest<T> rawMethod(String method) {
rawMethod = method;
@@ -122,24 +125,40 @@ public class HttpRequestImpl<T> implements HttpRequest<T> {
return this;
}
+ public String rawMethod() {
+ return rawMethod;
+ }
+
@Override
public HttpRequest<T> port(int value) {
port = value;
return this;
}
+ public int port() {
+ return port;
+ }
+
@Override
public HttpRequest<T> host(String value) {
host = value;
return this;
}
+ public String host() {
+ return host;
+ }
+
@Override
public HttpRequest<T> virtualHost(String value) {
virtualHost = value;
return this;
}
+ public String virtualHost() {
+ return virtualHost;
+ }
+
@Override
public HttpRequest<T> uri(String value) {
params = null;
@@ -147,6 +166,10 @@ public class HttpRequestImpl<T> implements HttpRequest<T> {
return this;
}
+ public String uri() {
+ return uri;
+ }
+
@Override
public HttpRequest<T> putHeaders(MultiMap headers) {
headers().addAll(headers);
@@ -190,12 +213,20 @@ public class HttpRequestImpl<T> implements HttpRequest<T> {
return this;
}
+ public Boolean ssl() {
+ return ssl;
+ }
+
@Override
public HttpRequest<T> timeout(long value) {
timeout = value;
return this;
}
+ public long timeout() {
+ return timeout;
+ }
+
@Override
public HttpRequest<T> addQueryParam(String paramName, String paramValue) {
queryParams().add(paramName, paramValue);
@@ -214,6 +245,10 @@ public class HttpRequestImpl<T> implements HttpRequest<T> {
return this;
}
+ public boolean followRedirects() {
+ return followRedirects;
+ }
+
@Override
public HttpRequest<T> expect(ResponsePredicate expectation) {
if (expectations == null) {
