Class PreFlightRequestWebFilter
java.lang.Object
org.springframework.web.cors.reactive.PreFlightRequestWebFilter
- All Implemented Interfaces:
WebFilter
WebFilter that handles pre-flight requests through a
PreFlightRequestHandler
and bypasses the rest of the chain.
A WebFlux application can simply inject PreFlightRequestHandler and use
it to create an instance of this WebFilter since @EnableWebFlux
declares DispatcherHandler
as a bean and that is a
PreFlightRequestHandler.
- Since:
- 5.3.7
- Author:
- Rossen Stoyanchev
-
Constructor Summary
ConstructorDescriptionCreate an instance that will delegate to the given handler. -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<Void>
filter
(ServerWebExchange exchange, WebFilterChain chain) Process the Web request and (optionally) delegate to the nextWebFilter
through the givenWebFilterChain
.
-
Constructor Details
-
PreFlightRequestWebFilter
Create an instance that will delegate to the given handler.
-
-
Method Details
-
filter
Description copied from interface:WebFilter
Process the Web request and (optionally) delegate to the nextWebFilter
through the givenWebFilterChain
.
-