Class CfnBranchProps.Builder

java.lang.Object
software.amazon.awscdk.services.amplify.CfnBranchProps.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnBranchProps>
Enclosing interface:
CfnBranchProps

@Stability(Stable) public static final class CfnBranchProps.Builder extends Object implements software.amazon.jsii.Builder<CfnBranchProps>
A builder for CfnBranchProps
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • appId

      @Stability(Stable) public CfnBranchProps.Builder appId(String appId)
      Sets the value of CfnBranchProps.getAppId()
      Parameters:
      appId - The unique ID for an Amplify app. This parameter is required.
      Returns:
      this
    • branchName

      @Stability(Stable) public CfnBranchProps.Builder branchName(String branchName)
      Parameters:
      branchName - The name for the branch. This parameter is required.
      Returns:
      this
    • backend

      @Stability(Stable) public CfnBranchProps.Builder backend(IResolvable backend)
      Sets the value of CfnBranchProps.getBackend()
      Parameters:
      backend - Specifies the backend for a Branch of an Amplify app.
      Returns:
      this
    • backend

      @Stability(Stable) public CfnBranchProps.Builder backend(CfnBranch.BackendProperty backend)
      Sets the value of CfnBranchProps.getBackend()
      Parameters:
      backend - Specifies the backend for a Branch of an Amplify app.
      Returns:
      this
    • basicAuthConfig

      @Stability(Stable) public CfnBranchProps.Builder basicAuthConfig(IResolvable basicAuthConfig)
      Parameters:
      basicAuthConfig - The basic authorization credentials for a branch of an Amplify app. You must base64-encode the authorization credentials and provide them in the format user:password .
      Returns:
      this
    • basicAuthConfig

      @Stability(Stable) public CfnBranchProps.Builder basicAuthConfig(CfnBranch.BasicAuthConfigProperty basicAuthConfig)
      Parameters:
      basicAuthConfig - The basic authorization credentials for a branch of an Amplify app. You must base64-encode the authorization credentials and provide them in the format user:password .
      Returns:
      this
    • buildSpec

      @Stability(Stable) public CfnBranchProps.Builder buildSpec(String buildSpec)
      Parameters:
      buildSpec - The build specification (build spec) for the branch.
      Returns:
      this
    • description

      @Stability(Stable) public CfnBranchProps.Builder description(String description)
      Parameters:
      description - The description for the branch that is part of an Amplify app.
      Returns:
      this
    • enableAutoBuild

      @Stability(Stable) public CfnBranchProps.Builder enableAutoBuild(Boolean enableAutoBuild)
      Parameters:
      enableAutoBuild - Enables auto building for the branch.
      Returns:
      this
    • enableAutoBuild

      @Stability(Stable) public CfnBranchProps.Builder enableAutoBuild(IResolvable enableAutoBuild)
      Parameters:
      enableAutoBuild - Enables auto building for the branch.
      Returns:
      this
    • enablePerformanceMode

      @Stability(Stable) public CfnBranchProps.Builder enablePerformanceMode(Boolean enablePerformanceMode)
      Parameters:
      enablePerformanceMode - Enables performance mode for the branch. Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out.
      Returns:
      this
    • enablePerformanceMode

      @Stability(Stable) public CfnBranchProps.Builder enablePerformanceMode(IResolvable enablePerformanceMode)
      Parameters:
      enablePerformanceMode - Enables performance mode for the branch. Performance mode optimizes for faster hosting performance by keeping content cached at the edge for a longer interval. When performance mode is enabled, hosting configuration or code changes can take up to 10 minutes to roll out.
      Returns:
      this
    • enablePullRequestPreview

      @Stability(Stable) public CfnBranchProps.Builder enablePullRequestPreview(Boolean enablePullRequestPreview)
      Parameters:
      enablePullRequestPreview - Specifies whether Amplify Hosting creates a preview for each pull request that is made for this branch. If this property is enabled, Amplify deploys your app to a unique preview URL after each pull request is opened. Development and QA teams can use this preview to test the pull request before it's merged into a production or integration branch.

      To provide backend support for your preview, Amplify automatically provisions a temporary backend environment that it deletes when the pull request is closed. If you want to specify a dedicated backend environment for your previews, use the PullRequestEnvironmentName property.

      For more information, see Web Previews in the AWS Amplify Hosting User Guide .

      Returns:
      this
    • enablePullRequestPreview

      @Stability(Stable) public CfnBranchProps.Builder enablePullRequestPreview(IResolvable enablePullRequestPreview)
      Parameters:
      enablePullRequestPreview - Specifies whether Amplify Hosting creates a preview for each pull request that is made for this branch. If this property is enabled, Amplify deploys your app to a unique preview URL after each pull request is opened. Development and QA teams can use this preview to test the pull request before it's merged into a production or integration branch.

      To provide backend support for your preview, Amplify automatically provisions a temporary backend environment that it deletes when the pull request is closed. If you want to specify a dedicated backend environment for your previews, use the PullRequestEnvironmentName property.

      For more information, see Web Previews in the AWS Amplify Hosting User Guide .

      Returns:
      this
    • environmentVariables

      @Stability(Stable) public CfnBranchProps.Builder environmentVariables(IResolvable environmentVariables)
      Parameters:
      environmentVariables - The environment variables for the branch.
      Returns:
      this
    • environmentVariables

      @Stability(Stable) public CfnBranchProps.Builder environmentVariables(List<? extends Object> environmentVariables)
      Parameters:
      environmentVariables - The environment variables for the branch.
      Returns:
      this
    • framework

      @Stability(Stable) public CfnBranchProps.Builder framework(String framework)
      Parameters:
      framework - The framework for the branch.
      Returns:
      this
    • pullRequestEnvironmentName

      @Stability(Stable) public CfnBranchProps.Builder pullRequestEnvironmentName(String pullRequestEnvironmentName)
      Parameters:
      pullRequestEnvironmentName - If pull request previews are enabled for this branch, you can use this property to specify a dedicated backend environment for your previews. For example, you could specify an environment named prod , test , or dev that you initialized with the Amplify CLI and mapped to this branch.

      To enable pull request previews, set the EnablePullRequestPreview property to true .

      If you don't specify an environment, Amplify Hosting provides backend support for each preview by automatically provisioning a temporary backend environment. Amplify Hosting deletes this environment when the pull request is closed.

      For more information about creating backend environments, see Feature Branch Deployments and Team Workflows in the AWS Amplify Hosting User Guide .

      Returns:
      this
    • stage

      @Stability(Stable) public CfnBranchProps.Builder stage(String stage)
      Sets the value of CfnBranchProps.getStage()
      Parameters:
      stage - Describes the current stage for the branch.
      Returns:
      this
    • tags

      @Stability(Stable) public CfnBranchProps.Builder tags(List<? extends CfnTag> tags)
      Sets the value of CfnBranchProps.getTags()
      Parameters:
      tags - The tag for the branch.
      Returns:
      this
    • build

      @Stability(Stable) public CfnBranchProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnBranchProps>
      Returns:
      a new instance of CfnBranchProps
      Throws:
      NullPointerException - if any required attribute was not provided