public class MockServerHttpResponse extends Object implements org.springframework.http.server.reactive.ServerHttpResponse
ServerHttpResponse
.Constructor and Description |
---|
MockServerHttpResponse() |
Modifier and Type | Method and Description |
---|---|
void |
beforeCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> action) |
org.springframework.core.io.buffer.DataBufferFactory |
bufferFactory() |
org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer> |
getBody() |
org.reactivestreams.Publisher<org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer>> |
getBodyWithFlush() |
org.springframework.util.MultiValueMap<String,org.springframework.http.ResponseCookie> |
getCookies() |
org.springframework.http.HttpHeaders |
getHeaders() |
org.springframework.http.HttpStatus |
getStatusCode() |
reactor.core.publisher.Mono<Void> |
setComplete() |
boolean |
setStatusCode(org.springframework.http.HttpStatus status) |
reactor.core.publisher.Mono<Void> |
writeAndFlushWith(org.reactivestreams.Publisher<org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer>> body) |
reactor.core.publisher.Mono<Void> |
writeWith(org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer> body) |
public boolean setStatusCode(org.springframework.http.HttpStatus status)
setStatusCode
in interface org.springframework.http.server.reactive.ServerHttpResponse
public org.springframework.http.HttpStatus getStatusCode()
getStatusCode
in interface org.springframework.http.server.reactive.ServerHttpResponse
public org.springframework.http.HttpHeaders getHeaders()
getHeaders
in interface org.springframework.http.HttpMessage
public org.springframework.util.MultiValueMap<String,org.springframework.http.ResponseCookie> getCookies()
getCookies
in interface org.springframework.http.server.reactive.ServerHttpResponse
public org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer> getBody()
public org.reactivestreams.Publisher<org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer>> getBodyWithFlush()
public reactor.core.publisher.Mono<Void> writeWith(org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer> body)
writeWith
in interface org.springframework.http.ReactiveHttpOutputMessage
public reactor.core.publisher.Mono<Void> writeAndFlushWith(org.reactivestreams.Publisher<org.reactivestreams.Publisher<org.springframework.core.io.buffer.DataBuffer>> body)
writeAndFlushWith
in interface org.springframework.http.ReactiveHttpOutputMessage
public void beforeCommit(Supplier<? extends reactor.core.publisher.Mono<Void>> action)
beforeCommit
in interface org.springframework.http.ReactiveHttpOutputMessage
public reactor.core.publisher.Mono<Void> setComplete()
setComplete
in interface org.springframework.http.ReactiveHttpOutputMessage
setComplete
in interface org.springframework.http.server.reactive.ServerHttpResponse
public org.springframework.core.io.buffer.DataBufferFactory bufferFactory()
bufferFactory
in interface org.springframework.http.ReactiveHttpOutputMessage