Class CrossOriginResourcePolicyServerHttpHeadersWriter
- java.lang.Object
-
- org.springframework.security.web.server.header.CrossOriginResourcePolicyServerHttpHeadersWriter
-
- All Implemented Interfaces:
ServerHttpHeadersWriter
public final class CrossOriginResourcePolicyServerHttpHeadersWriter extends java.lang.Object implements ServerHttpHeadersWriter
Inserts Cross-Origin-Resource-Policy headers.- Since:
- 5.7
- See Also:
- Cross-Origin-Resource-Policy
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
RESOURCE_POLICY
-
Constructor Summary
Constructors Constructor Description CrossOriginResourcePolicyServerHttpHeadersWriter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
setPolicy(CrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy resourcePolicy)
Sets theCrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy
value to be used in theCross-Origin-Embedder-Policy
headerreactor.core.publisher.Mono<java.lang.Void>
writeHttpHeaders(org.springframework.web.server.ServerWebExchange exchange)
Write the headers to the response.
-
-
-
Field Detail
-
RESOURCE_POLICY
public static final java.lang.String RESOURCE_POLICY
- See Also:
- Constant Field Values
-
-
Method Detail
-
setPolicy
public void setPolicy(CrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy resourcePolicy)
Sets theCrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy
value to be used in theCross-Origin-Embedder-Policy
header- Parameters:
resourcePolicy
- theCrossOriginResourcePolicyServerHttpHeadersWriter.CrossOriginResourcePolicy
to use
-
writeHttpHeaders
public reactor.core.publisher.Mono<java.lang.Void> writeHttpHeaders(org.springframework.web.server.ServerWebExchange exchange)
Description copied from interface:ServerHttpHeadersWriter
Write the headers to the response.- Specified by:
writeHttpHeaders
in interfaceServerHttpHeadersWriter
- Returns:
- A Mono which is returned to the
Supplier
of theReactiveHttpOutputMessage.beforeCommit(Supplier)
.
-
-