public class HttpHeadResponseDecorator extends ServerHttpResponseDecorator
ServerHttpResponse
decorator for HTTP HEAD requests.Constructor and Description |
---|
HttpHeadResponseDecorator(ServerHttpResponse delegate) |
Modifier and Type | Method and Description |
---|---|
reactor.core.publisher.Mono<Void> |
writeAndFlushWith(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends DataBuffer>> body)
Invoke
ServerHttpResponseDecorator.setComplete() without writing. |
reactor.core.publisher.Mono<Void> |
writeWith(org.reactivestreams.Publisher<? extends DataBuffer> body)
Apply
reduce on the body, count
the number of bytes produced, release data buffers without writing, and
set the Content-Length header. |
addCookie, beforeCommit, bufferFactory, getCookies, getDelegate, getHeaders, getStatusCode, isCommitted, setComplete, setStatusCode, toString
public HttpHeadResponseDecorator(ServerHttpResponse delegate)
public final reactor.core.publisher.Mono<Void> writeWith(org.reactivestreams.Publisher<? extends DataBuffer> body)
reduce
on the body, count
the number of bytes produced, release data buffers without writing, and
set the Content-Length header.writeWith
in interface ReactiveHttpOutputMessage
writeWith
in class ServerHttpResponseDecorator
body
- the body content publisherMono
that indicates completion or errorpublic final reactor.core.publisher.Mono<Void> writeAndFlushWith(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends DataBuffer>> body)
ServerHttpResponseDecorator.setComplete()
without writing.
RFC 7302 allows HTTP HEAD response without content-length and it's not something that can be computed on a streaming response.
writeAndFlushWith
in interface ReactiveHttpOutputMessage
writeAndFlushWith
in class ServerHttpResponseDecorator
body
- the body content publisherMono
that indicates completion or error