Package io.github.cdklabs.projen
Class CreateProjectOptions.Builder
- java.lang.Object
-
- io.github.cdklabs.projen.CreateProjectOptions.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<CreateProjectOptions>
- Enclosing interface:
- CreateProjectOptions
@Stability(Experimental) public static final class CreateProjectOptions.Builder extends Object implements software.amazon.jsii.Builder<CreateProjectOptions>
A builder forCreateProjectOptions
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateProjectOptionsbuild()Builds the configured instance.CreateProjectOptions.Builderdir(String dir)Sets the value ofCreateProjectOptions.getDir()CreateProjectOptions.BuilderoptionHints(InitProjectOptionHints optionHints)Sets the value ofCreateProjectOptions.getOptionHints()CreateProjectOptions.Builderpost(Boolean post)Sets the value ofCreateProjectOptions.getPost()CreateProjectOptions.BuilderprojectFqn(String projectFqn)Sets the value ofCreateProjectOptions.getProjectFqn()CreateProjectOptions.BuilderprojectOptions(Map<String,? extends Object> projectOptions)Sets the value ofCreateProjectOptions.getProjectOptions()CreateProjectOptions.Buildersynth(Boolean synth)Sets the value ofCreateProjectOptions.getSynth()
-
-
-
Method Detail
-
dir
@Stability(Experimental) public CreateProjectOptions.Builder dir(String dir)
Sets the value ofCreateProjectOptions.getDir()- Parameters:
dir- Directory that the project will be generated in. This parameter is required.- Returns:
this
-
projectFqn
@Stability(Experimental) public CreateProjectOptions.Builder projectFqn(String projectFqn)
Sets the value ofCreateProjectOptions.getProjectFqn()- Parameters:
projectFqn- Fully-qualified name of the project type (usually formatted asprojen.module.ProjectType). This parameter is required.- Returns:
this
-
projectOptions
@Stability(Experimental) public CreateProjectOptions.Builder projectOptions(Map<String,? extends Object> projectOptions)
Sets the value ofCreateProjectOptions.getProjectOptions()- Parameters:
projectOptions- Project options. This parameter is required. Only JSON-like values can be passed in (strings, booleans, numbers, enums, arrays, and objects that are not derived from classes).Consult the API reference of the project type you are generating for information about what fields and types are available.
- Returns:
this
-
optionHints
@Stability(Experimental) public CreateProjectOptions.Builder optionHints(InitProjectOptionHints optionHints)
Sets the value ofCreateProjectOptions.getOptionHints()- Parameters:
optionHints- Should we render commented-out default options in the projenrc file?. Does not apply to projenrc.json files.- Returns:
this
-
post
@Stability(Experimental) public CreateProjectOptions.Builder post(Boolean post)
Sets the value ofCreateProjectOptions.getPost()- Parameters:
post- Should we execute post synthesis hooks?. (usually package manager install).- Returns:
this
-
synth
@Stability(Experimental) public CreateProjectOptions.Builder synth(Boolean synth)
Sets the value ofCreateProjectOptions.getSynth()- Parameters:
synth- Should we callproject.synth()or instantiate the project (could still have side-effects) and render the .projenrc file.- Returns:
this
-
build
@Stability(Experimental) public CreateProjectOptions build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CreateProjectOptions>- Returns:
- a new instance of
CreateProjectOptions - Throws:
NullPointerException- if any required attribute was not provided
-
-