Class BasePathMapping.Builder
java.lang.Object
software.amazon.awscdk.services.apigateway.BasePathMapping.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<BasePathMapping>
- Enclosing class:
BasePathMapping
@Stability(Stable)
public static final class BasePathMapping.Builder
extends Object
implements software.amazon.jsii.Builder<BasePathMapping>
A fluent builder for
BasePathMapping
.-
Method Summary
Modifier and TypeMethodDescriptionattachToStage
(Boolean attachToStage) Whether to attach the base path mapping to a stage.The base path name that callers of the API must provide in the URL after the domain name (e.g.build()
static BasePathMapping.Builder
domainName
(IDomainName domainName) The DomainName to associate with this base path mapping.The RestApi resource to target.The Deployment stage of API [disable-awslint:ref-via-interface].
-
Method Details
-
create
@Stability(Stable) public static BasePathMapping.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- This parameter is required.id
- This parameter is required.- Returns:
- a new instance of
BasePathMapping.Builder
.
-
attachToStage
Whether to attach the base path mapping to a stage.Use this property to create a base path mapping without attaching it to the Rest API default stage. This property is ignored if
stage
is provided.Default: - true
- Parameters:
attachToStage
- Whether to attach the base path mapping to a stage. This parameter is required.- Returns:
this
-
basePath
The base path name that callers of the API must provide in the URL after the domain name (e.g.example.com/base-path
). If you specify this property, it can't be an empty string.Default: - map requests from the domain root (e.g. `example.com`). If this is undefined, no additional mappings will be allowed on this domain name.
- Parameters:
basePath
- The base path name that callers of the API must provide in the URL after the domain name (e.g.example.com/base-path
). If you specify this property, it can't be an empty string. This parameter is required.- Returns:
this
-
stage
The Deployment stage of API [disable-awslint:ref-via-interface].Default: - map to deploymentStage of restApi otherwise stage needs to pass in URL
- Parameters:
stage
- The Deployment stage of API [disable-awslint:ref-via-interface]. This parameter is required.- Returns:
this
-
domainName
The DomainName to associate with this base path mapping.- Parameters:
domainName
- The DomainName to associate with this base path mapping. This parameter is required.- Returns:
this
-
restApi
The RestApi resource to target.- Parameters:
restApi
- The RestApi resource to target. This parameter is required.- Returns:
this
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<BasePathMapping>
- Returns:
- a newly built instance of
BasePathMapping
.
-