List of usage examples for io.vertx.core.http HttpVersion HTTP_1_0
HttpVersion HTTP_1_0
To view the source code for io.vertx.core.http HttpVersion HTTP_1_0.
Click Source Link
From source file:io.apiman.gateway.platforms.vertx3.http.HttpApiFactory.java
License:Apache License
public static void buildResponse(HttpServerResponse httpServerResponse, ApiResponse amanResponse, HttpVersion httpVersion) {/*w w w . ja v a2 s . c o m*/ amanResponse.getHeaders().forEach(e -> { if (httpVersion == HttpVersion.HTTP_1_0 || httpVersion == HttpVersion.HTTP_1_1 || !e.getKey().equals("Connection")) { httpServerResponse.headers().add(e.getKey(), e.getValue()); } }); httpServerResponse.setStatusCode(amanResponse.getCode()); httpServerResponse.setStatusMessage(amanResponse.getMessage()); }