Class HttpGatewayRouteMatch.Builder
java.lang.Object
software.amazon.awscdk.services.appmesh.HttpGatewayRouteMatch.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<HttpGatewayRouteMatch>
- Enclosing interface:
HttpGatewayRouteMatch
@Stability(Stable)
public static final class HttpGatewayRouteMatch.Builder
extends Object
implements software.amazon.jsii.Builder<HttpGatewayRouteMatch>
A builder for
HttpGatewayRouteMatch
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.headers
(List<? extends HeaderMatch> headers) Sets the value ofHttpGatewayRouteMatch.getHeaders()
hostname
(GatewayRouteHostnameMatch hostname) Sets the value ofHttpGatewayRouteMatch.getHostname()
method
(HttpRouteMethod method) Sets the value ofHttpGatewayRouteMatch.getMethod()
Sets the value ofHttpGatewayRouteMatch.getPath()
queryParameters
(List<? extends QueryParameterMatch> queryParameters) Sets the value ofHttpGatewayRouteMatch.getQueryParameters()
rewriteRequestHostname
(Boolean rewriteRequestHostname) Sets the value ofHttpGatewayRouteMatch.getRewriteRequestHostname()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
headers
@Stability(Stable) public HttpGatewayRouteMatch.Builder headers(List<? extends HeaderMatch> headers) Sets the value ofHttpGatewayRouteMatch.getHeaders()
- Parameters:
headers
- Specifies the client request headers to match on. All specified headers must match for the gateway route to match.- Returns:
this
-
hostname
@Stability(Stable) public HttpGatewayRouteMatch.Builder hostname(GatewayRouteHostnameMatch hostname) Sets the value ofHttpGatewayRouteMatch.getHostname()
- Parameters:
hostname
- The gateway route host name to be matched on.- Returns:
this
-
method
Sets the value ofHttpGatewayRouteMatch.getMethod()
- Parameters:
method
- The method to match on.- Returns:
this
-
path
Sets the value ofHttpGatewayRouteMatch.getPath()
- Parameters:
path
- Specify how to match requests based on the 'path' part of their URL.- Returns:
this
-
queryParameters
@Stability(Stable) public HttpGatewayRouteMatch.Builder queryParameters(List<? extends QueryParameterMatch> queryParameters) Sets the value ofHttpGatewayRouteMatch.getQueryParameters()
- Parameters:
queryParameters
- The query parameters to match on. All specified query parameters must match for the route to match.- Returns:
this
-
rewriteRequestHostname
@Stability(Stable) public HttpGatewayRouteMatch.Builder rewriteRequestHostname(Boolean rewriteRequestHostname) Sets the value ofHttpGatewayRouteMatch.getRewriteRequestHostname()
- Parameters:
rewriteRequestHostname
- Whentrue
, rewrites the original request received at the Virtual Gateway to the destination Virtual Service name. Whenfalse
, retains the original hostname from the request.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<HttpGatewayRouteMatch>
- Returns:
- a new instance of
HttpGatewayRouteMatch
- Throws:
NullPointerException
- if any required attribute was not provided
-