public abstract class AbstractClientHttpRequest extends Object implements ClientHttpRequest
ClientHttpRequest implementations.| Constructor and Description |
|---|
AbstractClientHttpRequest() |
AbstractClientHttpRequest(HttpHeaders headers) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
applyCookies()
Implement this method to add cookies from
getHeaders() to the
underlying response. |
protected abstract void |
applyHeaders()
Implement this method to apply header changes from
getHeaders()
to the underlying response. |
void |
beforeCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> action)
Register an action to be applied just before the message is committed.
|
protected reactor.core.publisher.Mono<Void> |
doCommit()
A variant of
doCommit(Supplier) for a request without body. |
protected reactor.core.publisher.Mono<Void> |
doCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> writeAction)
Apply
beforeCommit actions, apply the
request headers/cookies, and write the request body. |
org.springframework.util.MultiValueMap<String,HttpCookie> |
getCookies()
Return a mutable map of request cookies to send to the server.
|
HttpHeaders |
getHeaders()
Return the headers of this message.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetMethod, getURIbufferFactory, setComplete, writeAndFlushWith, writeWithpublic AbstractClientHttpRequest()
public AbstractClientHttpRequest(HttpHeaders headers)
public HttpHeaders getHeaders()
HttpMessagegetHeaders in interface HttpMessagenull)public org.springframework.util.MultiValueMap<String,HttpCookie> getCookies()
ClientHttpRequestgetCookies in interface ClientHttpRequestprotected reactor.core.publisher.Mono<Void> doCommit()
doCommit(Supplier) for a request without body.protected reactor.core.publisher.Mono<Void> doCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> writeAction)
beforeCommit actions, apply the
request headers/cookies, and write the request body.writeAction - the action to write the request body or nullpublic void beforeCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> action)
ReactiveHttpOutputMessagebeforeCommit in interface ReactiveHttpOutputMessageaction - the actionprotected abstract void applyHeaders()
getHeaders()
to the underlying response. This method is called once only.protected abstract void applyCookies()
getHeaders() to the
underlying response. This method is called once only.