Class RedirectOptions.Builder
java.lang.Object
software.amazon.awscdk.services.elasticloadbalancingv2.RedirectOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<RedirectOptions>
- Enclosing interface:
RedirectOptions
@Stability(Stable)
public static final class RedirectOptions.Builder
extends Object
implements software.amazon.jsii.Builder<RedirectOptions>
A builder for
RedirectOptions-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.Sets the value ofRedirectOptions.getHost()Sets the value ofRedirectOptions.getPath()Sets the value ofRedirectOptions.getPermanent()Sets the value ofRedirectOptions.getPort()Sets the value ofRedirectOptions.getProtocol()Sets the value ofRedirectOptions.getQuery()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
host
Sets the value ofRedirectOptions.getHost()- Parameters:
host- The hostname. This component is not percent-encoded. The hostname can contain #{host}.- Returns:
this
-
path
Sets the value ofRedirectOptions.getPath()- Parameters:
path- The absolute path, starting with the leading "/". This component is not percent-encoded. The path can contain #{host}, #{path}, and #{port}.- Returns:
this
-
permanent
Sets the value ofRedirectOptions.getPermanent()- Parameters:
permanent- The HTTP redirect code. The redirect is either permanent (HTTP 301) or temporary (HTTP 302).- Returns:
this
-
port
Sets the value ofRedirectOptions.getPort()- Parameters:
port- The port. You can specify a value from 1 to 65535 or #{port}.- Returns:
this
-
protocol
Sets the value ofRedirectOptions.getProtocol()- Parameters:
protocol- The protocol. You can specify HTTP, HTTPS, or #{protocol}. You can redirect HTTP to HTTP, HTTP to HTTPS, and HTTPS to HTTPS. You cannot redirect HTTPS to HTTP.- Returns:
this
-
query
Sets the value ofRedirectOptions.getQuery()- Parameters:
query- The query parameters, URL-encoded when necessary, but not percent-encoded. Do not include the leading "?", as it is automatically added. You can specify any of the reserved keywords.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<RedirectOptions>- Returns:
- a new instance of
RedirectOptions - Throws:
NullPointerException- if any required attribute was not provided
-