Package | Description |
---|---|
io.netty.handler.codec.http.cors |
This package contains Cross Origin Resource Sharing (CORS) related classes.
|
Modifier and Type | Method and Description |
---|---|
CorsConfigBuilder |
CorsConfigBuilder.allowCredentials()
By default cookies are not included in CORS requests, but this method will enable cookies to
be added to CORS requests.
|
CorsConfigBuilder |
CorsConfigBuilder.allowedRequestHeaders(CharSequence... headers)
Specifies the if headers that should be returned in the CORS 'Access-Control-Allow-Headers'
response header.
|
CorsConfigBuilder |
CorsConfigBuilder.allowedRequestHeaders(String... headers)
Specifies the if headers that should be returned in the CORS 'Access-Control-Allow-Headers'
response header.
|
CorsConfigBuilder |
CorsConfigBuilder.allowedRequestMethods(HttpMethod... methods)
Specifies the allowed set of HTTP Request Methods that should be returned in the
CORS 'Access-Control-Request-Method' response header.
|
CorsConfigBuilder |
CorsConfigBuilder.allowNullOrigin()
Web browsers may set the 'Origin' request header to 'null' if a resource is loaded
from the local file system.
|
CorsConfigBuilder |
CorsConfigBuilder.disable()
Disables CORS support.
|
CorsConfigBuilder |
CorsConfigBuilder.exposeHeaders(CharSequence... headers)
Specifies the headers to be exposed to calling clients.
|
CorsConfigBuilder |
CorsConfigBuilder.exposeHeaders(String... headers)
Specifies the headers to be exposed to calling clients.
|
static CorsConfigBuilder |
CorsConfigBuilder.forAnyOrigin()
Creates a Builder instance with it's origin set to '*'.
|
static CorsConfigBuilder |
CorsConfigBuilder.forOrigin(String origin)
Creates a
CorsConfigBuilder instance with the specified origin. |
static CorsConfigBuilder |
CorsConfigBuilder.forOrigins(String... origins)
Creates a
CorsConfigBuilder instance with the specified origins. |
CorsConfigBuilder |
CorsConfigBuilder.maxAge(long max)
When making a preflight request the client has to perform two request with can be inefficient.
|
CorsConfigBuilder |
CorsConfigBuilder.noPreflightResponseHeaders()
Specifies that no preflight response headers should be added to a preflight response.
|
<T> CorsConfigBuilder |
CorsConfigBuilder.preflightResponseHeader(CharSequence name,
Callable<T> valueGenerator)
Returns HTTP response headers that should be added to a CORS preflight response.
|
<T> CorsConfigBuilder |
CorsConfigBuilder.preflightResponseHeader(CharSequence name,
Iterable<T> value)
Returns HTTP response headers that should be added to a CORS preflight response.
|
CorsConfigBuilder |
CorsConfigBuilder.preflightResponseHeader(CharSequence name,
Object... values)
Returns HTTP response headers that should be added to a CORS preflight response.
|
CorsConfigBuilder |
CorsConfigBuilder.shortCircuit()
Specifies that a CORS request should be rejected if it's invalid before being
further processing.
|
Copyright © 2008–2017 The Netty Project. All rights reserved.