接口 AsyncRequestCallback
- 函数接口:
- 这是一个函数接口, 因此可用作 lambda 表达式或方法引用的赋值目标。
@FunctionalInterface @Deprecated public interface AsyncRequestCallback
已过时。as of Spring 5.0, in favor ofExchangeFilterFunctionCallback interface for code that operates on anAsyncClientHttpRequest. Allows to manipulate the request headers, and write to the request body.Used internally by the
AsyncRestTemplate, but also useful for application code.
方法概要
所有方法 实例方法 抽象方法 已过时的方法 修饰符和类型 方法 说明 voiddoWithRequest(AsyncClientHttpRequest request)已过时。
方法详细资料
doWithRequest
void doWithRequest(AsyncClientHttpRequest request) throws IOException
已过时。Gets called byAsyncRestTemplate.execute(java.lang.String, org.springframework.http.HttpMethod, org.springframework.web.client.AsyncRequestCallback, org.springframework.web.client.ResponseExtractor<T>, java.lang.Object...)with an openedClientHttpRequest. Does not need to care about closing the request or about handling errors: this will all be handled by theRestTemplate.- 参数:
request- the active HTTP request- 抛出:
IOException- in case of I/O errors