Documentation Index
Fetch the complete documentation index at: https://cdktn.io/docs/llms.txt
Use this file to discover all available pages before exploring further.
Initializers
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.NewTerraformResource(scope Construct, id *string, config TerraformResourceConfig) TerraformResource
| Name | Type | Description |
|---|
scope | github.com/aws/constructs-go/constructs/v10.Construct | No description. |
id | *string | No description. |
config | TerraformResourceConfig | No description. |
scopeRequired
- Type: github.com/aws/constructs-go/constructs/v10.Construct
idRequired
configRequired
Methods
| Name | Description |
|---|
ToString | Returns a string representation of this construct. |
AddOverride | No description. |
OverrideLogicalId | Overrides the auto-generated logical ID with a specific ID. |
ResetOverrideLogicalId | Resets a previously passed logical Id to use the auto-generated logical id again. |
ToHclTerraform | No description. |
ToMetadata | No description. |
ToTerraform | Adds this resource to the terraform JSON output. |
AddMoveTarget | Adds a user defined moveTarget string to this resource to be later used in .moveTo(moveTarget) to resolve the location of the move. |
GetAnyMapAttribute | No description. |
GetBooleanAttribute | No description. |
GetBooleanMapAttribute | No description. |
GetListAttribute | No description. |
GetNumberAttribute | No description. |
GetNumberListAttribute | No description. |
GetNumberMapAttribute | No description. |
GetStringAttribute | No description. |
GetStringMapAttribute | No description. |
HasResourceMove | No description. |
ImportFrom | No description. |
InterpolationForAttribute | No description. |
MoveFromId | Move the resource corresponding to “id” to this resource. |
MoveTo | Moves this resource to the target resource given by moveTarget. |
MoveToId | Moves this resource to the resource corresponding to “id”. |
ToString
Returns a string representation of this construct.
AddOverride
func AddOverride(path *string, value interface{})
pathRequired
valueRequired
OverrideLogicalId
func OverrideLogicalId(newLogicalId *string)
Overrides the auto-generated logical ID with a specific ID.
newLogicalIdRequired
The new logical ID to use for this stack element.
ResetOverrideLogicalId
func ResetOverrideLogicalId()
Resets a previously passed logical Id to use the auto-generated logical id again.
func ToHclTerraform() interface{}
func ToMetadata() interface{}
func ToTerraform() interface{}
Adds this resource to the terraform JSON output.
AddMoveTarget
func AddMoveTarget(moveTarget *string)
Adds a user defined moveTarget string to this resource to be later used in .moveTo(moveTarget) to resolve the location of the move.
moveTargetRequired
The string move target that will correspond to this resource.
GetAnyMapAttribute
func GetAnyMapAttribute(terraformAttribute *string) *map[string]interface{}
GetBooleanAttribute
func GetBooleanAttribute(terraformAttribute *string) IResolvable
GetBooleanMapAttribute
func GetBooleanMapAttribute(terraformAttribute *string) *map[string]*bool
GetListAttribute
func GetListAttribute(terraformAttribute *string) *[]*string
GetNumberAttribute
func GetNumberAttribute(terraformAttribute *string) *f64
GetNumberListAttribute
func GetNumberListAttribute(terraformAttribute *string) *[]*f64
GetNumberMapAttribute
func GetNumberMapAttribute(terraformAttribute *string) *map[string]*f64
GetStringAttribute
func GetStringAttribute(terraformAttribute *string) *string
GetStringMapAttribute
func GetStringMapAttribute(terraformAttribute *string) *map[string]*string
HasResourceMove
func HasResourceMove() interface{}
ImportFrom
func ImportFrom(id *string, provider TerraformProvider)
idRequired
providerOptional
InterpolationForAttribute
func InterpolationForAttribute(terraformAttribute *string) IResolvable
MoveFromId
func MoveFromId(id *string)
Move the resource corresponding to “id” to this resource.
Note that the resource being moved from must be marked as moved using it’s instance function.
idRequired
Full id of resource being moved from, e.g. “aws_s3_bucket.example”.
MoveTo
func MoveTo(moveTarget *string, index interface{})
Moves this resource to the target resource given by moveTarget.
moveTargetRequired
The previously set user defined string set by .addMoveTarget() corresponding to the resource to move to.
indexOptional
Optional The index corresponding to the key the resource is to appear in the foreach of a resource to move to.
MoveToId
func MoveToId(id *string)
Moves this resource to the resource corresponding to “id”.
idRequired
Full id of resource to move to, e.g. “aws_s3_bucket.example”.
Static Functions
| Name | Description |
|---|
IsConstruct | Checks if x is a construct. |
IsTerraformElement | No description. |
IsTerraformResource | No description. |
IsConstruct
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformResource_IsConstruct(x interface{}) *bool
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
Any object.
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformResource_IsTerraformElement(x interface{}) *bool
xRequired
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformResource_IsTerraformResource(x interface{}) *bool
xRequired
Properties
| Name | Type | Description |
|---|
Node | github.com/aws/constructs-go/constructs/v10.Node | The tree node. |
CdktfStack | TerraformStack | No description. |
Fqn | *string | No description. |
FriendlyUniqueId | *string | No description. |
TerraformMetaArguments | *map[string]interface{} | No description. |
TerraformResourceType | *string | No description. |
TerraformGeneratorMetadata | TerraformProviderGeneratorMetadata | No description. |
Connection | interface{} | No description. |
Count | interface{} | No description. |
DependsOn | *[]*string | No description. |
ForEach | ITerraformIterator | No description. |
Lifecycle | TerraformResourceLifecycle | No description. |
Provider | TerraformProvider | No description. |
Provisioners | *[]interface{} | No description. |
NodeRequired
- Type: github.com/aws/constructs-go/constructs/v10.Node
The tree node.
CdktfStackRequired
func CdktfStack() TerraformStack
FqnRequired
FriendlyUniqueIdRequired
func FriendlyUniqueId() *string
func TerraformMetaArguments() *map[string]interface{}
- Type: *map[string]interface{}
func TerraformResourceType() *string
func TerraformGeneratorMetadata() TerraformProviderGeneratorMetadata
ConnectionOptional
func Connection() interface{}
CountOptional
DependsOnOptional
func DependsOn() *[]*string
ForEachOptional
func ForEach() ITerraformIterator
LifecycleOptional
func Lifecycle() TerraformResourceLifecycle
ProviderOptional
func Provider() TerraformProvider
ProvisionersOptional
func Provisioners() *[]interface{}