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.
Expressions in connection blocks cannot refer to their parent resource by name.
References create dependencies, and referring to a resource by name within its own block would create a dependency cycle.
Instead, expressions can use the self object, which represents the connection’s parent resource and has all of that resource’s attributes.
For example, use self.public_ip to reference an aws_instance’s public_ip attribute.
Initializers
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.NewTerraformSelf() TerraformSelf
Static Functions
| Name | Description |
|---|
GetAny | Only usable within a connection block to reference the connections parent resource. |
GetNumber | Only usable within a connection block to reference the connections parent resource. |
GetString | Only usable within a connection block to reference the connections parent resource. |
GetAny
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformSelf_GetAny(key *string) interface{}
Only usable within a connection block to reference the connections parent resource.
Access a property on the resource like this: getAny("hostPort")
keyRequired
GetNumber
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformSelf_GetNumber(key *string) *f64
Only usable within a connection block to reference the connections parent resource.
Access a property on the resource like this: getNumber("hostPort")
keyRequired
GetString
import "github.com/open-constructs/cdk-terrain-go/cdktn"
cdktn.TerraformSelf_GetString(key *string) *string
Only usable within a connection block to reference the connections parent resource.
Access a property on the resource like this: getString("publicIp")
keyRequired