-
Notifications
You must be signed in to change notification settings - Fork 17
/
awscdk_Tags.go
102 lines (92 loc) · 2.59 KB
/
awscdk_Tags.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
// An experiment to bundle the entire CDK into a single module
package awscdk
import (
_init_ "github.com/aws/aws-cdk-go/awscdk/jsii"
_jsii_ "github.com/aws/jsii-runtime-go/runtime"
)
// Manages AWS tags for all resources within a construct scope.
//
// Example:
// var mesh mesh
// var service service
//
//
// node := appmesh.NewVirtualNode(this, jsii.String("node"), &virtualNodeProps{
// mesh: mesh,
// serviceDiscovery: appmesh.serviceDiscovery.cloudMap(service),
// listeners: []virtualNodeListener{
// appmesh.*virtualNodeListener.http(&httpVirtualNodeListenerOptions{
// port: jsii.Number(8080),
// healthCheck: appmesh.healthCheck.http(&httpHealthCheckOptions{
// healthyThreshold: jsii.Number(3),
// interval: cdk.duration.seconds(jsii.Number(5)),
// path: jsii.String("/ping"),
// timeout: cdk.*duration.seconds(jsii.Number(2)),
// unhealthyThreshold: jsii.Number(2),
// }),
// timeout: &httpTimeout{
// idle: cdk.*duration.seconds(jsii.Number(5)),
// },
// }),
// },
// backendDefaults: &backendDefaults{
// tlsClientPolicy: &tlsClientPolicy{
// validation: &tlsValidation{
// trust: appmesh.tlsValidationTrust.file(jsii.String("/keys/local_cert_chain.pem")),
// },
// },
// },
// accessLog: appmesh.accessLog.fromFilePath(jsii.String("/dev/stdout")),
// })
//
// cdk.tags.of(node).add(jsii.String("Environment"), jsii.String("Dev"))
//
// Experimental.
type Tags interface {
// add tags to the node of a construct and all its the taggable children.
// Experimental.
Add(key *string, value *string, props *TagProps)
// remove tags to the node of a construct and all its the taggable children.
// Experimental.
Remove(key *string, props *TagProps)
}
// The jsii proxy struct for Tags
type jsiiProxy_Tags struct {
_ byte // padding
}
// Returns the tags API for this scope.
// Experimental.
func Tags_Of(scope IConstruct) Tags {
_init_.Initialize()
if err := validateTags_OfParameters(scope); err != nil {
panic(err)
}
var returns Tags
_jsii_.StaticInvoke(
"monocdk.Tags",
"of",
[]interface{}{scope},
&returns,
)
return returns
}
func (t *jsiiProxy_Tags) Add(key *string, value *string, props *TagProps) {
if err := t.validateAddParameters(key, value, props); err != nil {
panic(err)
}
_jsii_.InvokeVoid(
t,
"add",
[]interface{}{key, value, props},
)
}
func (t *jsiiProxy_Tags) Remove(key *string, props *TagProps) {
if err := t.validateRemoveParameters(key, props); err != nil {
panic(err)
}
_jsii_.InvokeVoid(
t,
"remove",
[]interface{}{key, props},
)
}