接口的使用
org.springframework.web.reactive.function.server.ServerRequest
使用ServerRequest的程序包 程序包 说明 org.springframework.mock.web.reactive.function.server Mock objects for the functional web framework.org.springframework.web.reactive.function.server Provides the types that make up Spring's functional web framework for Reactive environments.org.springframework.web.reactive.function.server.support Classes supporting theorg.springframework.web.reactive.function.server
package.org.springframework.mock.web.reactive.function.server中ServerRequest的使用
实现ServerRequest的org.springframework.mock.web.reactive.function.server中的类 修饰符和类型 类 说明 class
MockServerRequest
Mock implementation ofServerRequest
.org.springframework.web.reactive.function.server中ServerRequest的使用
返回ServerRequest的org.springframework.web.reactive.function.server中的方法 修饰符和类型 方法 说明 ServerRequest
ServerRequest.Builder. build()
Build the request.static ServerRequest
ServerRequest. create(ServerWebExchange exchange, List<HttpMessageReader<?>> messageReaders)
Create a newServerRequest
based on the givenServerWebExchange
and message readers.返回变量类型为ServerRequest的类型的org.springframework.web.reactive.function.server中的方法 修饰符和类型 方法 说明 default Optional<ServerRequest>
RequestPredicate. nest(ServerRequest request)
Transform the given request into a request used for a nested route.static Function<ServerRequest,reactor.core.publisher.Mono<Resource>>
RouterFunctions. resourceLookupFunction(String pattern, Resource location)
Returns the resource lookup function used byRouterFunctions.resources(String, Resource)
.参数类型为ServerRequest的org.springframework.web.reactive.function.server中的方法 修饰符和类型 方法 说明 reactor.core.publisher.Mono<R>
HandlerFilterFunction. filter(ServerRequest request, HandlerFunction<T> next)
Apply this filter to the given handler function.static ServerRequest.Builder
ServerRequest. from(ServerRequest other)
Create a builder with the message readers, method name, URI, headers, cookies, and attributes of the given request.reactor.core.publisher.Mono<T>
HandlerFunction. handle(ServerRequest request)
Handle the given request.default Optional<ServerRequest>
RequestPredicate. nest(ServerRequest request)
Transform the given request into a request used for a nested route.reactor.core.publisher.Mono<HandlerFunction<T>>
RouterFunction. route(ServerRequest request)
Return the handler function that matches the given request.boolean
RequestPredicate. test(ServerRequest request)
Evaluate this predicate on the given request.类型变量类型为ServerRequest的org.springframework.web.reactive.function.server中的方法参数 修饰符和类型 方法 说明 RouterFunctions.Builder
RouterFunctions.Builder. after(BiFunction<ServerRequest,ServerResponse,ServerResponse> responseProcessor)
Filter the response object for all routes created by this builder with the given response processing function.RouterFunctions.Builder
RouterFunctions.Builder. before(Function<ServerRequest,ServerRequest> requestProcessor)
Filter the request object for all routes created by this builder with the given request processing function.RouterFunctions.Builder
RouterFunctions.Builder. before(Function<ServerRequest,ServerRequest> requestProcessor)
Filter the request object for all routes created by this builder with the given request processing function.static HandlerFilterFunction<?,?>
HandlerFilterFunction. ofRequestProcessor(Function<ServerRequest,reactor.core.publisher.Mono<ServerRequest>> requestProcessor)
Adapt the given request processor function to a filter function that only operates on theServerRequest
.static HandlerFilterFunction<?,?>
HandlerFilterFunction. ofRequestProcessor(Function<ServerRequest,reactor.core.publisher.Mono<ServerRequest>> requestProcessor)
Adapt the given request processor function to a filter function that only operates on theServerRequest
.<T extends Throwable>
RouterFunctions.BuilderRouterFunctions.Builder. onError(Class<T> exceptionType, BiFunction<? super T,ServerRequest,reactor.core.publisher.Mono<ServerResponse>> responseProvider)
Filters all exceptions of the given type by applying the given response provider function.RouterFunctions.Builder
RouterFunctions.Builder. onError(Predicate<? super Throwable> predicate, BiFunction<? super Throwable,ServerRequest,reactor.core.publisher.Mono<ServerResponse>> responseProvider)
Filters all exceptions that match the predicate by applying the given response provider function.RouterFunctions.Builder
RouterFunctions.Builder. resources(Function<ServerRequest,reactor.core.publisher.Mono<Resource>> lookupFunction)
Route to resources using the provided lookup function.static RouterFunction<ServerResponse>
RouterFunctions. resources(Function<ServerRequest,reactor.core.publisher.Mono<Resource>> lookupFunction)
Route to resources using the provided lookup function.void
RouterFunctions.Visitor. resources(Function<ServerRequest,reactor.core.publisher.Mono<Resource>> lookupFunction)
Receive notification of a resource router function.org.springframework.web.reactive.function.server.support中ServerRequest的使用
实现ServerRequest的org.springframework.web.reactive.function.server.support中的类 修饰符和类型 类 说明 class
ServerRequestWrapper
Implementation of theServerRequest
interface that can be subclassed to adapt the request in ahandler filter function
.返回ServerRequest的org.springframework.web.reactive.function.server.support中的方法 修饰符和类型 方法 说明 ServerRequest
ServerRequestWrapper. request()
Return the wrapped request.参数类型为ServerRequest的org.springframework.web.reactive.function.server.support中的构造器 构造器 说明 ServerRequestWrapper(ServerRequest delegate)
Create a newServerRequestWrapper
that wraps the given request.