public static final class FunctionUrlCorsOptions.Builder
extends java.lang.Object
FunctionUrlCorsOptions
Constructor and Description |
---|
Builder() |
public FunctionUrlCorsOptions.Builder allowCredentials(java.lang.Boolean allowCredentials)
FunctionUrlCorsOptions.getAllowCredentials()
allowCredentials
- Whether to allow cookies or other credentials in requests to your function URL.this
public FunctionUrlCorsOptions.Builder allowedHeaders(java.util.List<java.lang.String> allowedHeaders)
FunctionUrlCorsOptions.getAllowedHeaders()
allowedHeaders
- Headers that are specified in the Access-Control-Request-Headers header.this
public FunctionUrlCorsOptions.Builder allowedMethods(java.util.List<? extends HttpMethod> allowedMethods)
FunctionUrlCorsOptions.getAllowedMethods()
allowedMethods
- An HTTP method that you allow the origin to execute.this
public FunctionUrlCorsOptions.Builder allowedOrigins(java.util.List<java.lang.String> allowedOrigins)
FunctionUrlCorsOptions.getAllowedOrigins()
allowedOrigins
- One or more origins you want customers to be able to access the bucket from.this
public FunctionUrlCorsOptions.Builder exposedHeaders(java.util.List<java.lang.String> exposedHeaders)
FunctionUrlCorsOptions.getExposedHeaders()
exposedHeaders
- One or more headers in the response that you want customers to be able to access from their applications.this
public FunctionUrlCorsOptions.Builder maxAge(Duration maxAge)
FunctionUrlCorsOptions.getMaxAge()
maxAge
- The time in seconds that your browser is to cache the preflight response for the specified resource.this
public FunctionUrlCorsOptions build()
FunctionUrlCorsOptions
java.lang.NullPointerException
- if any required attribute was not provided