@cdktf-providers/edge-center-edgecenter 0.10.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (173) hide show
  1. package/LICENSE +355 -0
  2. package/README.md +19 -0
  3. package/dist/baremetal/index.d.ts +528 -0
  4. package/dist/baremetal/index.js +1250 -0
  5. package/dist/cdn-lecert/index.d.ts +76 -0
  6. package/dist/cdn-lecert/index.js +157 -0
  7. package/dist/cdn-origingroup/index.d.ts +237 -0
  8. package/dist/cdn-origingroup/index.js +560 -0
  9. package/dist/cdn-resource/index.d.ts +2223 -0
  10. package/dist/cdn-resource/index.js +5865 -0
  11. package/dist/cdn-rule/index.d.ts +2037 -0
  12. package/dist/cdn-rule/index.js +5381 -0
  13. package/dist/cdn-shielding/index.d.ts +64 -0
  14. package/dist/cdn-shielding/index.js +131 -0
  15. package/dist/cdn-sslcert/index.d.ts +76 -0
  16. package/dist/cdn-sslcert/index.js +159 -0
  17. package/dist/data-edgecenter-availability-zone/index.d.ts +67 -0
  18. package/dist/data-edgecenter-availability-zone/index.js +141 -0
  19. package/dist/data-edgecenter-cdn-shielding-location/index.d.ts +54 -0
  20. package/dist/data-edgecenter-cdn-shielding-location/index.js +111 -0
  21. package/dist/data-edgecenter-floatingip/index.d.ts +183 -0
  22. package/dist/data-edgecenter-floatingip/index.js +378 -0
  23. package/dist/data-edgecenter-image/index.d.ts +183 -0
  24. package/dist/data-edgecenter-image/index.js +378 -0
  25. package/dist/data-edgecenter-instance/index.d.ts +312 -0
  26. package/dist/data-edgecenter-instance/index.js +690 -0
  27. package/dist/data-edgecenter-instance-port-security/index.d.ts +110 -0
  28. package/dist/data-edgecenter-instance-port-security/index.js +231 -0
  29. package/dist/data-edgecenter-instance-v2/index.d.ts +222 -0
  30. package/dist/data-edgecenter-instance-v2/index.js +501 -0
  31. package/dist/data-edgecenter-k8s/index.d.ts +167 -0
  32. package/dist/data-edgecenter-k8s/index.js +412 -0
  33. package/dist/data-edgecenter-k8s-client-config/index.d.ts +100 -0
  34. package/dist/data-edgecenter-k8s-client-config/index.js +211 -0
  35. package/dist/data-edgecenter-k8s-pool/index.d.ts +120 -0
  36. package/dist/data-edgecenter-k8s-pool/index.js +271 -0
  37. package/dist/data-edgecenter-lb-l7policy/index.d.ts +114 -0
  38. package/dist/data-edgecenter-lb-l7policy/index.js +258 -0
  39. package/dist/data-edgecenter-lb-l7rule/index.d.ts +120 -0
  40. package/dist/data-edgecenter-lb-l7rule/index.js +262 -0
  41. package/dist/data-edgecenter-lblistener/index.d.ts +122 -0
  42. package/dist/data-edgecenter-lblistener/index.js +269 -0
  43. package/dist/data-edgecenter-lbpool/index.d.ts +204 -0
  44. package/dist/data-edgecenter-lbpool/index.js +454 -0
  45. package/dist/data-edgecenter-loadbalancer/index.d.ts +203 -0
  46. package/dist/data-edgecenter-loadbalancer/index.js +427 -0
  47. package/dist/data-edgecenter-loadbalancerv2/index.d.ts +169 -0
  48. package/dist/data-edgecenter-loadbalancerv2/index.js +343 -0
  49. package/dist/data-edgecenter-network/index.d.ts +270 -0
  50. package/dist/data-edgecenter-network/index.js +589 -0
  51. package/dist/data-edgecenter-project/index.d.ts +72 -0
  52. package/dist/data-edgecenter-project/index.js +153 -0
  53. package/dist/data-edgecenter-region/index.d.ts +54 -0
  54. package/dist/data-edgecenter-region/index.js +111 -0
  55. package/dist/data-edgecenter-reseller-images/index.d.ts +91 -0
  56. package/dist/data-edgecenter-reseller-images/index.js +198 -0
  57. package/dist/data-edgecenter-reseller-images-v2/index.d.ts +101 -0
  58. package/dist/data-edgecenter-reseller-images-v2/index.js +218 -0
  59. package/dist/data-edgecenter-reseller-networks/index.d.ts +269 -0
  60. package/dist/data-edgecenter-reseller-networks/index.js +610 -0
  61. package/dist/data-edgecenter-reservedfixedip/index.d.ts +141 -0
  62. package/dist/data-edgecenter-reservedfixedip/index.js +311 -0
  63. package/dist/data-edgecenter-router/index.d.ts +245 -0
  64. package/dist/data-edgecenter-router/index.js +538 -0
  65. package/dist/data-edgecenter-secret/index.d.ts +109 -0
  66. package/dist/data-edgecenter-secret/index.js +235 -0
  67. package/dist/data-edgecenter-securitygroup/index.d.ts +211 -0
  68. package/dist/data-edgecenter-securitygroup/index.js +450 -0
  69. package/dist/data-edgecenter-servergroup/index.d.ts +137 -0
  70. package/dist/data-edgecenter-servergroup/index.js +289 -0
  71. package/dist/data-edgecenter-snapshot/index.d.ts +129 -0
  72. package/dist/data-edgecenter-snapshot/index.js +281 -0
  73. package/dist/data-edgecenter-storage-s3/index.d.ts +71 -0
  74. package/dist/data-edgecenter-storage-s3/index.js +157 -0
  75. package/dist/data-edgecenter-storage-s3-bucket/index.d.ts +64 -0
  76. package/dist/data-edgecenter-storage-s3-bucket/index.js +131 -0
  77. package/dist/data-edgecenter-subnet/index.d.ts +253 -0
  78. package/dist/data-edgecenter-subnet/index.js +536 -0
  79. package/dist/data-edgecenter-useractions-subscription-amqp/index.d.ts +48 -0
  80. package/dist/data-edgecenter-useractions-subscription-amqp/index.js +107 -0
  81. package/dist/data-edgecenter-useractions-subscription-log/index.d.ts +47 -0
  82. package/dist/data-edgecenter-useractions-subscription-log/index.js +103 -0
  83. package/dist/data-edgecenter-volume/index.d.ts +169 -0
  84. package/dist/data-edgecenter-volume/index.js +343 -0
  85. package/dist/dns-zone/index.d.ts +54 -0
  86. package/dist/dns-zone/index.js +111 -0
  87. package/dist/dns-zone-record/index.d.ts +494 -0
  88. package/dist/dns-zone-record/index.js +1217 -0
  89. package/dist/floatingip/index.d.ts +185 -0
  90. package/dist/floatingip/index.js +394 -0
  91. package/dist/index.d.ts +83 -0
  92. package/dist/index.js +84 -0
  93. package/dist/instance/index.d.ts +830 -0
  94. package/dist/instance/index.js +1948 -0
  95. package/dist/instance-port-security/index.d.ts +229 -0
  96. package/dist/instance-port-security/index.js +564 -0
  97. package/dist/instance-v2/index.d.ts +552 -0
  98. package/dist/instance-v2/index.js +1244 -0
  99. package/dist/k8s/index.d.ts +342 -0
  100. package/dist/k8s/index.js +856 -0
  101. package/dist/k8s-pool/index.d.ts +227 -0
  102. package/dist/k8s-pool/index.js +514 -0
  103. package/dist/keypair/index.d.ts +88 -0
  104. package/dist/keypair/index.js +185 -0
  105. package/dist/lazy-index.d.ts +0 -0
  106. package/dist/lazy-index.js +84 -0
  107. package/dist/lb-l7policy/index.d.ts +244 -0
  108. package/dist/lb-l7policy/index.js +566 -0
  109. package/dist/lb-l7rule/index.d.ts +219 -0
  110. package/dist/lb-l7rule/index.js +506 -0
  111. package/dist/lblistener/index.d.ts +264 -0
  112. package/dist/lblistener/index.js +597 -0
  113. package/dist/lbmember/index.d.ts +207 -0
  114. package/dist/lbmember/index.js +473 -0
  115. package/dist/lbpool/index.d.ts +387 -0
  116. package/dist/lbpool/index.js +934 -0
  117. package/dist/lifecyclepolicy/index.d.ts +476 -0
  118. package/dist/lifecyclepolicy/index.js +1188 -0
  119. package/dist/loadbalancer/index.d.ts +341 -0
  120. package/dist/loadbalancer/index.js +851 -0
  121. package/dist/loadbalancerv2/index.d.ts +253 -0
  122. package/dist/loadbalancerv2/index.js +562 -0
  123. package/dist/network/index.d.ts +187 -0
  124. package/dist/network/index.js +382 -0
  125. package/dist/project/index.d.ts +68 -0
  126. package/dist/project/index.js +150 -0
  127. package/dist/protection-resource/index.d.ts +179 -0
  128. package/dist/protection-resource/index.js +381 -0
  129. package/dist/protection-resource-alias/index.d.ts +64 -0
  130. package/dist/protection-resource-alias/index.js +131 -0
  131. package/dist/protection-resource-alias-certificate/index.d.ts +88 -0
  132. package/dist/protection-resource-alias-certificate/index.js +185 -0
  133. package/dist/protection-resource-blacklist-entry/index.d.ts +64 -0
  134. package/dist/protection-resource-blacklist-entry/index.js +131 -0
  135. package/dist/protection-resource-certificate/index.d.ts +88 -0
  136. package/dist/protection-resource-certificate/index.js +185 -0
  137. package/dist/protection-resource-header/index.d.ts +74 -0
  138. package/dist/protection-resource-header/index.js +151 -0
  139. package/dist/protection-resource-origin/index.d.ts +119 -0
  140. package/dist/protection-resource-origin/index.js +246 -0
  141. package/dist/protection-resource-whitelist-entry/index.d.ts +64 -0
  142. package/dist/protection-resource-whitelist-entry/index.js +131 -0
  143. package/dist/provider/index.d.ts +182 -0
  144. package/dist/provider/index.js +384 -0
  145. package/dist/reseller-images/index.d.ts +120 -0
  146. package/dist/reseller-images/index.js +272 -0
  147. package/dist/reseller-images-v2/index.d.ts +130 -0
  148. package/dist/reseller-images-v2/index.js +292 -0
  149. package/dist/reservedfixedip/index.d.ts +230 -0
  150. package/dist/reservedfixedip/index.js +513 -0
  151. package/dist/router/index.d.ts +322 -0
  152. package/dist/router/index.js +755 -0
  153. package/dist/secret/index.d.ts +146 -0
  154. package/dist/secret/index.js +311 -0
  155. package/dist/securitygroup/index.d.ts +291 -0
  156. package/dist/securitygroup/index.js +654 -0
  157. package/dist/servergroup/index.d.ts +143 -0
  158. package/dist/servergroup/index.js +302 -0
  159. package/dist/snapshot/index.d.ts +185 -0
  160. package/dist/snapshot/index.js +383 -0
  161. package/dist/storage-s3/index.d.ts +141 -0
  162. package/dist/storage-s3/index.js +292 -0
  163. package/dist/storage-s3-bucket/index.d.ts +64 -0
  164. package/dist/storage-s3-bucket/index.js +131 -0
  165. package/dist/subnet/index.d.ts +346 -0
  166. package/dist/subnet/index.js +751 -0
  167. package/dist/useractions-subscription-amqp/index.d.ts +87 -0
  168. package/dist/useractions-subscription-amqp/index.js +180 -0
  169. package/dist/useractions-subscription-log/index.d.ts +74 -0
  170. package/dist/useractions-subscription-log/index.js +151 -0
  171. package/dist/volume/index.d.ts +208 -0
  172. package/dist/volume/index.js +424 -0
  173. package/package.json +51 -0
@@ -0,0 +1,1948 @@
1
+ // https://registry.terraform.io/providers/edge-center/edgecenter/0.10.4/docs/resources/instance
2
+ // generated from terraform resource schema
3
+ import * as cdktf from 'cdktf';
4
+ export function instanceSecurityGroupToTerraform(struct) {
5
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
6
+ return struct;
7
+ }
8
+ if (cdktf.isComplexElement(struct)) {
9
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
10
+ }
11
+ return {};
12
+ }
13
+ export function instanceSecurityGroupToHclTerraform(struct) {
14
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
15
+ return struct;
16
+ }
17
+ if (cdktf.isComplexElement(struct)) {
18
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
19
+ }
20
+ const attrs = {};
21
+ return attrs;
22
+ }
23
+ export class InstanceSecurityGroupOutputReference extends cdktf.ComplexObject {
24
+ isEmptyObject = false;
25
+ /**
26
+ * @param terraformResource The parent resource
27
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
28
+ * @param complexObjectIndex the index of this item in the list
29
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
30
+ */
31
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
32
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
33
+ }
34
+ get internalValue() {
35
+ let hasAnyValues = this.isEmptyObject;
36
+ const internalValueResult = {};
37
+ return hasAnyValues ? internalValueResult : undefined;
38
+ }
39
+ set internalValue(value) {
40
+ if (value === undefined) {
41
+ this.isEmptyObject = false;
42
+ }
43
+ else {
44
+ this.isEmptyObject = Object.keys(value).length === 0;
45
+ }
46
+ }
47
+ // id - computed: true, optional: false, required: false
48
+ get id() {
49
+ return this.getStringAttribute('id');
50
+ }
51
+ // name - computed: true, optional: false, required: false
52
+ get name() {
53
+ return this.getStringAttribute('name');
54
+ }
55
+ }
56
+ export class InstanceSecurityGroupList extends cdktf.ComplexList {
57
+ terraformResource;
58
+ terraformAttribute;
59
+ wrapsSet;
60
+ /**
61
+ * @param terraformResource The parent resource
62
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
63
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
64
+ */
65
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
66
+ super(terraformResource, terraformAttribute, wrapsSet);
67
+ this.terraformResource = terraformResource;
68
+ this.terraformAttribute = terraformAttribute;
69
+ this.wrapsSet = wrapsSet;
70
+ }
71
+ /**
72
+ * @param index the index of the item to return
73
+ */
74
+ get(index) {
75
+ return new InstanceSecurityGroupOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
76
+ }
77
+ }
78
+ export function instanceAddressesNetToTerraform(struct) {
79
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
80
+ return struct;
81
+ }
82
+ if (cdktf.isComplexElement(struct)) {
83
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
84
+ }
85
+ return {
86
+ addr: cdktf.stringToTerraform(struct.addr),
87
+ type: cdktf.stringToTerraform(struct.type),
88
+ };
89
+ }
90
+ export function instanceAddressesNetToHclTerraform(struct) {
91
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
92
+ return struct;
93
+ }
94
+ if (cdktf.isComplexElement(struct)) {
95
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
96
+ }
97
+ const attrs = {
98
+ addr: {
99
+ value: cdktf.stringToHclTerraform(struct.addr),
100
+ isBlock: false,
101
+ type: "simple",
102
+ storageClassType: "string",
103
+ },
104
+ type: {
105
+ value: cdktf.stringToHclTerraform(struct.type),
106
+ isBlock: false,
107
+ type: "simple",
108
+ storageClassType: "string",
109
+ },
110
+ };
111
+ // remove undefined attributes
112
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
113
+ }
114
+ export class InstanceAddressesNetOutputReference extends cdktf.ComplexObject {
115
+ isEmptyObject = false;
116
+ resolvableValue;
117
+ /**
118
+ * @param terraformResource The parent resource
119
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
120
+ * @param complexObjectIndex the index of this item in the list
121
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
122
+ */
123
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
124
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
125
+ }
126
+ get internalValue() {
127
+ if (this.resolvableValue) {
128
+ return this.resolvableValue;
129
+ }
130
+ let hasAnyValues = this.isEmptyObject;
131
+ const internalValueResult = {};
132
+ if (this._addr !== undefined) {
133
+ hasAnyValues = true;
134
+ internalValueResult.addr = this._addr;
135
+ }
136
+ if (this._type !== undefined) {
137
+ hasAnyValues = true;
138
+ internalValueResult.type = this._type;
139
+ }
140
+ return hasAnyValues ? internalValueResult : undefined;
141
+ }
142
+ set internalValue(value) {
143
+ if (value === undefined) {
144
+ this.isEmptyObject = false;
145
+ this.resolvableValue = undefined;
146
+ this._addr = undefined;
147
+ this._type = undefined;
148
+ }
149
+ else if (cdktf.Tokenization.isResolvable(value)) {
150
+ this.isEmptyObject = false;
151
+ this.resolvableValue = value;
152
+ }
153
+ else {
154
+ this.isEmptyObject = Object.keys(value).length === 0;
155
+ this.resolvableValue = undefined;
156
+ this._addr = value.addr;
157
+ this._type = value.type;
158
+ }
159
+ }
160
+ // addr - computed: false, optional: false, required: true
161
+ _addr;
162
+ get addr() {
163
+ return this.getStringAttribute('addr');
164
+ }
165
+ set addr(value) {
166
+ this._addr = value;
167
+ }
168
+ // Temporarily expose input value. Use with caution.
169
+ get addrInput() {
170
+ return this._addr;
171
+ }
172
+ // type - computed: false, optional: false, required: true
173
+ _type;
174
+ get type() {
175
+ return this.getStringAttribute('type');
176
+ }
177
+ set type(value) {
178
+ this._type = value;
179
+ }
180
+ // Temporarily expose input value. Use with caution.
181
+ get typeInput() {
182
+ return this._type;
183
+ }
184
+ }
185
+ export class InstanceAddressesNetList extends cdktf.ComplexList {
186
+ terraformResource;
187
+ terraformAttribute;
188
+ wrapsSet;
189
+ internalValue;
190
+ /**
191
+ * @param terraformResource The parent resource
192
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
193
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
194
+ */
195
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
196
+ super(terraformResource, terraformAttribute, wrapsSet);
197
+ this.terraformResource = terraformResource;
198
+ this.terraformAttribute = terraformAttribute;
199
+ this.wrapsSet = wrapsSet;
200
+ }
201
+ /**
202
+ * @param index the index of the item to return
203
+ */
204
+ get(index) {
205
+ return new InstanceAddressesNetOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
206
+ }
207
+ }
208
+ export function instanceAddressesToTerraform(struct) {
209
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
210
+ return struct;
211
+ }
212
+ if (cdktf.isComplexElement(struct)) {
213
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
214
+ }
215
+ return {
216
+ net: cdktf.listMapper(instanceAddressesNetToTerraform, true)(struct.net),
217
+ };
218
+ }
219
+ export function instanceAddressesToHclTerraform(struct) {
220
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
221
+ return struct;
222
+ }
223
+ if (cdktf.isComplexElement(struct)) {
224
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
225
+ }
226
+ const attrs = {
227
+ net: {
228
+ value: cdktf.listMapperHcl(instanceAddressesNetToHclTerraform, true)(struct.net),
229
+ isBlock: true,
230
+ type: "list",
231
+ storageClassType: "InstanceAddressesNetList",
232
+ },
233
+ };
234
+ // remove undefined attributes
235
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
236
+ }
237
+ export class InstanceAddressesOutputReference extends cdktf.ComplexObject {
238
+ isEmptyObject = false;
239
+ resolvableValue;
240
+ /**
241
+ * @param terraformResource The parent resource
242
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
243
+ * @param complexObjectIndex the index of this item in the list
244
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
245
+ */
246
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
247
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
248
+ }
249
+ get internalValue() {
250
+ if (this.resolvableValue) {
251
+ return this.resolvableValue;
252
+ }
253
+ let hasAnyValues = this.isEmptyObject;
254
+ const internalValueResult = {};
255
+ if (this._net?.internalValue !== undefined) {
256
+ hasAnyValues = true;
257
+ internalValueResult.net = this._net?.internalValue;
258
+ }
259
+ return hasAnyValues ? internalValueResult : undefined;
260
+ }
261
+ set internalValue(value) {
262
+ if (value === undefined) {
263
+ this.isEmptyObject = false;
264
+ this.resolvableValue = undefined;
265
+ this._net.internalValue = undefined;
266
+ }
267
+ else if (cdktf.Tokenization.isResolvable(value)) {
268
+ this.isEmptyObject = false;
269
+ this.resolvableValue = value;
270
+ }
271
+ else {
272
+ this.isEmptyObject = Object.keys(value).length === 0;
273
+ this.resolvableValue = undefined;
274
+ this._net.internalValue = value.net;
275
+ }
276
+ }
277
+ // net - computed: false, optional: false, required: true
278
+ _net = new InstanceAddressesNetList(this, "net", false);
279
+ get net() {
280
+ return this._net;
281
+ }
282
+ putNet(value) {
283
+ this._net.internalValue = value;
284
+ }
285
+ // Temporarily expose input value. Use with caution.
286
+ get netInput() {
287
+ return this._net.internalValue;
288
+ }
289
+ }
290
+ export class InstanceAddressesList extends cdktf.ComplexList {
291
+ terraformResource;
292
+ terraformAttribute;
293
+ wrapsSet;
294
+ internalValue;
295
+ /**
296
+ * @param terraformResource The parent resource
297
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
298
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
299
+ */
300
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
301
+ super(terraformResource, terraformAttribute, wrapsSet);
302
+ this.terraformResource = terraformResource;
303
+ this.terraformAttribute = terraformAttribute;
304
+ this.wrapsSet = wrapsSet;
305
+ }
306
+ /**
307
+ * @param index the index of the item to return
308
+ */
309
+ get(index) {
310
+ return new InstanceAddressesOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
311
+ }
312
+ }
313
+ export function instanceConfigurationToTerraform(struct) {
314
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
315
+ return struct;
316
+ }
317
+ if (cdktf.isComplexElement(struct)) {
318
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
319
+ }
320
+ return {
321
+ key: cdktf.stringToTerraform(struct.key),
322
+ value: cdktf.stringToTerraform(struct.value),
323
+ };
324
+ }
325
+ export function instanceConfigurationToHclTerraform(struct) {
326
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
327
+ return struct;
328
+ }
329
+ if (cdktf.isComplexElement(struct)) {
330
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
331
+ }
332
+ const attrs = {
333
+ key: {
334
+ value: cdktf.stringToHclTerraform(struct.key),
335
+ isBlock: false,
336
+ type: "simple",
337
+ storageClassType: "string",
338
+ },
339
+ value: {
340
+ value: cdktf.stringToHclTerraform(struct.value),
341
+ isBlock: false,
342
+ type: "simple",
343
+ storageClassType: "string",
344
+ },
345
+ };
346
+ // remove undefined attributes
347
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
348
+ }
349
+ export class InstanceConfigurationOutputReference extends cdktf.ComplexObject {
350
+ isEmptyObject = false;
351
+ resolvableValue;
352
+ /**
353
+ * @param terraformResource The parent resource
354
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
355
+ * @param complexObjectIndex the index of this item in the list
356
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
357
+ */
358
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
359
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
360
+ }
361
+ get internalValue() {
362
+ if (this.resolvableValue) {
363
+ return this.resolvableValue;
364
+ }
365
+ let hasAnyValues = this.isEmptyObject;
366
+ const internalValueResult = {};
367
+ if (this._key !== undefined) {
368
+ hasAnyValues = true;
369
+ internalValueResult.key = this._key;
370
+ }
371
+ if (this._value !== undefined) {
372
+ hasAnyValues = true;
373
+ internalValueResult.value = this._value;
374
+ }
375
+ return hasAnyValues ? internalValueResult : undefined;
376
+ }
377
+ set internalValue(value) {
378
+ if (value === undefined) {
379
+ this.isEmptyObject = false;
380
+ this.resolvableValue = undefined;
381
+ this._key = undefined;
382
+ this._value = undefined;
383
+ }
384
+ else if (cdktf.Tokenization.isResolvable(value)) {
385
+ this.isEmptyObject = false;
386
+ this.resolvableValue = value;
387
+ }
388
+ else {
389
+ this.isEmptyObject = Object.keys(value).length === 0;
390
+ this.resolvableValue = undefined;
391
+ this._key = value.key;
392
+ this._value = value.value;
393
+ }
394
+ }
395
+ // key - computed: false, optional: false, required: true
396
+ _key;
397
+ get key() {
398
+ return this.getStringAttribute('key');
399
+ }
400
+ set key(value) {
401
+ this._key = value;
402
+ }
403
+ // Temporarily expose input value. Use with caution.
404
+ get keyInput() {
405
+ return this._key;
406
+ }
407
+ // value - computed: false, optional: false, required: true
408
+ _value;
409
+ get value() {
410
+ return this.getStringAttribute('value');
411
+ }
412
+ set value(value) {
413
+ this._value = value;
414
+ }
415
+ // Temporarily expose input value. Use with caution.
416
+ get valueInput() {
417
+ return this._value;
418
+ }
419
+ }
420
+ export class InstanceConfigurationList extends cdktf.ComplexList {
421
+ terraformResource;
422
+ terraformAttribute;
423
+ wrapsSet;
424
+ internalValue;
425
+ /**
426
+ * @param terraformResource The parent resource
427
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
428
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
429
+ */
430
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
431
+ super(terraformResource, terraformAttribute, wrapsSet);
432
+ this.terraformResource = terraformResource;
433
+ this.terraformAttribute = terraformAttribute;
434
+ this.wrapsSet = wrapsSet;
435
+ }
436
+ /**
437
+ * @param index the index of the item to return
438
+ */
439
+ get(index) {
440
+ return new InstanceConfigurationOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
441
+ }
442
+ }
443
+ export function instanceInterfaceToTerraform(struct) {
444
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
445
+ return struct;
446
+ }
447
+ if (cdktf.isComplexElement(struct)) {
448
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
449
+ }
450
+ return {
451
+ existing_fip_id: cdktf.stringToTerraform(struct.existingFipId),
452
+ fip_source: cdktf.stringToTerraform(struct.fipSource),
453
+ ip_address: cdktf.stringToTerraform(struct.ipAddress),
454
+ network_id: cdktf.stringToTerraform(struct.networkId),
455
+ order: cdktf.numberToTerraform(struct.order),
456
+ port_id: cdktf.stringToTerraform(struct.portId),
457
+ port_security_disabled: cdktf.booleanToTerraform(struct.portSecurityDisabled),
458
+ security_groups: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.securityGroups),
459
+ subnet_id: cdktf.stringToTerraform(struct.subnetId),
460
+ type: cdktf.stringToTerraform(struct.type),
461
+ };
462
+ }
463
+ export function instanceInterfaceToHclTerraform(struct) {
464
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
465
+ return struct;
466
+ }
467
+ if (cdktf.isComplexElement(struct)) {
468
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
469
+ }
470
+ const attrs = {
471
+ existing_fip_id: {
472
+ value: cdktf.stringToHclTerraform(struct.existingFipId),
473
+ isBlock: false,
474
+ type: "simple",
475
+ storageClassType: "string",
476
+ },
477
+ fip_source: {
478
+ value: cdktf.stringToHclTerraform(struct.fipSource),
479
+ isBlock: false,
480
+ type: "simple",
481
+ storageClassType: "string",
482
+ },
483
+ ip_address: {
484
+ value: cdktf.stringToHclTerraform(struct.ipAddress),
485
+ isBlock: false,
486
+ type: "simple",
487
+ storageClassType: "string",
488
+ },
489
+ network_id: {
490
+ value: cdktf.stringToHclTerraform(struct.networkId),
491
+ isBlock: false,
492
+ type: "simple",
493
+ storageClassType: "string",
494
+ },
495
+ order: {
496
+ value: cdktf.numberToHclTerraform(struct.order),
497
+ isBlock: false,
498
+ type: "simple",
499
+ storageClassType: "number",
500
+ },
501
+ port_id: {
502
+ value: cdktf.stringToHclTerraform(struct.portId),
503
+ isBlock: false,
504
+ type: "simple",
505
+ storageClassType: "string",
506
+ },
507
+ port_security_disabled: {
508
+ value: cdktf.booleanToHclTerraform(struct.portSecurityDisabled),
509
+ isBlock: false,
510
+ type: "simple",
511
+ storageClassType: "boolean",
512
+ },
513
+ security_groups: {
514
+ value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.securityGroups),
515
+ isBlock: false,
516
+ type: "list",
517
+ storageClassType: "stringList",
518
+ },
519
+ subnet_id: {
520
+ value: cdktf.stringToHclTerraform(struct.subnetId),
521
+ isBlock: false,
522
+ type: "simple",
523
+ storageClassType: "string",
524
+ },
525
+ type: {
526
+ value: cdktf.stringToHclTerraform(struct.type),
527
+ isBlock: false,
528
+ type: "simple",
529
+ storageClassType: "string",
530
+ },
531
+ };
532
+ // remove undefined attributes
533
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
534
+ }
535
+ export class InstanceInterfaceOutputReference extends cdktf.ComplexObject {
536
+ isEmptyObject = false;
537
+ resolvableValue;
538
+ /**
539
+ * @param terraformResource The parent resource
540
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
541
+ * @param complexObjectIndex the index of this item in the list
542
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
543
+ */
544
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
545
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
546
+ }
547
+ get internalValue() {
548
+ if (this.resolvableValue) {
549
+ return this.resolvableValue;
550
+ }
551
+ let hasAnyValues = this.isEmptyObject;
552
+ const internalValueResult = {};
553
+ if (this._existingFipId !== undefined) {
554
+ hasAnyValues = true;
555
+ internalValueResult.existingFipId = this._existingFipId;
556
+ }
557
+ if (this._fipSource !== undefined) {
558
+ hasAnyValues = true;
559
+ internalValueResult.fipSource = this._fipSource;
560
+ }
561
+ if (this._ipAddress !== undefined) {
562
+ hasAnyValues = true;
563
+ internalValueResult.ipAddress = this._ipAddress;
564
+ }
565
+ if (this._networkId !== undefined) {
566
+ hasAnyValues = true;
567
+ internalValueResult.networkId = this._networkId;
568
+ }
569
+ if (this._order !== undefined) {
570
+ hasAnyValues = true;
571
+ internalValueResult.order = this._order;
572
+ }
573
+ if (this._portId !== undefined) {
574
+ hasAnyValues = true;
575
+ internalValueResult.portId = this._portId;
576
+ }
577
+ if (this._portSecurityDisabled !== undefined) {
578
+ hasAnyValues = true;
579
+ internalValueResult.portSecurityDisabled = this._portSecurityDisabled;
580
+ }
581
+ if (this._securityGroups !== undefined) {
582
+ hasAnyValues = true;
583
+ internalValueResult.securityGroups = this._securityGroups;
584
+ }
585
+ if (this._subnetId !== undefined) {
586
+ hasAnyValues = true;
587
+ internalValueResult.subnetId = this._subnetId;
588
+ }
589
+ if (this._type !== undefined) {
590
+ hasAnyValues = true;
591
+ internalValueResult.type = this._type;
592
+ }
593
+ return hasAnyValues ? internalValueResult : undefined;
594
+ }
595
+ set internalValue(value) {
596
+ if (value === undefined) {
597
+ this.isEmptyObject = false;
598
+ this.resolvableValue = undefined;
599
+ this._existingFipId = undefined;
600
+ this._fipSource = undefined;
601
+ this._ipAddress = undefined;
602
+ this._networkId = undefined;
603
+ this._order = undefined;
604
+ this._portId = undefined;
605
+ this._portSecurityDisabled = undefined;
606
+ this._securityGroups = undefined;
607
+ this._subnetId = undefined;
608
+ this._type = undefined;
609
+ }
610
+ else if (cdktf.Tokenization.isResolvable(value)) {
611
+ this.isEmptyObject = false;
612
+ this.resolvableValue = value;
613
+ }
614
+ else {
615
+ this.isEmptyObject = Object.keys(value).length === 0;
616
+ this.resolvableValue = undefined;
617
+ this._existingFipId = value.existingFipId;
618
+ this._fipSource = value.fipSource;
619
+ this._ipAddress = value.ipAddress;
620
+ this._networkId = value.networkId;
621
+ this._order = value.order;
622
+ this._portId = value.portId;
623
+ this._portSecurityDisabled = value.portSecurityDisabled;
624
+ this._securityGroups = value.securityGroups;
625
+ this._subnetId = value.subnetId;
626
+ this._type = value.type;
627
+ }
628
+ }
629
+ // existing_fip_id - computed: false, optional: true, required: false
630
+ _existingFipId;
631
+ get existingFipId() {
632
+ return this.getStringAttribute('existing_fip_id');
633
+ }
634
+ set existingFipId(value) {
635
+ this._existingFipId = value;
636
+ }
637
+ resetExistingFipId() {
638
+ this._existingFipId = undefined;
639
+ }
640
+ // Temporarily expose input value. Use with caution.
641
+ get existingFipIdInput() {
642
+ return this._existingFipId;
643
+ }
644
+ // fip_source - computed: false, optional: true, required: false
645
+ _fipSource;
646
+ get fipSource() {
647
+ return this.getStringAttribute('fip_source');
648
+ }
649
+ set fipSource(value) {
650
+ this._fipSource = value;
651
+ }
652
+ resetFipSource() {
653
+ this._fipSource = undefined;
654
+ }
655
+ // Temporarily expose input value. Use with caution.
656
+ get fipSourceInput() {
657
+ return this._fipSource;
658
+ }
659
+ // ip_address - computed: true, optional: true, required: false
660
+ _ipAddress;
661
+ get ipAddress() {
662
+ return this.getStringAttribute('ip_address');
663
+ }
664
+ set ipAddress(value) {
665
+ this._ipAddress = value;
666
+ }
667
+ resetIpAddress() {
668
+ this._ipAddress = undefined;
669
+ }
670
+ // Temporarily expose input value. Use with caution.
671
+ get ipAddressInput() {
672
+ return this._ipAddress;
673
+ }
674
+ // network_id - computed: true, optional: true, required: false
675
+ _networkId;
676
+ get networkId() {
677
+ return this.getStringAttribute('network_id');
678
+ }
679
+ set networkId(value) {
680
+ this._networkId = value;
681
+ }
682
+ resetNetworkId() {
683
+ this._networkId = undefined;
684
+ }
685
+ // Temporarily expose input value. Use with caution.
686
+ get networkIdInput() {
687
+ return this._networkId;
688
+ }
689
+ // order - computed: true, optional: true, required: false
690
+ _order;
691
+ get order() {
692
+ return this.getNumberAttribute('order');
693
+ }
694
+ set order(value) {
695
+ this._order = value;
696
+ }
697
+ resetOrder() {
698
+ this._order = undefined;
699
+ }
700
+ // Temporarily expose input value. Use with caution.
701
+ get orderInput() {
702
+ return this._order;
703
+ }
704
+ // port_id - computed: true, optional: true, required: false
705
+ _portId;
706
+ get portId() {
707
+ return this.getStringAttribute('port_id');
708
+ }
709
+ set portId(value) {
710
+ this._portId = value;
711
+ }
712
+ resetPortId() {
713
+ this._portId = undefined;
714
+ }
715
+ // Temporarily expose input value. Use with caution.
716
+ get portIdInput() {
717
+ return this._portId;
718
+ }
719
+ // port_security_disabled - computed: false, optional: true, required: false
720
+ _portSecurityDisabled;
721
+ get portSecurityDisabled() {
722
+ return this.getBooleanAttribute('port_security_disabled');
723
+ }
724
+ set portSecurityDisabled(value) {
725
+ this._portSecurityDisabled = value;
726
+ }
727
+ resetPortSecurityDisabled() {
728
+ this._portSecurityDisabled = undefined;
729
+ }
730
+ // Temporarily expose input value. Use with caution.
731
+ get portSecurityDisabledInput() {
732
+ return this._portSecurityDisabled;
733
+ }
734
+ // security_groups - computed: false, optional: true, required: false
735
+ _securityGroups;
736
+ get securityGroups() {
737
+ return this.getListAttribute('security_groups');
738
+ }
739
+ set securityGroups(value) {
740
+ this._securityGroups = value;
741
+ }
742
+ resetSecurityGroups() {
743
+ this._securityGroups = undefined;
744
+ }
745
+ // Temporarily expose input value. Use with caution.
746
+ get securityGroupsInput() {
747
+ return this._securityGroups;
748
+ }
749
+ // subnet_id - computed: true, optional: true, required: false
750
+ _subnetId;
751
+ get subnetId() {
752
+ return this.getStringAttribute('subnet_id');
753
+ }
754
+ set subnetId(value) {
755
+ this._subnetId = value;
756
+ }
757
+ resetSubnetId() {
758
+ this._subnetId = undefined;
759
+ }
760
+ // Temporarily expose input value. Use with caution.
761
+ get subnetIdInput() {
762
+ return this._subnetId;
763
+ }
764
+ // type - computed: false, optional: true, required: false
765
+ _type;
766
+ get type() {
767
+ return this.getStringAttribute('type');
768
+ }
769
+ set type(value) {
770
+ this._type = value;
771
+ }
772
+ resetType() {
773
+ this._type = undefined;
774
+ }
775
+ // Temporarily expose input value. Use with caution.
776
+ get typeInput() {
777
+ return this._type;
778
+ }
779
+ }
780
+ export class InstanceInterfaceList extends cdktf.ComplexList {
781
+ terraformResource;
782
+ terraformAttribute;
783
+ wrapsSet;
784
+ internalValue;
785
+ /**
786
+ * @param terraformResource The parent resource
787
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
788
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
789
+ */
790
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
791
+ super(terraformResource, terraformAttribute, wrapsSet);
792
+ this.terraformResource = terraformResource;
793
+ this.terraformAttribute = terraformAttribute;
794
+ this.wrapsSet = wrapsSet;
795
+ }
796
+ /**
797
+ * @param index the index of the item to return
798
+ */
799
+ get(index) {
800
+ return new InstanceInterfaceOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
801
+ }
802
+ }
803
+ export function instanceMetadataToTerraform(struct) {
804
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
805
+ return struct;
806
+ }
807
+ if (cdktf.isComplexElement(struct)) {
808
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
809
+ }
810
+ return {
811
+ key: cdktf.stringToTerraform(struct.key),
812
+ value: cdktf.stringToTerraform(struct.value),
813
+ };
814
+ }
815
+ export function instanceMetadataToHclTerraform(struct) {
816
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
817
+ return struct;
818
+ }
819
+ if (cdktf.isComplexElement(struct)) {
820
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
821
+ }
822
+ const attrs = {
823
+ key: {
824
+ value: cdktf.stringToHclTerraform(struct.key),
825
+ isBlock: false,
826
+ type: "simple",
827
+ storageClassType: "string",
828
+ },
829
+ value: {
830
+ value: cdktf.stringToHclTerraform(struct.value),
831
+ isBlock: false,
832
+ type: "simple",
833
+ storageClassType: "string",
834
+ },
835
+ };
836
+ // remove undefined attributes
837
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
838
+ }
839
+ export class InstanceMetadataOutputReference extends cdktf.ComplexObject {
840
+ isEmptyObject = false;
841
+ resolvableValue;
842
+ /**
843
+ * @param terraformResource The parent resource
844
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
845
+ * @param complexObjectIndex the index of this item in the list
846
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
847
+ */
848
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
849
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
850
+ }
851
+ get internalValue() {
852
+ if (this.resolvableValue) {
853
+ return this.resolvableValue;
854
+ }
855
+ let hasAnyValues = this.isEmptyObject;
856
+ const internalValueResult = {};
857
+ if (this._key !== undefined) {
858
+ hasAnyValues = true;
859
+ internalValueResult.key = this._key;
860
+ }
861
+ if (this._value !== undefined) {
862
+ hasAnyValues = true;
863
+ internalValueResult.value = this._value;
864
+ }
865
+ return hasAnyValues ? internalValueResult : undefined;
866
+ }
867
+ set internalValue(value) {
868
+ if (value === undefined) {
869
+ this.isEmptyObject = false;
870
+ this.resolvableValue = undefined;
871
+ this._key = undefined;
872
+ this._value = undefined;
873
+ }
874
+ else if (cdktf.Tokenization.isResolvable(value)) {
875
+ this.isEmptyObject = false;
876
+ this.resolvableValue = value;
877
+ }
878
+ else {
879
+ this.isEmptyObject = Object.keys(value).length === 0;
880
+ this.resolvableValue = undefined;
881
+ this._key = value.key;
882
+ this._value = value.value;
883
+ }
884
+ }
885
+ // key - computed: false, optional: false, required: true
886
+ _key;
887
+ get key() {
888
+ return this.getStringAttribute('key');
889
+ }
890
+ set key(value) {
891
+ this._key = value;
892
+ }
893
+ // Temporarily expose input value. Use with caution.
894
+ get keyInput() {
895
+ return this._key;
896
+ }
897
+ // value - computed: false, optional: false, required: true
898
+ _value;
899
+ get value() {
900
+ return this.getStringAttribute('value');
901
+ }
902
+ set value(value) {
903
+ this._value = value;
904
+ }
905
+ // Temporarily expose input value. Use with caution.
906
+ get valueInput() {
907
+ return this._value;
908
+ }
909
+ }
910
+ export class InstanceMetadataList extends cdktf.ComplexList {
911
+ terraformResource;
912
+ terraformAttribute;
913
+ wrapsSet;
914
+ internalValue;
915
+ /**
916
+ * @param terraformResource The parent resource
917
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
918
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
919
+ */
920
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
921
+ super(terraformResource, terraformAttribute, wrapsSet);
922
+ this.terraformResource = terraformResource;
923
+ this.terraformAttribute = terraformAttribute;
924
+ this.wrapsSet = wrapsSet;
925
+ }
926
+ /**
927
+ * @param index the index of the item to return
928
+ */
929
+ get(index) {
930
+ return new InstanceMetadataOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
931
+ }
932
+ }
933
+ export function instanceVolumeToTerraform(struct) {
934
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
935
+ return struct;
936
+ }
937
+ if (cdktf.isComplexElement(struct)) {
938
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
939
+ }
940
+ return {
941
+ attachment_tag: cdktf.stringToTerraform(struct.attachmentTag),
942
+ boot_index: cdktf.numberToTerraform(struct.bootIndex),
943
+ delete_on_termination: cdktf.booleanToTerraform(struct.deleteOnTermination),
944
+ id: cdktf.stringToTerraform(struct.id),
945
+ image_id: cdktf.stringToTerraform(struct.imageId),
946
+ name: cdktf.stringToTerraform(struct.name),
947
+ size: cdktf.numberToTerraform(struct.size),
948
+ source: cdktf.stringToTerraform(struct.source),
949
+ type_name: cdktf.stringToTerraform(struct.typeName),
950
+ volume_id: cdktf.stringToTerraform(struct.volumeId),
951
+ };
952
+ }
953
+ export function instanceVolumeToHclTerraform(struct) {
954
+ if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
955
+ return struct;
956
+ }
957
+ if (cdktf.isComplexElement(struct)) {
958
+ throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
959
+ }
960
+ const attrs = {
961
+ attachment_tag: {
962
+ value: cdktf.stringToHclTerraform(struct.attachmentTag),
963
+ isBlock: false,
964
+ type: "simple",
965
+ storageClassType: "string",
966
+ },
967
+ boot_index: {
968
+ value: cdktf.numberToHclTerraform(struct.bootIndex),
969
+ isBlock: false,
970
+ type: "simple",
971
+ storageClassType: "number",
972
+ },
973
+ delete_on_termination: {
974
+ value: cdktf.booleanToHclTerraform(struct.deleteOnTermination),
975
+ isBlock: false,
976
+ type: "simple",
977
+ storageClassType: "boolean",
978
+ },
979
+ id: {
980
+ value: cdktf.stringToHclTerraform(struct.id),
981
+ isBlock: false,
982
+ type: "simple",
983
+ storageClassType: "string",
984
+ },
985
+ image_id: {
986
+ value: cdktf.stringToHclTerraform(struct.imageId),
987
+ isBlock: false,
988
+ type: "simple",
989
+ storageClassType: "string",
990
+ },
991
+ name: {
992
+ value: cdktf.stringToHclTerraform(struct.name),
993
+ isBlock: false,
994
+ type: "simple",
995
+ storageClassType: "string",
996
+ },
997
+ size: {
998
+ value: cdktf.numberToHclTerraform(struct.size),
999
+ isBlock: false,
1000
+ type: "simple",
1001
+ storageClassType: "number",
1002
+ },
1003
+ source: {
1004
+ value: cdktf.stringToHclTerraform(struct.source),
1005
+ isBlock: false,
1006
+ type: "simple",
1007
+ storageClassType: "string",
1008
+ },
1009
+ type_name: {
1010
+ value: cdktf.stringToHclTerraform(struct.typeName),
1011
+ isBlock: false,
1012
+ type: "simple",
1013
+ storageClassType: "string",
1014
+ },
1015
+ volume_id: {
1016
+ value: cdktf.stringToHclTerraform(struct.volumeId),
1017
+ isBlock: false,
1018
+ type: "simple",
1019
+ storageClassType: "string",
1020
+ },
1021
+ };
1022
+ // remove undefined attributes
1023
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
1024
+ }
1025
+ export class InstanceVolumeOutputReference extends cdktf.ComplexObject {
1026
+ isEmptyObject = false;
1027
+ resolvableValue;
1028
+ /**
1029
+ * @param terraformResource The parent resource
1030
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
1031
+ * @param complexObjectIndex the index of this item in the list
1032
+ * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
1033
+ */
1034
+ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
1035
+ super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
1036
+ }
1037
+ get internalValue() {
1038
+ if (this.resolvableValue) {
1039
+ return this.resolvableValue;
1040
+ }
1041
+ let hasAnyValues = this.isEmptyObject;
1042
+ const internalValueResult = {};
1043
+ if (this._attachmentTag !== undefined) {
1044
+ hasAnyValues = true;
1045
+ internalValueResult.attachmentTag = this._attachmentTag;
1046
+ }
1047
+ if (this._bootIndex !== undefined) {
1048
+ hasAnyValues = true;
1049
+ internalValueResult.bootIndex = this._bootIndex;
1050
+ }
1051
+ if (this._deleteOnTermination !== undefined) {
1052
+ hasAnyValues = true;
1053
+ internalValueResult.deleteOnTermination = this._deleteOnTermination;
1054
+ }
1055
+ if (this._id !== undefined) {
1056
+ hasAnyValues = true;
1057
+ internalValueResult.id = this._id;
1058
+ }
1059
+ if (this._imageId !== undefined) {
1060
+ hasAnyValues = true;
1061
+ internalValueResult.imageId = this._imageId;
1062
+ }
1063
+ if (this._name !== undefined) {
1064
+ hasAnyValues = true;
1065
+ internalValueResult.name = this._name;
1066
+ }
1067
+ if (this._size !== undefined) {
1068
+ hasAnyValues = true;
1069
+ internalValueResult.size = this._size;
1070
+ }
1071
+ if (this._source !== undefined) {
1072
+ hasAnyValues = true;
1073
+ internalValueResult.source = this._source;
1074
+ }
1075
+ if (this._typeName !== undefined) {
1076
+ hasAnyValues = true;
1077
+ internalValueResult.typeName = this._typeName;
1078
+ }
1079
+ if (this._volumeId !== undefined) {
1080
+ hasAnyValues = true;
1081
+ internalValueResult.volumeId = this._volumeId;
1082
+ }
1083
+ return hasAnyValues ? internalValueResult : undefined;
1084
+ }
1085
+ set internalValue(value) {
1086
+ if (value === undefined) {
1087
+ this.isEmptyObject = false;
1088
+ this.resolvableValue = undefined;
1089
+ this._attachmentTag = undefined;
1090
+ this._bootIndex = undefined;
1091
+ this._deleteOnTermination = undefined;
1092
+ this._id = undefined;
1093
+ this._imageId = undefined;
1094
+ this._name = undefined;
1095
+ this._size = undefined;
1096
+ this._source = undefined;
1097
+ this._typeName = undefined;
1098
+ this._volumeId = undefined;
1099
+ }
1100
+ else if (cdktf.Tokenization.isResolvable(value)) {
1101
+ this.isEmptyObject = false;
1102
+ this.resolvableValue = value;
1103
+ }
1104
+ else {
1105
+ this.isEmptyObject = Object.keys(value).length === 0;
1106
+ this.resolvableValue = undefined;
1107
+ this._attachmentTag = value.attachmentTag;
1108
+ this._bootIndex = value.bootIndex;
1109
+ this._deleteOnTermination = value.deleteOnTermination;
1110
+ this._id = value.id;
1111
+ this._imageId = value.imageId;
1112
+ this._name = value.name;
1113
+ this._size = value.size;
1114
+ this._source = value.source;
1115
+ this._typeName = value.typeName;
1116
+ this._volumeId = value.volumeId;
1117
+ }
1118
+ }
1119
+ // attachment_tag - computed: false, optional: true, required: false
1120
+ _attachmentTag;
1121
+ get attachmentTag() {
1122
+ return this.getStringAttribute('attachment_tag');
1123
+ }
1124
+ set attachmentTag(value) {
1125
+ this._attachmentTag = value;
1126
+ }
1127
+ resetAttachmentTag() {
1128
+ this._attachmentTag = undefined;
1129
+ }
1130
+ // Temporarily expose input value. Use with caution.
1131
+ get attachmentTagInput() {
1132
+ return this._attachmentTag;
1133
+ }
1134
+ // boot_index - computed: false, optional: true, required: false
1135
+ _bootIndex;
1136
+ get bootIndex() {
1137
+ return this.getNumberAttribute('boot_index');
1138
+ }
1139
+ set bootIndex(value) {
1140
+ this._bootIndex = value;
1141
+ }
1142
+ resetBootIndex() {
1143
+ this._bootIndex = undefined;
1144
+ }
1145
+ // Temporarily expose input value. Use with caution.
1146
+ get bootIndexInput() {
1147
+ return this._bootIndex;
1148
+ }
1149
+ // delete_on_termination - computed: true, optional: true, required: false
1150
+ _deleteOnTermination;
1151
+ get deleteOnTermination() {
1152
+ return this.getBooleanAttribute('delete_on_termination');
1153
+ }
1154
+ set deleteOnTermination(value) {
1155
+ this._deleteOnTermination = value;
1156
+ }
1157
+ resetDeleteOnTermination() {
1158
+ this._deleteOnTermination = undefined;
1159
+ }
1160
+ // Temporarily expose input value. Use with caution.
1161
+ get deleteOnTerminationInput() {
1162
+ return this._deleteOnTermination;
1163
+ }
1164
+ // id - computed: true, optional: true, required: false
1165
+ _id;
1166
+ get id() {
1167
+ return this.getStringAttribute('id');
1168
+ }
1169
+ set id(value) {
1170
+ this._id = value;
1171
+ }
1172
+ resetId() {
1173
+ this._id = undefined;
1174
+ }
1175
+ // Temporarily expose input value. Use with caution.
1176
+ get idInput() {
1177
+ return this._id;
1178
+ }
1179
+ // image_id - computed: false, optional: true, required: false
1180
+ _imageId;
1181
+ get imageId() {
1182
+ return this.getStringAttribute('image_id');
1183
+ }
1184
+ set imageId(value) {
1185
+ this._imageId = value;
1186
+ }
1187
+ resetImageId() {
1188
+ this._imageId = undefined;
1189
+ }
1190
+ // Temporarily expose input value. Use with caution.
1191
+ get imageIdInput() {
1192
+ return this._imageId;
1193
+ }
1194
+ // name - computed: false, optional: true, required: false
1195
+ _name;
1196
+ get name() {
1197
+ return this.getStringAttribute('name');
1198
+ }
1199
+ set name(value) {
1200
+ this._name = value;
1201
+ }
1202
+ resetName() {
1203
+ this._name = undefined;
1204
+ }
1205
+ // Temporarily expose input value. Use with caution.
1206
+ get nameInput() {
1207
+ return this._name;
1208
+ }
1209
+ // size - computed: true, optional: true, required: false
1210
+ _size;
1211
+ get size() {
1212
+ return this.getNumberAttribute('size');
1213
+ }
1214
+ set size(value) {
1215
+ this._size = value;
1216
+ }
1217
+ resetSize() {
1218
+ this._size = undefined;
1219
+ }
1220
+ // Temporarily expose input value. Use with caution.
1221
+ get sizeInput() {
1222
+ return this._size;
1223
+ }
1224
+ // source - computed: false, optional: false, required: true
1225
+ _source;
1226
+ get source() {
1227
+ return this.getStringAttribute('source');
1228
+ }
1229
+ set source(value) {
1230
+ this._source = value;
1231
+ }
1232
+ // Temporarily expose input value. Use with caution.
1233
+ get sourceInput() {
1234
+ return this._source;
1235
+ }
1236
+ // type_name - computed: false, optional: true, required: false
1237
+ _typeName;
1238
+ get typeName() {
1239
+ return this.getStringAttribute('type_name');
1240
+ }
1241
+ set typeName(value) {
1242
+ this._typeName = value;
1243
+ }
1244
+ resetTypeName() {
1245
+ this._typeName = undefined;
1246
+ }
1247
+ // Temporarily expose input value. Use with caution.
1248
+ get typeNameInput() {
1249
+ return this._typeName;
1250
+ }
1251
+ // volume_id - computed: false, optional: true, required: false
1252
+ _volumeId;
1253
+ get volumeId() {
1254
+ return this.getStringAttribute('volume_id');
1255
+ }
1256
+ set volumeId(value) {
1257
+ this._volumeId = value;
1258
+ }
1259
+ resetVolumeId() {
1260
+ this._volumeId = undefined;
1261
+ }
1262
+ // Temporarily expose input value. Use with caution.
1263
+ get volumeIdInput() {
1264
+ return this._volumeId;
1265
+ }
1266
+ }
1267
+ export class InstanceVolumeList extends cdktf.ComplexList {
1268
+ terraformResource;
1269
+ terraformAttribute;
1270
+ wrapsSet;
1271
+ internalValue;
1272
+ /**
1273
+ * @param terraformResource The parent resource
1274
+ * @param terraformAttribute The attribute on the parent resource this class is referencing
1275
+ * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
1276
+ */
1277
+ constructor(terraformResource, terraformAttribute, wrapsSet) {
1278
+ super(terraformResource, terraformAttribute, wrapsSet);
1279
+ this.terraformResource = terraformResource;
1280
+ this.terraformAttribute = terraformAttribute;
1281
+ this.wrapsSet = wrapsSet;
1282
+ }
1283
+ /**
1284
+ * @param index the index of the item to return
1285
+ */
1286
+ get(index) {
1287
+ return new InstanceVolumeOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
1288
+ }
1289
+ }
1290
+ /**
1291
+ * Represents a {@link https://registry.terraform.io/providers/edge-center/edgecenter/0.10.4/docs/resources/instance edgecenter_instance}
1292
+ */
1293
+ export class Instance extends cdktf.TerraformResource {
1294
+ // =================
1295
+ // STATIC PROPERTIES
1296
+ // =================
1297
+ static tfResourceType = "edgecenter_instance";
1298
+ // ==============
1299
+ // STATIC Methods
1300
+ // ==============
1301
+ /**
1302
+ * Generates CDKTF code for importing a Instance resource upon running "cdktf plan <stack-name>"
1303
+ * @param scope The scope in which to define this construct
1304
+ * @param importToId The construct id used in the generated config for the Instance to import
1305
+ * @param importFromId The id of the existing Instance that should be imported. Refer to the {@link https://registry.terraform.io/providers/edge-center/edgecenter/0.10.4/docs/resources/instance#import import section} in the documentation of this resource for the id to use
1306
+ * @param provider? Optional instance of the provider where the Instance to import is found
1307
+ */
1308
+ static generateConfigForImport(scope, importToId, importFromId, provider) {
1309
+ return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "edgecenter_instance", importId: importFromId, provider });
1310
+ }
1311
+ // ===========
1312
+ // INITIALIZER
1313
+ // ===========
1314
+ /**
1315
+ * Create a new {@link https://registry.terraform.io/providers/edge-center/edgecenter/0.10.4/docs/resources/instance edgecenter_instance} Resource
1316
+ *
1317
+ * @param scope The scope in which to define this construct
1318
+ * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
1319
+ * @param options InstanceConfig
1320
+ */
1321
+ constructor(scope, id, config) {
1322
+ super(scope, id, {
1323
+ terraformResourceType: 'edgecenter_instance',
1324
+ terraformGeneratorMetadata: {
1325
+ providerName: 'edgecenter',
1326
+ providerVersion: '0.10.4',
1327
+ providerVersionConstraint: '0.10.4'
1328
+ },
1329
+ provider: config.provider,
1330
+ dependsOn: config.dependsOn,
1331
+ count: config.count,
1332
+ lifecycle: config.lifecycle,
1333
+ provisioners: config.provisioners,
1334
+ connection: config.connection,
1335
+ forEach: config.forEach
1336
+ });
1337
+ this._allowAppPorts = config.allowAppPorts;
1338
+ this._flavor = config.flavor;
1339
+ this._flavorId = config.flavorId;
1340
+ this._id = config.id;
1341
+ this._keypairName = config.keypairName;
1342
+ this._lastUpdated = config.lastUpdated;
1343
+ this._metadataMap = config.metadataMap;
1344
+ this._name = config.name;
1345
+ this._nameTemplate = config.nameTemplate;
1346
+ this._nameTemplates = config.nameTemplates;
1347
+ this._password = config.password;
1348
+ this._projectId = config.projectId;
1349
+ this._projectName = config.projectName;
1350
+ this._regionId = config.regionId;
1351
+ this._regionName = config.regionName;
1352
+ this._serverGroup = config.serverGroup;
1353
+ this._status = config.status;
1354
+ this._userData = config.userData;
1355
+ this._userdata = config.userdata;
1356
+ this._username = config.username;
1357
+ this._vmState = config.vmState;
1358
+ this._addresses.internalValue = config.addresses;
1359
+ this._configuration.internalValue = config.configuration;
1360
+ this._interface.internalValue = config.interface;
1361
+ this._metadata.internalValue = config.metadata;
1362
+ this._volume.internalValue = config.volume;
1363
+ }
1364
+ // ==========
1365
+ // ATTRIBUTES
1366
+ // ==========
1367
+ // allow_app_ports - computed: false, optional: true, required: false
1368
+ _allowAppPorts;
1369
+ get allowAppPorts() {
1370
+ return this.getBooleanAttribute('allow_app_ports');
1371
+ }
1372
+ set allowAppPorts(value) {
1373
+ this._allowAppPorts = value;
1374
+ }
1375
+ resetAllowAppPorts() {
1376
+ this._allowAppPorts = undefined;
1377
+ }
1378
+ // Temporarily expose input value. Use with caution.
1379
+ get allowAppPortsInput() {
1380
+ return this._allowAppPorts;
1381
+ }
1382
+ // flavor - computed: true, optional: true, required: false
1383
+ _flavor;
1384
+ get flavor() {
1385
+ return this.getStringMapAttribute('flavor');
1386
+ }
1387
+ set flavor(value) {
1388
+ this._flavor = value;
1389
+ }
1390
+ resetFlavor() {
1391
+ this._flavor = undefined;
1392
+ }
1393
+ // Temporarily expose input value. Use with caution.
1394
+ get flavorInput() {
1395
+ return this._flavor;
1396
+ }
1397
+ // flavor_id - computed: false, optional: false, required: true
1398
+ _flavorId;
1399
+ get flavorId() {
1400
+ return this.getStringAttribute('flavor_id');
1401
+ }
1402
+ set flavorId(value) {
1403
+ this._flavorId = value;
1404
+ }
1405
+ // Temporarily expose input value. Use with caution.
1406
+ get flavorIdInput() {
1407
+ return this._flavorId;
1408
+ }
1409
+ // id - computed: true, optional: true, required: false
1410
+ _id;
1411
+ get id() {
1412
+ return this.getStringAttribute('id');
1413
+ }
1414
+ set id(value) {
1415
+ this._id = value;
1416
+ }
1417
+ resetId() {
1418
+ this._id = undefined;
1419
+ }
1420
+ // Temporarily expose input value. Use with caution.
1421
+ get idInput() {
1422
+ return this._id;
1423
+ }
1424
+ // keypair_name - computed: false, optional: true, required: false
1425
+ _keypairName;
1426
+ get keypairName() {
1427
+ return this.getStringAttribute('keypair_name');
1428
+ }
1429
+ set keypairName(value) {
1430
+ this._keypairName = value;
1431
+ }
1432
+ resetKeypairName() {
1433
+ this._keypairName = undefined;
1434
+ }
1435
+ // Temporarily expose input value. Use with caution.
1436
+ get keypairNameInput() {
1437
+ return this._keypairName;
1438
+ }
1439
+ // last_updated - computed: true, optional: true, required: false
1440
+ _lastUpdated;
1441
+ get lastUpdated() {
1442
+ return this.getStringAttribute('last_updated');
1443
+ }
1444
+ set lastUpdated(value) {
1445
+ this._lastUpdated = value;
1446
+ }
1447
+ resetLastUpdated() {
1448
+ this._lastUpdated = undefined;
1449
+ }
1450
+ // Temporarily expose input value. Use with caution.
1451
+ get lastUpdatedInput() {
1452
+ return this._lastUpdated;
1453
+ }
1454
+ // metadata_map - computed: false, optional: true, required: false
1455
+ _metadataMap;
1456
+ get metadataMap() {
1457
+ return this.getStringMapAttribute('metadata_map');
1458
+ }
1459
+ set metadataMap(value) {
1460
+ this._metadataMap = value;
1461
+ }
1462
+ resetMetadataMap() {
1463
+ this._metadataMap = undefined;
1464
+ }
1465
+ // Temporarily expose input value. Use with caution.
1466
+ get metadataMapInput() {
1467
+ return this._metadataMap;
1468
+ }
1469
+ // name - computed: true, optional: true, required: false
1470
+ _name;
1471
+ get name() {
1472
+ return this.getStringAttribute('name');
1473
+ }
1474
+ set name(value) {
1475
+ this._name = value;
1476
+ }
1477
+ resetName() {
1478
+ this._name = undefined;
1479
+ }
1480
+ // Temporarily expose input value. Use with caution.
1481
+ get nameInput() {
1482
+ return this._name;
1483
+ }
1484
+ // name_template - computed: false, optional: true, required: false
1485
+ _nameTemplate;
1486
+ get nameTemplate() {
1487
+ return this.getStringAttribute('name_template');
1488
+ }
1489
+ set nameTemplate(value) {
1490
+ this._nameTemplate = value;
1491
+ }
1492
+ resetNameTemplate() {
1493
+ this._nameTemplate = undefined;
1494
+ }
1495
+ // Temporarily expose input value. Use with caution.
1496
+ get nameTemplateInput() {
1497
+ return this._nameTemplate;
1498
+ }
1499
+ // name_templates - computed: false, optional: true, required: false
1500
+ _nameTemplates;
1501
+ get nameTemplates() {
1502
+ return this.getListAttribute('name_templates');
1503
+ }
1504
+ set nameTemplates(value) {
1505
+ this._nameTemplates = value;
1506
+ }
1507
+ resetNameTemplates() {
1508
+ this._nameTemplates = undefined;
1509
+ }
1510
+ // Temporarily expose input value. Use with caution.
1511
+ get nameTemplatesInput() {
1512
+ return this._nameTemplates;
1513
+ }
1514
+ // password - computed: false, optional: true, required: false
1515
+ _password;
1516
+ get password() {
1517
+ return this.getStringAttribute('password');
1518
+ }
1519
+ set password(value) {
1520
+ this._password = value;
1521
+ }
1522
+ resetPassword() {
1523
+ this._password = undefined;
1524
+ }
1525
+ // Temporarily expose input value. Use with caution.
1526
+ get passwordInput() {
1527
+ return this._password;
1528
+ }
1529
+ // project_id - computed: true, optional: true, required: false
1530
+ _projectId;
1531
+ get projectId() {
1532
+ return this.getNumberAttribute('project_id');
1533
+ }
1534
+ set projectId(value) {
1535
+ this._projectId = value;
1536
+ }
1537
+ resetProjectId() {
1538
+ this._projectId = undefined;
1539
+ }
1540
+ // Temporarily expose input value. Use with caution.
1541
+ get projectIdInput() {
1542
+ return this._projectId;
1543
+ }
1544
+ // project_name - computed: true, optional: true, required: false
1545
+ _projectName;
1546
+ get projectName() {
1547
+ return this.getStringAttribute('project_name');
1548
+ }
1549
+ set projectName(value) {
1550
+ this._projectName = value;
1551
+ }
1552
+ resetProjectName() {
1553
+ this._projectName = undefined;
1554
+ }
1555
+ // Temporarily expose input value. Use with caution.
1556
+ get projectNameInput() {
1557
+ return this._projectName;
1558
+ }
1559
+ // region_id - computed: true, optional: true, required: false
1560
+ _regionId;
1561
+ get regionId() {
1562
+ return this.getNumberAttribute('region_id');
1563
+ }
1564
+ set regionId(value) {
1565
+ this._regionId = value;
1566
+ }
1567
+ resetRegionId() {
1568
+ this._regionId = undefined;
1569
+ }
1570
+ // Temporarily expose input value. Use with caution.
1571
+ get regionIdInput() {
1572
+ return this._regionId;
1573
+ }
1574
+ // region_name - computed: true, optional: true, required: false
1575
+ _regionName;
1576
+ get regionName() {
1577
+ return this.getStringAttribute('region_name');
1578
+ }
1579
+ set regionName(value) {
1580
+ this._regionName = value;
1581
+ }
1582
+ resetRegionName() {
1583
+ this._regionName = undefined;
1584
+ }
1585
+ // Temporarily expose input value. Use with caution.
1586
+ get regionNameInput() {
1587
+ return this._regionName;
1588
+ }
1589
+ // security_group - computed: true, optional: false, required: false
1590
+ _securityGroup = new InstanceSecurityGroupList(this, "security_group", false);
1591
+ get securityGroup() {
1592
+ return this._securityGroup;
1593
+ }
1594
+ // server_group - computed: false, optional: true, required: false
1595
+ _serverGroup;
1596
+ get serverGroup() {
1597
+ return this.getStringAttribute('server_group');
1598
+ }
1599
+ set serverGroup(value) {
1600
+ this._serverGroup = value;
1601
+ }
1602
+ resetServerGroup() {
1603
+ this._serverGroup = undefined;
1604
+ }
1605
+ // Temporarily expose input value. Use with caution.
1606
+ get serverGroupInput() {
1607
+ return this._serverGroup;
1608
+ }
1609
+ // status - computed: true, optional: true, required: false
1610
+ _status;
1611
+ get status() {
1612
+ return this.getStringAttribute('status');
1613
+ }
1614
+ set status(value) {
1615
+ this._status = value;
1616
+ }
1617
+ resetStatus() {
1618
+ this._status = undefined;
1619
+ }
1620
+ // Temporarily expose input value. Use with caution.
1621
+ get statusInput() {
1622
+ return this._status;
1623
+ }
1624
+ // user_data - computed: false, optional: true, required: false
1625
+ _userData;
1626
+ get userData() {
1627
+ return this.getStringAttribute('user_data');
1628
+ }
1629
+ set userData(value) {
1630
+ this._userData = value;
1631
+ }
1632
+ resetUserData() {
1633
+ this._userData = undefined;
1634
+ }
1635
+ // Temporarily expose input value. Use with caution.
1636
+ get userDataInput() {
1637
+ return this._userData;
1638
+ }
1639
+ // userdata - computed: false, optional: true, required: false
1640
+ _userdata;
1641
+ get userdata() {
1642
+ return this.getStringAttribute('userdata');
1643
+ }
1644
+ set userdata(value) {
1645
+ this._userdata = value;
1646
+ }
1647
+ resetUserdata() {
1648
+ this._userdata = undefined;
1649
+ }
1650
+ // Temporarily expose input value. Use with caution.
1651
+ get userdataInput() {
1652
+ return this._userdata;
1653
+ }
1654
+ // username - computed: false, optional: true, required: false
1655
+ _username;
1656
+ get username() {
1657
+ return this.getStringAttribute('username');
1658
+ }
1659
+ set username(value) {
1660
+ this._username = value;
1661
+ }
1662
+ resetUsername() {
1663
+ this._username = undefined;
1664
+ }
1665
+ // Temporarily expose input value. Use with caution.
1666
+ get usernameInput() {
1667
+ return this._username;
1668
+ }
1669
+ // vm_state - computed: true, optional: true, required: false
1670
+ _vmState;
1671
+ get vmState() {
1672
+ return this.getStringAttribute('vm_state');
1673
+ }
1674
+ set vmState(value) {
1675
+ this._vmState = value;
1676
+ }
1677
+ resetVmState() {
1678
+ this._vmState = undefined;
1679
+ }
1680
+ // Temporarily expose input value. Use with caution.
1681
+ get vmStateInput() {
1682
+ return this._vmState;
1683
+ }
1684
+ // addresses - computed: false, optional: true, required: false
1685
+ _addresses = new InstanceAddressesList(this, "addresses", false);
1686
+ get addresses() {
1687
+ return this._addresses;
1688
+ }
1689
+ putAddresses(value) {
1690
+ this._addresses.internalValue = value;
1691
+ }
1692
+ resetAddresses() {
1693
+ this._addresses.internalValue = undefined;
1694
+ }
1695
+ // Temporarily expose input value. Use with caution.
1696
+ get addressesInput() {
1697
+ return this._addresses.internalValue;
1698
+ }
1699
+ // configuration - computed: false, optional: true, required: false
1700
+ _configuration = new InstanceConfigurationList(this, "configuration", false);
1701
+ get configuration() {
1702
+ return this._configuration;
1703
+ }
1704
+ putConfiguration(value) {
1705
+ this._configuration.internalValue = value;
1706
+ }
1707
+ resetConfiguration() {
1708
+ this._configuration.internalValue = undefined;
1709
+ }
1710
+ // Temporarily expose input value. Use with caution.
1711
+ get configurationInput() {
1712
+ return this._configuration.internalValue;
1713
+ }
1714
+ // interface - computed: false, optional: false, required: true
1715
+ _interface = new InstanceInterfaceList(this, "interface", false);
1716
+ get interface() {
1717
+ return this._interface;
1718
+ }
1719
+ putInterface(value) {
1720
+ this._interface.internalValue = value;
1721
+ }
1722
+ // Temporarily expose input value. Use with caution.
1723
+ get interfaceInput() {
1724
+ return this._interface.internalValue;
1725
+ }
1726
+ // metadata - computed: false, optional: true, required: false
1727
+ _metadata = new InstanceMetadataList(this, "metadata", false);
1728
+ get metadata() {
1729
+ return this._metadata;
1730
+ }
1731
+ putMetadata(value) {
1732
+ this._metadata.internalValue = value;
1733
+ }
1734
+ resetMetadata() {
1735
+ this._metadata.internalValue = undefined;
1736
+ }
1737
+ // Temporarily expose input value. Use with caution.
1738
+ get metadataInput() {
1739
+ return this._metadata.internalValue;
1740
+ }
1741
+ // volume - computed: false, optional: false, required: true
1742
+ _volume = new InstanceVolumeList(this, "volume", true);
1743
+ get volume() {
1744
+ return this._volume;
1745
+ }
1746
+ putVolume(value) {
1747
+ this._volume.internalValue = value;
1748
+ }
1749
+ // Temporarily expose input value. Use with caution.
1750
+ get volumeInput() {
1751
+ return this._volume.internalValue;
1752
+ }
1753
+ // =========
1754
+ // SYNTHESIS
1755
+ // =========
1756
+ synthesizeAttributes() {
1757
+ return {
1758
+ allow_app_ports: cdktf.booleanToTerraform(this._allowAppPorts),
1759
+ flavor: cdktf.hashMapper(cdktf.stringToTerraform)(this._flavor),
1760
+ flavor_id: cdktf.stringToTerraform(this._flavorId),
1761
+ id: cdktf.stringToTerraform(this._id),
1762
+ keypair_name: cdktf.stringToTerraform(this._keypairName),
1763
+ last_updated: cdktf.stringToTerraform(this._lastUpdated),
1764
+ metadata_map: cdktf.hashMapper(cdktf.stringToTerraform)(this._metadataMap),
1765
+ name: cdktf.stringToTerraform(this._name),
1766
+ name_template: cdktf.stringToTerraform(this._nameTemplate),
1767
+ name_templates: cdktf.listMapper(cdktf.stringToTerraform, false)(this._nameTemplates),
1768
+ password: cdktf.stringToTerraform(this._password),
1769
+ project_id: cdktf.numberToTerraform(this._projectId),
1770
+ project_name: cdktf.stringToTerraform(this._projectName),
1771
+ region_id: cdktf.numberToTerraform(this._regionId),
1772
+ region_name: cdktf.stringToTerraform(this._regionName),
1773
+ server_group: cdktf.stringToTerraform(this._serverGroup),
1774
+ status: cdktf.stringToTerraform(this._status),
1775
+ user_data: cdktf.stringToTerraform(this._userData),
1776
+ userdata: cdktf.stringToTerraform(this._userdata),
1777
+ username: cdktf.stringToTerraform(this._username),
1778
+ vm_state: cdktf.stringToTerraform(this._vmState),
1779
+ addresses: cdktf.listMapper(instanceAddressesToTerraform, true)(this._addresses.internalValue),
1780
+ configuration: cdktf.listMapper(instanceConfigurationToTerraform, true)(this._configuration.internalValue),
1781
+ interface: cdktf.listMapper(instanceInterfaceToTerraform, true)(this._interface.internalValue),
1782
+ metadata: cdktf.listMapper(instanceMetadataToTerraform, true)(this._metadata.internalValue),
1783
+ volume: cdktf.listMapper(instanceVolumeToTerraform, true)(this._volume.internalValue),
1784
+ };
1785
+ }
1786
+ synthesizeHclAttributes() {
1787
+ const attrs = {
1788
+ allow_app_ports: {
1789
+ value: cdktf.booleanToHclTerraform(this._allowAppPorts),
1790
+ isBlock: false,
1791
+ type: "simple",
1792
+ storageClassType: "boolean",
1793
+ },
1794
+ flavor: {
1795
+ value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(this._flavor),
1796
+ isBlock: false,
1797
+ type: "map",
1798
+ storageClassType: "stringMap",
1799
+ },
1800
+ flavor_id: {
1801
+ value: cdktf.stringToHclTerraform(this._flavorId),
1802
+ isBlock: false,
1803
+ type: "simple",
1804
+ storageClassType: "string",
1805
+ },
1806
+ id: {
1807
+ value: cdktf.stringToHclTerraform(this._id),
1808
+ isBlock: false,
1809
+ type: "simple",
1810
+ storageClassType: "string",
1811
+ },
1812
+ keypair_name: {
1813
+ value: cdktf.stringToHclTerraform(this._keypairName),
1814
+ isBlock: false,
1815
+ type: "simple",
1816
+ storageClassType: "string",
1817
+ },
1818
+ last_updated: {
1819
+ value: cdktf.stringToHclTerraform(this._lastUpdated),
1820
+ isBlock: false,
1821
+ type: "simple",
1822
+ storageClassType: "string",
1823
+ },
1824
+ metadata_map: {
1825
+ value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(this._metadataMap),
1826
+ isBlock: false,
1827
+ type: "map",
1828
+ storageClassType: "stringMap",
1829
+ },
1830
+ name: {
1831
+ value: cdktf.stringToHclTerraform(this._name),
1832
+ isBlock: false,
1833
+ type: "simple",
1834
+ storageClassType: "string",
1835
+ },
1836
+ name_template: {
1837
+ value: cdktf.stringToHclTerraform(this._nameTemplate),
1838
+ isBlock: false,
1839
+ type: "simple",
1840
+ storageClassType: "string",
1841
+ },
1842
+ name_templates: {
1843
+ value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(this._nameTemplates),
1844
+ isBlock: false,
1845
+ type: "list",
1846
+ storageClassType: "stringList",
1847
+ },
1848
+ password: {
1849
+ value: cdktf.stringToHclTerraform(this._password),
1850
+ isBlock: false,
1851
+ type: "simple",
1852
+ storageClassType: "string",
1853
+ },
1854
+ project_id: {
1855
+ value: cdktf.numberToHclTerraform(this._projectId),
1856
+ isBlock: false,
1857
+ type: "simple",
1858
+ storageClassType: "number",
1859
+ },
1860
+ project_name: {
1861
+ value: cdktf.stringToHclTerraform(this._projectName),
1862
+ isBlock: false,
1863
+ type: "simple",
1864
+ storageClassType: "string",
1865
+ },
1866
+ region_id: {
1867
+ value: cdktf.numberToHclTerraform(this._regionId),
1868
+ isBlock: false,
1869
+ type: "simple",
1870
+ storageClassType: "number",
1871
+ },
1872
+ region_name: {
1873
+ value: cdktf.stringToHclTerraform(this._regionName),
1874
+ isBlock: false,
1875
+ type: "simple",
1876
+ storageClassType: "string",
1877
+ },
1878
+ server_group: {
1879
+ value: cdktf.stringToHclTerraform(this._serverGroup),
1880
+ isBlock: false,
1881
+ type: "simple",
1882
+ storageClassType: "string",
1883
+ },
1884
+ status: {
1885
+ value: cdktf.stringToHclTerraform(this._status),
1886
+ isBlock: false,
1887
+ type: "simple",
1888
+ storageClassType: "string",
1889
+ },
1890
+ user_data: {
1891
+ value: cdktf.stringToHclTerraform(this._userData),
1892
+ isBlock: false,
1893
+ type: "simple",
1894
+ storageClassType: "string",
1895
+ },
1896
+ userdata: {
1897
+ value: cdktf.stringToHclTerraform(this._userdata),
1898
+ isBlock: false,
1899
+ type: "simple",
1900
+ storageClassType: "string",
1901
+ },
1902
+ username: {
1903
+ value: cdktf.stringToHclTerraform(this._username),
1904
+ isBlock: false,
1905
+ type: "simple",
1906
+ storageClassType: "string",
1907
+ },
1908
+ vm_state: {
1909
+ value: cdktf.stringToHclTerraform(this._vmState),
1910
+ isBlock: false,
1911
+ type: "simple",
1912
+ storageClassType: "string",
1913
+ },
1914
+ addresses: {
1915
+ value: cdktf.listMapperHcl(instanceAddressesToHclTerraform, true)(this._addresses.internalValue),
1916
+ isBlock: true,
1917
+ type: "list",
1918
+ storageClassType: "InstanceAddressesList",
1919
+ },
1920
+ configuration: {
1921
+ value: cdktf.listMapperHcl(instanceConfigurationToHclTerraform, true)(this._configuration.internalValue),
1922
+ isBlock: true,
1923
+ type: "list",
1924
+ storageClassType: "InstanceConfigurationList",
1925
+ },
1926
+ interface: {
1927
+ value: cdktf.listMapperHcl(instanceInterfaceToHclTerraform, true)(this._interface.internalValue),
1928
+ isBlock: true,
1929
+ type: "list",
1930
+ storageClassType: "InstanceInterfaceList",
1931
+ },
1932
+ metadata: {
1933
+ value: cdktf.listMapperHcl(instanceMetadataToHclTerraform, true)(this._metadata.internalValue),
1934
+ isBlock: true,
1935
+ type: "list",
1936
+ storageClassType: "InstanceMetadataList",
1937
+ },
1938
+ volume: {
1939
+ value: cdktf.listMapperHcl(instanceVolumeToHclTerraform, true)(this._volume.internalValue),
1940
+ isBlock: true,
1941
+ type: "set",
1942
+ storageClassType: "InstanceVolumeList",
1943
+ },
1944
+ };
1945
+ // remove undefined attributes
1946
+ return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
1947
+ }
1948
+ }