|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface RequestCallback
Callback interface for code that operates on a ClientHttpRequest. Allows to manipulate the request
headers, and write to the request body.
Used internally by the RestTemplate, but also useful for application code.
RestTemplate.execute(java.lang.String, org.springframework.http.HttpMethod, org.springframework.web.client.RequestCallback, org.springframework.web.client.ResponseExtractor, java.lang.Object...) | Method Summary | |
|---|---|
void |
doWithRequest(ClientHttpRequest request)
Gets called by RestTemplate.execute(java.lang.String, org.springframework.http.HttpMethod, org.springframework.web.client.RequestCallback, org.springframework.web.client.ResponseExtractor with an opened ClientHttpRequest. |
| Method Detail |
|---|
void doWithRequest(ClientHttpRequest request)
throws IOException
RestTemplate.execute(java.lang.String, org.springframework.http.HttpMethod, org.springframework.web.client.RequestCallback, org.springframework.web.client.ResponseExtractor, java.lang.Object...) with an opened ClientHttpRequest.
Does not need to care about closing the request or about handling errors:
this will all be handled by the RestTemplate.
request - the active HTTP request
IOException - in case of I/O errors
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||