T - the type of the handler function to filterR - the type of the response of the function@FunctionalInterface public interface HandlerFilterFunction<T extends ServerResponse,R extends ServerResponse>
RouterFunction.filter(HandlerFilterFunction)| Modifier and Type | Method and Description |
|---|---|
default HandlerFilterFunction<T,R> |
andThen(HandlerFilterFunction<T,T> after)
Return a composed filter function that first applies this filter, and then applies the
after filter. |
default HandlerFunction<R> |
apply(HandlerFunction<T> handler)
Apply this filter to the given handler function, resulting in a filtered handler function.
|
reactor.core.publisher.Mono<R> |
filter(ServerRequest request,
HandlerFunction<T> next)
Apply this filter to the given handler function.
|
static HandlerFilterFunction<?,?> |
ofRequestProcessor(Function<ServerRequest,reactor.core.publisher.Mono<ServerRequest>> requestProcessor)
Adapt the given request processor function to a filter function that only operates
on the
ClientRequest. |
static <T extends ServerResponse,R extends ServerResponse> |
ofResponseProcessor(Function<T,reactor.core.publisher.Mono<R>> responseProcessor)
Adapt the given response processor function to a filter function that only operates
on the
ClientResponse. |
reactor.core.publisher.Mono<R> filter(ServerRequest request, HandlerFunction<T> next)
request - the requestnext - the next handler or filter function in the chainServerRequestWrapperdefault HandlerFilterFunction<T,R> andThen(HandlerFilterFunction<T,T> after)
after filter.after - the filter to apply after this filter is appliedafter functiondefault HandlerFunction<R> apply(HandlerFunction<T> handler)
handler - the handler function to filterstatic HandlerFilterFunction<?,?> ofRequestProcessor(Function<ServerRequest,reactor.core.publisher.Mono<ServerRequest>> requestProcessor)
ClientRequest.requestProcessor - the request processorstatic <T extends ServerResponse,R extends ServerResponse> HandlerFilterFunction<T,R> ofResponseProcessor(Function<T,reactor.core.publisher.Mono<R>> responseProcessor)
ClientResponse.responseProcessor - the response processor