Package | Description |
---|---|
org.springframework.web.reactive.function.server |
Provides the types that make up Spring's functional web framework for Reactive environments.
|
Modifier and Type | Method and Description |
---|---|
EntityResponse.Builder<T> |
EntityResponse.Builder.allow(HttpMethod... allowedMethods)
Set the set of allowed
HTTP methods , as specified
by the Allow header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.allow(Set<HttpMethod> allowedMethods)
Set the set of allowed
HTTP methods , as specified
by the Allow header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.cacheControl(CacheControl cacheControl)
Set the caching directives for the resource, as specified by the HTTP 1.1
Cache-Control header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.contentLength(long contentLength)
Set the length of the body in bytes, as specified by the
Content-Length header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.contentType(MediaType contentType)
Set the media type of the body, as specified by the
Content-Type header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.cookie(ResponseCookie cookie)
Add the given cookie to the response.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.cookies(Consumer<MultiValueMap<String,ResponseCookie>> cookiesConsumer)
Manipulate this response's cookies with the given consumer.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.eTag(String etag)
Set the entity tag of the body, as specified by the
ETag header. |
static <T> EntityResponse.Builder<T> |
EntityResponse.fromObject(T body)
Create a builder with the given object.
|
static <T> EntityResponse.Builder<T> |
EntityResponse.fromProducer(T producer,
Class<?> elementClass)
Create a builder with the given producer.
|
static <T> EntityResponse.Builder<T> |
EntityResponse.fromProducer(T producer,
ParameterizedTypeReference<?> typeReference)
Create a builder with the given producer.
|
static <T,P extends Publisher<T>> |
EntityResponse.fromPublisher(P publisher,
Class<T> elementClass)
Create a builder with the given publisher.
|
static <T,P extends Publisher<T>> |
EntityResponse.fromPublisher(P publisher,
ParameterizedTypeReference<T> typeReference)
Create a builder with the given publisher.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.header(String headerName,
String... headerValues)
Add the given header value(s) under the given name.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.headers(HttpHeaders headers)
Copy the given headers into the entity's headers map.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.hint(String key,
Object value)
Add a serialization hint like
Jackson2CodecSupport.JSON_VIEW_HINT to
customize how the body will be serialized. |
EntityResponse.Builder<T> |
EntityResponse.Builder.hints(Consumer<Map<String,Object>> hintsConsumer)
Customize the serialization hints with the given consumer.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.lastModified(Instant lastModified)
Set the time the resource was last changed, as specified by the
Last-Modified header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.lastModified(ZonedDateTime lastModified)
Set the time the resource was last changed, as specified by the
Last-Modified header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.location(URI location)
Set the location of a resource, as specified by the
Location header. |
EntityResponse.Builder<T> |
EntityResponse.Builder.status(HttpStatus status)
Set the HTTP status.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.status(int status)
Set the HTTP status.
|
EntityResponse.Builder<T> |
EntityResponse.Builder.varyBy(String... requestHeaders)
Configure one or more request header names (e.g.
|