ExchangeFilterFunction を推奨 @FunctionalInterfaceSE @DeprecatedSE public interface AsyncRequestCallback
AsyncClientHttpRequest で動作するコードのコールバックインターフェース。リクエストヘッダーを操作し、リクエストの本文に書き込むことができます。AsyncRestTemplate によって内部的に使用されますが、アプリケーションコードにも役立ちます。
| 修飾子と型 | メソッドと説明 |
|---|---|
void | doWithRequest(AsyncClientHttpRequest request) 使用すべきではありません。 |
void doWithRequest(AsyncClientHttpRequest request) throws IOExceptionSE
AsyncRestTemplate.execute(java.lang.String, org.springframework.http.HttpMethod, org.springframework.web.client.AsyncRequestCallback, org.springframework.web.client.ResponseExtractor<T>, java.lang.Object...) を開いて ClientHttpRequest を呼び出します。リクエストのクローズやエラーの処理について気にする必要はありません: これはすべて RestTemplate によって処理されます。request - アクティブな HTTP リクエスト IOExceptionSE - I/O エラーの場合