Skip to main content

Initializers

import io.cdktn.cdktn.TerraformAsset;

TerraformAsset.Builder.create(Construct scope, java.lang.String id)
    .path(java.lang.String)
//  .assetHash(java.lang.String)
//  .type(AssetType)
    .build();
NameTypeDescription
scopesoftware.constructs.ConstructNo description.
idjava.lang.StringNo description.
pathjava.lang.StringNo description.
assetHashjava.lang.StringNo description.
typeAssetTypeNo description.

scopeRequired

  • Type: software.constructs.Construct

idRequired

  • Type: java.lang.String

pathRequired

  • Type: java.lang.String

assetHashOptional

  • Type: java.lang.String

typeOptional


Methods

NameDescription
toStringReturns a string representation of this construct.

toString

public java.lang.String toString()
Returns a string representation of this construct.

Static Functions

NameDescription
isConstructChecks if x is a construct.

isConstruct

import io.cdktn.cdktn.TerraformAsset;

TerraformAsset.isConstruct(java.lang.Object x)
Checks if x is a construct. Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked. Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired

  • Type: java.lang.Object
Any object.

Properties

NameTypeDescription
nodesoftware.constructs.NodeThe tree node.
fileNamejava.lang.StringName of the asset.
pathjava.lang.StringThe path relative to the root of the terraform directory in posix format Use this property to reference the asset.
assetHashjava.lang.StringNo description.
typeAssetTypeNo description.

nodeRequired

public Node getNode();
  • Type: software.constructs.Node
The tree node.

fileNameRequired

public java.lang.String getFileName();
  • Type: java.lang.String
Name of the asset.

pathRequired

public java.lang.String getPath();
  • Type: java.lang.String
The path relative to the root of the terraform directory in posix format Use this property to reference the asset.

assetHashRequired

public java.lang.String getAssetHash();
  • Type: java.lang.String

typeRequired

public AssetType getType();