接口 HandlerFilterFunction<T extends ServerResponse,​R extends ServerResponse>

    • 方法详细资料

      • filter

        reactor.core.publisher.Mono<Rfilter​(ServerRequest request,
                                              HandlerFunction<T> next)
        Apply this filter to the given handler function. The given handler function represents the next entity in the chain, and can be invoked in order to proceed to this entity, or not invoked to block the chain.
        参数:
        request - the request
        next - the next handler or filter function in the chain
        返回:
        the filtered response
        另请参阅:
        ServerRequestWrapper
      • andThen

        default HandlerFilterFunction<T,​RandThen​(HandlerFilterFunction<T,​T> after)
        Return a composed filter function that first applies this filter, and then applies the after filter.
        参数:
        after - the filter to apply after this filter is applied
        返回:
        a composed filter that first applies this function and then applies the after function
      • apply

        default HandlerFunction<Rapply​(HandlerFunction<T> handler)
        Apply this filter to the given handler function, resulting in a filtered handler function.
        参数:
        handler - the handler function to filter
        返回:
        the filtered handler function
      • ofRequestProcessor

        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 ServerRequest.
        参数:
        requestProcessor - the request processor
        返回:
        the filter adaptation of the request processor
      • ofResponseProcessor

        static <T extends ServerResponse,​R extends ServerResponseHandlerFilterFunction<T,​R> ofResponseProcessor​(Function<T,​reactor.core.publisher.Mono<R>> responseProcessor)
        Adapt the given response processor function to a filter function that only operates on the ServerResponse.
        参数:
        responseProcessor - the response processor
        返回:
        the filter adaptation of the request processor