Package software.amazon.awscdk
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 Summary
-
Method Summary
Modifier and TypeMethodDescriptionanalyticsReporting
(Boolean analyticsReporting) Sets the value ofAppProps.getAnalyticsReporting()
Sets the value ofAppProps.getAutoSynth()
build()
Builds the configured instance.Sets the value ofAppProps.getContext()
defaultStackSynthesizer
(IReusableStackSynthesizer defaultStackSynthesizer) Sets the value ofAppProps.getDefaultStackSynthesizer()
Sets the value ofAppProps.getOutdir()
policyValidationBeta1
(List<? extends IPolicyValidationPluginBeta1> policyValidationBeta1) Sets the value ofAppProps.getPolicyValidationBeta1()
postCliContext
(Map<String, ? extends Object> postCliContext) Sets the value ofAppProps.getPostCliContext()
stackTraces
(Boolean stackTraces) Sets the value ofAppProps.getStackTraces()
treeMetadata
(Boolean treeMetadata) Sets the value ofAppProps.getTreeMetadata()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
analyticsReporting
Sets the value ofAppProps.getAnalyticsReporting()
- Parameters:
analyticsReporting
- Include runtime versioning information in the Stacks of this app.- Returns:
this
-
autoSynth
Sets the value ofAppProps.getAutoSynth()
- Parameters:
autoSynth
- Automatically callsynth()
before the program exits. If you set this, you don't have to callsynth()
explicitly. Note that this feature is only available for certain programming languages, and callingsynth()
is still recommended.- Returns:
this
-
context
Sets the value ofAppProps.getContext()
- Parameters:
context
- Additional context values for the application. Context set by the CLI or thecontext
key incdk.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) Sets the value ofAppProps.getDefaultStackSynthesizer()
- 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
Sets the value ofAppProps.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) Sets the value ofAppProps.getPolicyValidationBeta1()
- Parameters:
policyValidationBeta1
- Validation plugins to run after synthesis.- Returns:
this
-
postCliContext
@Stability(Stable) public AppProps.Builder postCliContext(Map<String, ? extends Object> postCliContext) Sets the value ofAppProps.getPostCliContext()
- Parameters:
postCliContext
- Additional context values for the application. Context provided here has precedence over context set by:- The CLI via --context
- The
context
key incdk.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
Sets the value ofAppProps.getStackTraces()
- Parameters:
stackTraces
- Include construct creation stack trace in theaws:cdk:trace
metadata key of all constructs.- Returns:
this
-
treeMetadata
Sets the value ofAppProps.getTreeMetadata()
- Parameters:
treeMetadata
- Include construct tree metadata as part of the Cloud Assembly.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<AppProps>
- Returns:
- a new instance of
AppProps
- Throws:
NullPointerException
- if any required attribute was not provided
-