diff --git a/src/main/java/com/synopsys/integration/rest/request/Request.java b/src/main/java/com/synopsys/integration/rest/request/Request.java index a6fe5f6..0738110 100644 --- a/src/main/java/com/synopsys/integration/rest/request/Request.java +++ b/src/main/java/com/synopsys/integration/rest/request/Request.java @@ -26,16 +26,14 @@ public class Request extends Stringable implements Buildable { private final HttpUrl url; private final HttpMethod method; - private final String acceptMimeType; private final Charset bodyEncoding; private final Map> queryParameters = new HashMap<>(); private final Map headers = new HashMap<>(); private final BodyContent bodyContent; - public Request(HttpUrl url, HttpMethod method, String acceptMimeType, Charset bodyEncoding, Map> queryParameters, Map headers, BodyContent bodyContent) { + public Request(HttpUrl url, HttpMethod method, Charset bodyEncoding, Map> queryParameters, Map headers, BodyContent bodyContent) { this.url = url; this.method = method; - this.acceptMimeType = acceptMimeType; this.bodyEncoding = null == bodyEncoding ? StandardCharsets.UTF_8 : bodyEncoding; this.queryParameters.putAll(queryParameters); this.headers.putAll(headers); @@ -43,7 +41,7 @@ public Request(HttpUrl url, HttpMethod method, String acceptMimeType, Charset bo } public Request(Builder builder) { - this(builder.url, builder.method, builder.acceptMimeType, builder.bodyEncoding, builder.queryParameters, builder.headers, builder.bodyContent); + this(builder.url, builder.method, builder.bodyEncoding, builder.queryParameters, builder.headers, builder.bodyContent); } public Request.Builder createBuilder() { @@ -62,10 +60,6 @@ public HttpMethod getMethod() { return method; } - public String getAcceptMimeType() { - return acceptMimeType; - } - public Charset getBodyEncoding() { return bodyEncoding; } @@ -85,7 +79,6 @@ public BodyContent getBodyContent() { public static class Builder extends IntegrationBuilder { private HttpUrl url; private HttpMethod method; - private String acceptMimeType; private Charset bodyEncoding; private Map> queryParameters = new HashMap<>(); private Map headers = new HashMap<>(); @@ -94,7 +87,6 @@ public static class Builder extends IntegrationBuilder { public Builder(Request request) { url = request.url; method = request.method; - acceptMimeType = request.acceptMimeType; bodyEncoding = request.bodyEncoding; queryParameters.putAll(request.queryParameters); headers.putAll(request.headers); @@ -104,7 +96,6 @@ public Builder(Request request) { public Builder(Builder builder) { url = builder.url; method = builder.method; - acceptMimeType = builder.acceptMimeType; bodyEncoding = builder.bodyEncoding; queryParameters.putAll(builder.queryParameters); headers.putAll(builder.headers); @@ -135,7 +126,6 @@ protected Request buildWithoutValidation() { return new Request( getUrl(), getMethod(), - getAcceptMimeType(), getBodyEncoding(), getQueryParameters(), getHeaders(), @@ -157,11 +147,6 @@ public Builder method(HttpMethod method) { return this; } - public Builder acceptMimeType(String acceptMimeType) { - this.acceptMimeType = acceptMimeType; - return this; - } - public Builder bodyEncoding(Charset bodyEncoding) { this.bodyEncoding = bodyEncoding; return this; @@ -205,10 +190,6 @@ public HttpMethod getMethod() { return method; } - public String getAcceptMimeType() { - return acceptMimeType; - } - public Charset getBodyEncoding() { return bodyEncoding; }