Class AppProps.Builder

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

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

    • Builder

      public Builder()
  • Method Details

    • analyticsReporting

      @Stability(Stable) public AppProps.Builder analyticsReporting(Boolean analyticsReporting)
      Parameters:
      analyticsReporting - Include runtime versioning information in the Stacks of this app.
      Returns:
      this
    • autoSynth

      @Stability(Stable) public AppProps.Builder autoSynth(Boolean autoSynth)
      Sets the value of AppProps.getAutoSynth()
      Parameters:
      autoSynth - Automatically call synth() before the program exits. If you set this, you don't have to call synth() explicitly. Note that this feature is only available for certain programming languages, and calling synth() is still recommended.
      Returns:
      this
    • context

      @Stability(Stable) public AppProps.Builder context(Map<String,? extends Object> context)
      Sets the value of AppProps.getContext()
      Parameters:
      context - Additional context values for the application. Context set by the CLI or the context key in cdk.json has precedence.

      Context can be read from any construct using node.getContext(key).

      Returns:
      this
    • defaultStackSynthesizer

      @Stability(Stable) public AppProps.Builder defaultStackSynthesizer(IReusableStackSynthesizer defaultStackSynthesizer)
      Parameters:
      defaultStackSynthesizer - The stack synthesizer to use by default for all Stacks in the App. The Stack Synthesizer controls aspects of synthesis and deployment, like how assets are referenced and what IAM roles to use. For more information, see the README of the main CDK package.
      Returns:
      this
    • outdir

      @Stability(Stable) public AppProps.Builder outdir(String outdir)
      Sets the value of AppProps.getOutdir()
      Parameters:
      outdir - The output directory into which to emit synthesized artifacts. You should never need to set this value. By default, the value you pass to the CLI's --output flag will be used, and if you change it to a different directory the CLI will fail to pick up the generated Cloud Assembly.

      This property is intended for internal and testing use.

      Returns:
      this
    • policyValidationBeta1

      @Stability(Stable) public AppProps.Builder policyValidationBeta1(List<? extends IPolicyValidationPluginBeta1> policyValidationBeta1)
      Parameters:
      policyValidationBeta1 - Validation plugins to run after synthesis.
      Returns:
      this
    • postCliContext

      @Stability(Stable) public AppProps.Builder postCliContext(Map<String,? extends Object> postCliContext)
      Parameters:
      postCliContext - Additional context values for the application. Context provided here has precedence over context set by:

      • The CLI via --context
      • The context key in cdk.json
      • The AppProps.context property

      This property is recommended over the AppProps.context property since you can make final decision over which context value to take in your app.

      Context can be read from any construct using node.getContext(key).

      Returns:
      this
    • stackTraces

      @Stability(Stable) public AppProps.Builder stackTraces(Boolean stackTraces)
      Sets the value of AppProps.getStackTraces()
      Parameters:
      stackTraces - Include construct creation stack trace in the aws:cdk:trace metadata key of all constructs.
      Returns:
      this
    • treeMetadata

      @Stability(Stable) public AppProps.Builder treeMetadata(Boolean treeMetadata)
      Sets the value of AppProps.getTreeMetadata()
      Parameters:
      treeMetadata - Include construct tree metadata as part of the Cloud Assembly.
      Returns:
      this
    • build

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