@Stability(value=Experimental) public static final class SampleFile.Builder extends Object implements software.amazon.jsii.Builder<SampleFile>
SampleFile.| Modifier and Type | Method and Description |
|---|---|
SampleFile |
build() |
SampleFile.Builder |
contents(String contents)
(experimental) The contents of the file to write.
|
static SampleFile.Builder |
create(Project project,
String filePath) |
SampleFile.Builder |
sourcePath(String sourcePath)
(experimental) Absolute path to a file to copy the contents from (does not need to be a text file).
|
@Stability(value=Experimental) public static SampleFile.Builder create(Project project, String filePath)
project - - the project to tie this file to. This parameter is required.filePath - - the relative path in the project to put the file. This parameter is required.SampleFile.Builder.@Stability(value=Experimental) public SampleFile.Builder contents(String contents)
contents - The contents of the file to write. This parameter is required.this@Stability(value=Experimental) public SampleFile.Builder sourcePath(String sourcePath)
If your project is Typescript-based and has configured testdir to be a
subdirectory of src, sample files should outside of the src directory,
otherwise they may not be copied. For example:
new SampleFile(this, 'assets/icon.png', { source: path.join(__dirname, '..', 'sample-assets', 'icon.png') });
sourcePath - Absolute path to a file to copy the contents from (does not need to be a text file). This parameter is required.this@Stability(value=Experimental) public SampleFile build()
build in interface software.amazon.jsii.Builder<SampleFile>Copyright © 2021. All rights reserved.