private static HttpRequest updateAcceptEncoding(ClientRequestContext ctx, HttpRequest req,
                                                    @Nullable String acceptEncoding) {
        final RequestHeadersBuilder headersBuilder;
        if (acceptEncoding == null) {
            headersBuilder = req.headers().toBuilder()
                                .removeAndThen(HttpHeaderNames.ACCEPT_ENCODING);
        } else {
            headersBuilder = req.headers().toBuilder()
                                .set(HttpHeaderNames.ACCEPT_ENCODING, acceptEncoding);
        }

        final HttpRequest updated = req.withHeaders(headersBuilder);
        ctx.updateRequest(updated);
        return updated;
    }
Creates a new instance that decorates the specified {@link HttpClient} with the provided decoders.
core/src/main/java/com/linecorp/armeria/client/encoding/DecodingClient.java