Improve Javadoc of ExchangeFunction

See gh-26577
This commit is contained in:
fengyuanwei
2021-02-20 15:58:03 +08:00
committed by Rossen Stoyanchev
parent 3ec0452fed
commit 962ec38a61

View File

@@ -25,11 +25,11 @@ import reactor.core.publisher.Mono;
* <p>For example:
* <pre class="code">
* ExchangeFunction exchangeFunction = ExchangeFunctions.create(new ReactorClientHttpConnector());
* ClientRequest&lt;Void&gt; request = ClientRequest.method(HttpMethod.GET, "https://example.com/resource").build();
* ClientRequest request = ClientRequest.create(HttpMethod.GET, URI.create("https://example.com/resource")).build();
*
* Mono&lt;String&gt; result = exchangeFunction
* .exchange(request)
* .then(response -> response.bodyToMono(String.class));
* .flatMap(response -> response.bodyToMono(String.class));
* </pre>
*
* @author Arjen Poutsma