AssetManifestBuilder
Build an asset manifest from assets added to a stack.
This class does not need to be used by app builders; it is only necessary for building Stack Synthesizers.
Initializers
using AlibabaCloud.SDK.ROS.CDK.Core;
new AssetManifestBuilder();
Name | Type | Description |
---|---|---|
Methods
Name | Description |
---|---|
AddDockerImageAsset |
Add a docker asset source and destination to the manifest. |
AddFileAsset |
Add a file asset source and destination to the manifest. |
DefaultAddDockerImageAsset |
Add a docker image asset to the manifest with default settings. |
DefaultAddFileAsset |
Add a file asset to the manifest with default settings. |
EmitManifest |
Write the manifest to disk, and add it to the synthesis session. |
AddDockerImageAsset
private DockerImageDestination AddDockerImageAsset(Stack Stack, string SourceHash, DockerImageSource Source, DockerImageDestination Dest)
Add a docker asset source and destination to the manifest.
sourceHash should be unique for every source.
- Type: Stack
- Type: string
- Type: AlibabaCloud.SDK.ROS.CDK.Assembly.Schema.DockerImageSource
- Type: AlibabaCloud.SDK.ROS.CDK.Assembly.Schema.DockerImageDestination
AddFileAsset
private FileDestination AddFileAsset(Stack Stack, string SourceHash, FileSource Source, FileDestination Dest)
Add a file asset source and destination to the manifest.
sourceHash should be unique for every source.
- Type: Stack
- Type: string
- Type: AlibabaCloud.SDK.ROS.CDK.Assembly.Schema.FileSource
- Type: AlibabaCloud.SDK.ROS.CDK.Assembly.Schema.FileDestination
DefaultAddDockerImageAsset
private DockerImageDestination DefaultAddDockerImageAsset(Stack Stack, DockerImageAssetSource Asset, AssetManifestDockerImageDestination Target)
Add a docker image asset to the manifest with default settings.
Derive the region from the stack, use the asset hash as the key, and set the prefix.
- Type: Stack
- Type: DockerImageAssetSource
DefaultAddFileAsset
private FileDestination DefaultAddFileAsset(Stack Stack, FileAssetSource Asset, AssetManifestFileDestination Target)
Add a file asset to the manifest with default settings.
Derive the region from the stack, use the asset hash as the key, copy the file extension over, and set the prefix.
- Type: Stack
- Type: FileAssetSource
EmitManifest
private string EmitManifest(Stack Stack, ISynthesisSession Session, AssetManifestOptions Options = null, string[] Dependencies = null)
Write the manifest to disk, and add it to the synthesis session.
Return the artifact id, which should be added to the additionalDependencies
field of the stack artifact.
- Type: Stack
- Type: ISynthesisSession
- Type: AlibabaCloud.SDK.ROS.CDK.Assembly.Schema.AssetManifestOptions
- Type: string[]
Properties
Name | Type | Description |
---|---|---|
HasAssets |
bool |
Whether there are any assets registered in the manifest. |
HasAssets
Required
public bool HasAssets { get; }
- Type: bool
Whether there are any assets registered in the manifest.