OLD | NEW |
(Empty) | |
| 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 |
| 3 library googleapis.deploymentmanager.v2; |
| 4 |
| 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; |
| 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:crypto/crypto.dart' as crypto; |
| 11 import 'package:http/http.dart' as http; |
| 12 |
| 13 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show |
| 14 ApiRequestError, DetailedApiRequestError; |
| 15 |
| 16 const core.String USER_AGENT = 'dart-api-client deploymentmanager/v2'; |
| 17 |
| 18 /** |
| 19 * The Deployment Manager API allows users to declaratively configure, deploy |
| 20 * and run complex solutions on the Google Cloud Platform. |
| 21 */ |
| 22 class DeploymentmanagerApi { |
| 23 /** View and manage your data across Google Cloud Platform services */ |
| 24 static const CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platf
orm"; |
| 25 |
| 26 /** |
| 27 * MESSAGE UNDER CONSTRUCTION View your data across Google Cloud Platform |
| 28 * services |
| 29 */ |
| 30 static const CloudPlatformReadOnlyScope = "https://www.googleapis.com/auth/clo
ud-platform.read-only"; |
| 31 |
| 32 /** |
| 33 * View and manage your Google Cloud Platform management resources and |
| 34 * deployment status information |
| 35 */ |
| 36 static const NdevCloudmanScope = "https://www.googleapis.com/auth/ndev.cloudma
n"; |
| 37 |
| 38 /** |
| 39 * View your Google Cloud Platform management resources and deployment status |
| 40 * information |
| 41 */ |
| 42 static const NdevCloudmanReadonlyScope = "https://www.googleapis.com/auth/ndev
.cloudman.readonly"; |
| 43 |
| 44 |
| 45 final commons.ApiRequester _requester; |
| 46 |
| 47 DeploymentsResourceApi get deployments => new DeploymentsResourceApi(_requeste
r); |
| 48 ManifestsResourceApi get manifests => new ManifestsResourceApi(_requester); |
| 49 OperationsResourceApi get operations => new OperationsResourceApi(_requester); |
| 50 ResourcesResourceApi get resources => new ResourcesResourceApi(_requester); |
| 51 TypesResourceApi get types => new TypesResourceApi(_requester); |
| 52 |
| 53 DeploymentmanagerApi(http.Client client, {core.String rootUrl: "https://www.go
ogleapis.com/", core.String servicePath: "deploymentmanager/v2/projects/"}) : |
| 54 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); |
| 55 } |
| 56 |
| 57 |
| 58 class DeploymentsResourceApi { |
| 59 final commons.ApiRequester _requester; |
| 60 |
| 61 DeploymentsResourceApi(commons.ApiRequester client) : |
| 62 _requester = client; |
| 63 |
| 64 /** |
| 65 * Cancels and removes the preview currently associated with the deployment. |
| 66 * |
| 67 * [request] - The metadata request object. |
| 68 * |
| 69 * Request parameters: |
| 70 * |
| 71 * [project] - The project ID for this request. |
| 72 * Value must have pattern |
| 73 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 74 * |
| 75 * [deployment] - The name of the deployment for this request. |
| 76 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 77 * |
| 78 * Completes with a [Operation]. |
| 79 * |
| 80 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 81 * error. |
| 82 * |
| 83 * If the used [http.Client] completes with an error when making a REST call, |
| 84 * this method will complete with the same error. |
| 85 */ |
| 86 async.Future<Operation> cancelPreview(DeploymentsCancelPreviewRequest request,
core.String project, core.String deployment) { |
| 87 var _url = null; |
| 88 var _queryParams = new core.Map(); |
| 89 var _uploadMedia = null; |
| 90 var _uploadOptions = null; |
| 91 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 92 var _body = null; |
| 93 |
| 94 if (request != null) { |
| 95 _body = convert.JSON.encode((request).toJson()); |
| 96 } |
| 97 if (project == null) { |
| 98 throw new core.ArgumentError("Parameter project is required."); |
| 99 } |
| 100 if (deployment == null) { |
| 101 throw new core.ArgumentError("Parameter deployment is required."); |
| 102 } |
| 103 |
| 104 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/cancelPreview'; |
| 105 |
| 106 var _response = _requester.request(_url, |
| 107 "POST", |
| 108 body: _body, |
| 109 queryParams: _queryParams, |
| 110 uploadOptions: _uploadOptions, |
| 111 uploadMedia: _uploadMedia, |
| 112 downloadOptions: _downloadOptions); |
| 113 return _response.then((data) => new Operation.fromJson(data)); |
| 114 } |
| 115 |
| 116 /** |
| 117 * Deletes a deployment and all of the resources in the deployment. |
| 118 * |
| 119 * Request parameters: |
| 120 * |
| 121 * [project] - The project ID for this request. |
| 122 * Value must have pattern |
| 123 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 124 * |
| 125 * [deployment] - The name of the deployment for this request. |
| 126 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 127 * |
| 128 * Completes with a [Operation]. |
| 129 * |
| 130 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 131 * error. |
| 132 * |
| 133 * If the used [http.Client] completes with an error when making a REST call, |
| 134 * this method will complete with the same error. |
| 135 */ |
| 136 async.Future<Operation> delete(core.String project, core.String deployment) { |
| 137 var _url = null; |
| 138 var _queryParams = new core.Map(); |
| 139 var _uploadMedia = null; |
| 140 var _uploadOptions = null; |
| 141 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 142 var _body = null; |
| 143 |
| 144 if (project == null) { |
| 145 throw new core.ArgumentError("Parameter project is required."); |
| 146 } |
| 147 if (deployment == null) { |
| 148 throw new core.ArgumentError("Parameter deployment is required."); |
| 149 } |
| 150 |
| 151 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment'); |
| 152 |
| 153 var _response = _requester.request(_url, |
| 154 "DELETE", |
| 155 body: _body, |
| 156 queryParams: _queryParams, |
| 157 uploadOptions: _uploadOptions, |
| 158 uploadMedia: _uploadMedia, |
| 159 downloadOptions: _downloadOptions); |
| 160 return _response.then((data) => new Operation.fromJson(data)); |
| 161 } |
| 162 |
| 163 /** |
| 164 * Gets information about a specific deployment. |
| 165 * |
| 166 * Request parameters: |
| 167 * |
| 168 * [project] - The project ID for this request. |
| 169 * Value must have pattern |
| 170 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 171 * |
| 172 * [deployment] - The name of the deployment for this request. |
| 173 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 174 * |
| 175 * Completes with a [Deployment]. |
| 176 * |
| 177 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 178 * error. |
| 179 * |
| 180 * If the used [http.Client] completes with an error when making a REST call, |
| 181 * this method will complete with the same error. |
| 182 */ |
| 183 async.Future<Deployment> get(core.String project, core.String deployment) { |
| 184 var _url = null; |
| 185 var _queryParams = new core.Map(); |
| 186 var _uploadMedia = null; |
| 187 var _uploadOptions = null; |
| 188 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 189 var _body = null; |
| 190 |
| 191 if (project == null) { |
| 192 throw new core.ArgumentError("Parameter project is required."); |
| 193 } |
| 194 if (deployment == null) { |
| 195 throw new core.ArgumentError("Parameter deployment is required."); |
| 196 } |
| 197 |
| 198 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment'); |
| 199 |
| 200 var _response = _requester.request(_url, |
| 201 "GET", |
| 202 body: _body, |
| 203 queryParams: _queryParams, |
| 204 uploadOptions: _uploadOptions, |
| 205 uploadMedia: _uploadMedia, |
| 206 downloadOptions: _downloadOptions); |
| 207 return _response.then((data) => new Deployment.fromJson(data)); |
| 208 } |
| 209 |
| 210 /** |
| 211 * Creates a deployment and all of the resources described by the deployment |
| 212 * manifest. |
| 213 * |
| 214 * [request] - The metadata request object. |
| 215 * |
| 216 * Request parameters: |
| 217 * |
| 218 * [project] - The project ID for this request. |
| 219 * Value must have pattern |
| 220 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 221 * |
| 222 * [preview] - If set to true, creates a deployment and creates "shell" |
| 223 * resources but does not actually instantiate these resources. This allows |
| 224 * you to preview what your deployment looks like. After previewing a |
| 225 * deployment, you can deploy your resources by making a request with the |
| 226 * update() method or you can use the cancelPreview() method to cancel the |
| 227 * preview altogether. Note that the deployment will still exist after you |
| 228 * cancel the preview and you must separately delete this deployment if you |
| 229 * want to remove it. |
| 230 * |
| 231 * Completes with a [Operation]. |
| 232 * |
| 233 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 234 * error. |
| 235 * |
| 236 * If the used [http.Client] completes with an error when making a REST call, |
| 237 * this method will complete with the same error. |
| 238 */ |
| 239 async.Future<Operation> insert(Deployment request, core.String project, {core.
bool preview}) { |
| 240 var _url = null; |
| 241 var _queryParams = new core.Map(); |
| 242 var _uploadMedia = null; |
| 243 var _uploadOptions = null; |
| 244 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 245 var _body = null; |
| 246 |
| 247 if (request != null) { |
| 248 _body = convert.JSON.encode((request).toJson()); |
| 249 } |
| 250 if (project == null) { |
| 251 throw new core.ArgumentError("Parameter project is required."); |
| 252 } |
| 253 if (preview != null) { |
| 254 _queryParams["preview"] = ["${preview}"]; |
| 255 } |
| 256 |
| 257 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments'; |
| 258 |
| 259 var _response = _requester.request(_url, |
| 260 "POST", |
| 261 body: _body, |
| 262 queryParams: _queryParams, |
| 263 uploadOptions: _uploadOptions, |
| 264 uploadMedia: _uploadMedia, |
| 265 downloadOptions: _downloadOptions); |
| 266 return _response.then((data) => new Operation.fromJson(data)); |
| 267 } |
| 268 |
| 269 /** |
| 270 * Lists all deployments for a given project. |
| 271 * |
| 272 * Request parameters: |
| 273 * |
| 274 * [project] - The project ID for this request. |
| 275 * Value must have pattern |
| 276 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 277 * |
| 278 * [filter] - Sets a filter expression for filtering listed resources, in the |
| 279 * form filter={expression}. Your {expression} must be in the format: |
| 280 * FIELD_NAME COMPARISON_STRING LITERAL_STRING. |
| 281 * |
| 282 * The FIELD_NAME is the name of the field you want to compare. Only atomic |
| 283 * field types are supported (string, number, boolean). The COMPARISON_STRING |
| 284 * must be either eq (equals) or ne (not equals). The LITERAL_STRING is the |
| 285 * string value to filter to. The literal value must be valid for the type of |
| 286 * field (string, number, boolean). For string fields, the literal value is |
| 287 * interpreted as a regular expression using RE2 syntax. The literal value |
| 288 * must match the entire field. |
| 289 * |
| 290 * For example, filter=name ne example-instance. |
| 291 * |
| 292 * [maxResults] - Maximum count of results to be returned. |
| 293 * Value must be between "0" and "500". |
| 294 * |
| 295 * [pageToken] - Specifies a page token to use. Use this parameter if you want |
| 296 * to list the next page of results. Set pageToken to the nextPageToken |
| 297 * returned by a previous list request. |
| 298 * |
| 299 * Completes with a [DeploymentsListResponse]. |
| 300 * |
| 301 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 302 * error. |
| 303 * |
| 304 * If the used [http.Client] completes with an error when making a REST call, |
| 305 * this method will complete with the same error. |
| 306 */ |
| 307 async.Future<DeploymentsListResponse> list(core.String project, {core.String f
ilter, core.int maxResults, core.String pageToken}) { |
| 308 var _url = null; |
| 309 var _queryParams = new core.Map(); |
| 310 var _uploadMedia = null; |
| 311 var _uploadOptions = null; |
| 312 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 313 var _body = null; |
| 314 |
| 315 if (project == null) { |
| 316 throw new core.ArgumentError("Parameter project is required."); |
| 317 } |
| 318 if (filter != null) { |
| 319 _queryParams["filter"] = [filter]; |
| 320 } |
| 321 if (maxResults != null) { |
| 322 _queryParams["maxResults"] = ["${maxResults}"]; |
| 323 } |
| 324 if (pageToken != null) { |
| 325 _queryParams["pageToken"] = [pageToken]; |
| 326 } |
| 327 |
| 328 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments'; |
| 329 |
| 330 var _response = _requester.request(_url, |
| 331 "GET", |
| 332 body: _body, |
| 333 queryParams: _queryParams, |
| 334 uploadOptions: _uploadOptions, |
| 335 uploadMedia: _uploadMedia, |
| 336 downloadOptions: _downloadOptions); |
| 337 return _response.then((data) => new DeploymentsListResponse.fromJson(data)); |
| 338 } |
| 339 |
| 340 /** |
| 341 * Updates a deployment and all of the resources described by the deployment |
| 342 * manifest. This method supports patch semantics. |
| 343 * |
| 344 * [request] - The metadata request object. |
| 345 * |
| 346 * Request parameters: |
| 347 * |
| 348 * [project] - The project ID for this request. |
| 349 * Value must have pattern |
| 350 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 351 * |
| 352 * [deployment] - The name of the deployment for this request. |
| 353 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 354 * |
| 355 * [createPolicy] - Sets the policy to use for creating new resources. |
| 356 * Possible string values are: |
| 357 * - "ACQUIRE" |
| 358 * - "CREATE_OR_ACQUIRE" |
| 359 * |
| 360 * [deletePolicy] - Sets the policy to use for deleting resources. |
| 361 * Possible string values are: |
| 362 * - "ABANDON" |
| 363 * - "DELETE" |
| 364 * |
| 365 * [preview] - If set to true, updates the deployment and creates and updates |
| 366 * the "shell" resources but does not actually alter or instantiate these |
| 367 * resources. This allows you to preview what your deployment looks like. You |
| 368 * can use this intent to preview how an update would affect your deployment. |
| 369 * You must provide a target.config with a configuration if this is set to |
| 370 * true. After previewing a deployment, you can deploy your resources by |
| 371 * making a request with the update() or you can cancelPreview() to remove the |
| 372 * preview altogether. Note that the deployment will still exist after you |
| 373 * cancel the preview and you must separately delete this deployment if you |
| 374 * want to remove it. |
| 375 * |
| 376 * Completes with a [Operation]. |
| 377 * |
| 378 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 379 * error. |
| 380 * |
| 381 * If the used [http.Client] completes with an error when making a REST call, |
| 382 * this method will complete with the same error. |
| 383 */ |
| 384 async.Future<Operation> patch(Deployment request, core.String project, core.St
ring deployment, {core.String createPolicy, core.String deletePolicy, core.bool
preview}) { |
| 385 var _url = null; |
| 386 var _queryParams = new core.Map(); |
| 387 var _uploadMedia = null; |
| 388 var _uploadOptions = null; |
| 389 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 390 var _body = null; |
| 391 |
| 392 if (request != null) { |
| 393 _body = convert.JSON.encode((request).toJson()); |
| 394 } |
| 395 if (project == null) { |
| 396 throw new core.ArgumentError("Parameter project is required."); |
| 397 } |
| 398 if (deployment == null) { |
| 399 throw new core.ArgumentError("Parameter deployment is required."); |
| 400 } |
| 401 if (createPolicy != null) { |
| 402 _queryParams["createPolicy"] = [createPolicy]; |
| 403 } |
| 404 if (deletePolicy != null) { |
| 405 _queryParams["deletePolicy"] = [deletePolicy]; |
| 406 } |
| 407 if (preview != null) { |
| 408 _queryParams["preview"] = ["${preview}"]; |
| 409 } |
| 410 |
| 411 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment'); |
| 412 |
| 413 var _response = _requester.request(_url, |
| 414 "PATCH", |
| 415 body: _body, |
| 416 queryParams: _queryParams, |
| 417 uploadOptions: _uploadOptions, |
| 418 uploadMedia: _uploadMedia, |
| 419 downloadOptions: _downloadOptions); |
| 420 return _response.then((data) => new Operation.fromJson(data)); |
| 421 } |
| 422 |
| 423 /** |
| 424 * Stops an ongoing operation. This does not roll back any work that has |
| 425 * already been completed, but prevents any new work from being started. |
| 426 * |
| 427 * [request] - The metadata request object. |
| 428 * |
| 429 * Request parameters: |
| 430 * |
| 431 * [project] - The project ID for this request. |
| 432 * Value must have pattern |
| 433 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 434 * |
| 435 * [deployment] - The name of the deployment for this request. |
| 436 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 437 * |
| 438 * Completes with a [Operation]. |
| 439 * |
| 440 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 441 * error. |
| 442 * |
| 443 * If the used [http.Client] completes with an error when making a REST call, |
| 444 * this method will complete with the same error. |
| 445 */ |
| 446 async.Future<Operation> stop(DeploymentsStopRequest request, core.String proje
ct, core.String deployment) { |
| 447 var _url = null; |
| 448 var _queryParams = new core.Map(); |
| 449 var _uploadMedia = null; |
| 450 var _uploadOptions = null; |
| 451 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 452 var _body = null; |
| 453 |
| 454 if (request != null) { |
| 455 _body = convert.JSON.encode((request).toJson()); |
| 456 } |
| 457 if (project == null) { |
| 458 throw new core.ArgumentError("Parameter project is required."); |
| 459 } |
| 460 if (deployment == null) { |
| 461 throw new core.ArgumentError("Parameter deployment is required."); |
| 462 } |
| 463 |
| 464 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/stop'; |
| 465 |
| 466 var _response = _requester.request(_url, |
| 467 "POST", |
| 468 body: _body, |
| 469 queryParams: _queryParams, |
| 470 uploadOptions: _uploadOptions, |
| 471 uploadMedia: _uploadMedia, |
| 472 downloadOptions: _downloadOptions); |
| 473 return _response.then((data) => new Operation.fromJson(data)); |
| 474 } |
| 475 |
| 476 /** |
| 477 * Updates a deployment and all of the resources described by the deployment |
| 478 * manifest. |
| 479 * |
| 480 * [request] - The metadata request object. |
| 481 * |
| 482 * Request parameters: |
| 483 * |
| 484 * [project] - The project ID for this request. |
| 485 * Value must have pattern |
| 486 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 487 * |
| 488 * [deployment] - The name of the deployment for this request. |
| 489 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 490 * |
| 491 * [createPolicy] - Sets the policy to use for creating new resources. |
| 492 * Possible string values are: |
| 493 * - "ACQUIRE" |
| 494 * - "CREATE_OR_ACQUIRE" |
| 495 * |
| 496 * [deletePolicy] - Sets the policy to use for deleting resources. |
| 497 * Possible string values are: |
| 498 * - "ABANDON" |
| 499 * - "DELETE" |
| 500 * |
| 501 * [preview] - If set to true, updates the deployment and creates and updates |
| 502 * the "shell" resources but does not actually alter or instantiate these |
| 503 * resources. This allows you to preview what your deployment looks like. You |
| 504 * can use this intent to preview how an update would affect your deployment. |
| 505 * You must provide a target.config with a configuration if this is set to |
| 506 * true. After previewing a deployment, you can deploy your resources by |
| 507 * making a request with the update() or you can cancelPreview() to remove the |
| 508 * preview altogether. Note that the deployment will still exist after you |
| 509 * cancel the preview and you must separately delete this deployment if you |
| 510 * want to remove it. |
| 511 * |
| 512 * Completes with a [Operation]. |
| 513 * |
| 514 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 515 * error. |
| 516 * |
| 517 * If the used [http.Client] completes with an error when making a REST call, |
| 518 * this method will complete with the same error. |
| 519 */ |
| 520 async.Future<Operation> update(Deployment request, core.String project, core.S
tring deployment, {core.String createPolicy, core.String deletePolicy, core.bool
preview}) { |
| 521 var _url = null; |
| 522 var _queryParams = new core.Map(); |
| 523 var _uploadMedia = null; |
| 524 var _uploadOptions = null; |
| 525 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 526 var _body = null; |
| 527 |
| 528 if (request != null) { |
| 529 _body = convert.JSON.encode((request).toJson()); |
| 530 } |
| 531 if (project == null) { |
| 532 throw new core.ArgumentError("Parameter project is required."); |
| 533 } |
| 534 if (deployment == null) { |
| 535 throw new core.ArgumentError("Parameter deployment is required."); |
| 536 } |
| 537 if (createPolicy != null) { |
| 538 _queryParams["createPolicy"] = [createPolicy]; |
| 539 } |
| 540 if (deletePolicy != null) { |
| 541 _queryParams["deletePolicy"] = [deletePolicy]; |
| 542 } |
| 543 if (preview != null) { |
| 544 _queryParams["preview"] = ["${preview}"]; |
| 545 } |
| 546 |
| 547 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment'); |
| 548 |
| 549 var _response = _requester.request(_url, |
| 550 "PUT", |
| 551 body: _body, |
| 552 queryParams: _queryParams, |
| 553 uploadOptions: _uploadOptions, |
| 554 uploadMedia: _uploadMedia, |
| 555 downloadOptions: _downloadOptions); |
| 556 return _response.then((data) => new Operation.fromJson(data)); |
| 557 } |
| 558 |
| 559 } |
| 560 |
| 561 |
| 562 class ManifestsResourceApi { |
| 563 final commons.ApiRequester _requester; |
| 564 |
| 565 ManifestsResourceApi(commons.ApiRequester client) : |
| 566 _requester = client; |
| 567 |
| 568 /** |
| 569 * Gets information about a specific manifest. |
| 570 * |
| 571 * Request parameters: |
| 572 * |
| 573 * [project] - The project ID for this request. |
| 574 * Value must have pattern |
| 575 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 576 * |
| 577 * [deployment] - The name of the deployment for this request. |
| 578 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 579 * |
| 580 * [manifest] - The name of the manifest for this request. |
| 581 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 582 * |
| 583 * Completes with a [Manifest]. |
| 584 * |
| 585 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 586 * error. |
| 587 * |
| 588 * If the used [http.Client] completes with an error when making a REST call, |
| 589 * this method will complete with the same error. |
| 590 */ |
| 591 async.Future<Manifest> get(core.String project, core.String deployment, core.S
tring manifest) { |
| 592 var _url = null; |
| 593 var _queryParams = new core.Map(); |
| 594 var _uploadMedia = null; |
| 595 var _uploadOptions = null; |
| 596 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 597 var _body = null; |
| 598 |
| 599 if (project == null) { |
| 600 throw new core.ArgumentError("Parameter project is required."); |
| 601 } |
| 602 if (deployment == null) { |
| 603 throw new core.ArgumentError("Parameter deployment is required."); |
| 604 } |
| 605 if (manifest == null) { |
| 606 throw new core.ArgumentError("Parameter manifest is required."); |
| 607 } |
| 608 |
| 609 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/manifests/' + commons.Escaper.e
capeVariable('$manifest'); |
| 610 |
| 611 var _response = _requester.request(_url, |
| 612 "GET", |
| 613 body: _body, |
| 614 queryParams: _queryParams, |
| 615 uploadOptions: _uploadOptions, |
| 616 uploadMedia: _uploadMedia, |
| 617 downloadOptions: _downloadOptions); |
| 618 return _response.then((data) => new Manifest.fromJson(data)); |
| 619 } |
| 620 |
| 621 /** |
| 622 * Lists all manifests for a given deployment. |
| 623 * |
| 624 * Request parameters: |
| 625 * |
| 626 * [project] - The project ID for this request. |
| 627 * Value must have pattern |
| 628 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 629 * |
| 630 * [deployment] - The name of the deployment for this request. |
| 631 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 632 * |
| 633 * [filter] - Sets a filter expression for filtering listed resources, in the |
| 634 * form filter={expression}. Your {expression} must be in the format: |
| 635 * FIELD_NAME COMPARISON_STRING LITERAL_STRING. |
| 636 * |
| 637 * The FIELD_NAME is the name of the field you want to compare. Only atomic |
| 638 * field types are supported (string, number, boolean). The COMPARISON_STRING |
| 639 * must be either eq (equals) or ne (not equals). The LITERAL_STRING is the |
| 640 * string value to filter to. The literal value must be valid for the type of |
| 641 * field (string, number, boolean). For string fields, the literal value is |
| 642 * interpreted as a regular expression using RE2 syntax. The literal value |
| 643 * must match the entire field. |
| 644 * |
| 645 * For example, filter=name ne example-instance. |
| 646 * |
| 647 * [maxResults] - Maximum count of results to be returned. |
| 648 * Value must be between "0" and "500". |
| 649 * |
| 650 * [pageToken] - Specifies a page token to use. Use this parameter if you want |
| 651 * to list the next page of results. Set pageToken to the nextPageToken |
| 652 * returned by a previous list request. |
| 653 * |
| 654 * Completes with a [ManifestsListResponse]. |
| 655 * |
| 656 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 657 * error. |
| 658 * |
| 659 * If the used [http.Client] completes with an error when making a REST call, |
| 660 * this method will complete with the same error. |
| 661 */ |
| 662 async.Future<ManifestsListResponse> list(core.String project, core.String depl
oyment, {core.String filter, core.int maxResults, core.String pageToken}) { |
| 663 var _url = null; |
| 664 var _queryParams = new core.Map(); |
| 665 var _uploadMedia = null; |
| 666 var _uploadOptions = null; |
| 667 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 668 var _body = null; |
| 669 |
| 670 if (project == null) { |
| 671 throw new core.ArgumentError("Parameter project is required."); |
| 672 } |
| 673 if (deployment == null) { |
| 674 throw new core.ArgumentError("Parameter deployment is required."); |
| 675 } |
| 676 if (filter != null) { |
| 677 _queryParams["filter"] = [filter]; |
| 678 } |
| 679 if (maxResults != null) { |
| 680 _queryParams["maxResults"] = ["${maxResults}"]; |
| 681 } |
| 682 if (pageToken != null) { |
| 683 _queryParams["pageToken"] = [pageToken]; |
| 684 } |
| 685 |
| 686 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/manifests'; |
| 687 |
| 688 var _response = _requester.request(_url, |
| 689 "GET", |
| 690 body: _body, |
| 691 queryParams: _queryParams, |
| 692 uploadOptions: _uploadOptions, |
| 693 uploadMedia: _uploadMedia, |
| 694 downloadOptions: _downloadOptions); |
| 695 return _response.then((data) => new ManifestsListResponse.fromJson(data)); |
| 696 } |
| 697 |
| 698 } |
| 699 |
| 700 |
| 701 class OperationsResourceApi { |
| 702 final commons.ApiRequester _requester; |
| 703 |
| 704 OperationsResourceApi(commons.ApiRequester client) : |
| 705 _requester = client; |
| 706 |
| 707 /** |
| 708 * Gets information about a specific operation. |
| 709 * |
| 710 * Request parameters: |
| 711 * |
| 712 * [project] - The project ID for this request. |
| 713 * Value must have pattern |
| 714 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 715 * |
| 716 * [operation] - The name of the operation for this request. |
| 717 * |
| 718 * Completes with a [Operation]. |
| 719 * |
| 720 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 721 * error. |
| 722 * |
| 723 * If the used [http.Client] completes with an error when making a REST call, |
| 724 * this method will complete with the same error. |
| 725 */ |
| 726 async.Future<Operation> get(core.String project, core.String operation) { |
| 727 var _url = null; |
| 728 var _queryParams = new core.Map(); |
| 729 var _uploadMedia = null; |
| 730 var _uploadOptions = null; |
| 731 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 732 var _body = null; |
| 733 |
| 734 if (project == null) { |
| 735 throw new core.ArgumentError("Parameter project is required."); |
| 736 } |
| 737 if (operation == null) { |
| 738 throw new core.ArgumentError("Parameter operation is required."); |
| 739 } |
| 740 |
| 741 _url = commons.Escaper.ecapeVariable('$project') + '/global/operations/' + c
ommons.Escaper.ecapeVariable('$operation'); |
| 742 |
| 743 var _response = _requester.request(_url, |
| 744 "GET", |
| 745 body: _body, |
| 746 queryParams: _queryParams, |
| 747 uploadOptions: _uploadOptions, |
| 748 uploadMedia: _uploadMedia, |
| 749 downloadOptions: _downloadOptions); |
| 750 return _response.then((data) => new Operation.fromJson(data)); |
| 751 } |
| 752 |
| 753 /** |
| 754 * Lists all operations for a project. |
| 755 * |
| 756 * Request parameters: |
| 757 * |
| 758 * [project] - The project ID for this request. |
| 759 * Value must have pattern |
| 760 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 761 * |
| 762 * [filter] - Sets a filter expression for filtering listed resources, in the |
| 763 * form filter={expression}. Your {expression} must be in the format: |
| 764 * FIELD_NAME COMPARISON_STRING LITERAL_STRING. |
| 765 * |
| 766 * The FIELD_NAME is the name of the field you want to compare. Only atomic |
| 767 * field types are supported (string, number, boolean). The COMPARISON_STRING |
| 768 * must be either eq (equals) or ne (not equals). The LITERAL_STRING is the |
| 769 * string value to filter to. The literal value must be valid for the type of |
| 770 * field (string, number, boolean). For string fields, the literal value is |
| 771 * interpreted as a regular expression using RE2 syntax. The literal value |
| 772 * must match the entire field. |
| 773 * |
| 774 * For example, filter=name ne example-instance. |
| 775 * |
| 776 * [maxResults] - Maximum count of results to be returned. |
| 777 * Value must be between "0" and "500". |
| 778 * |
| 779 * [pageToken] - Specifies a page token to use. Use this parameter if you want |
| 780 * to list the next page of results. Set pageToken to the nextPageToken |
| 781 * returned by a previous list request. |
| 782 * |
| 783 * Completes with a [OperationsListResponse]. |
| 784 * |
| 785 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 786 * error. |
| 787 * |
| 788 * If the used [http.Client] completes with an error when making a REST call, |
| 789 * this method will complete with the same error. |
| 790 */ |
| 791 async.Future<OperationsListResponse> list(core.String project, {core.String fi
lter, core.int maxResults, core.String pageToken}) { |
| 792 var _url = null; |
| 793 var _queryParams = new core.Map(); |
| 794 var _uploadMedia = null; |
| 795 var _uploadOptions = null; |
| 796 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 797 var _body = null; |
| 798 |
| 799 if (project == null) { |
| 800 throw new core.ArgumentError("Parameter project is required."); |
| 801 } |
| 802 if (filter != null) { |
| 803 _queryParams["filter"] = [filter]; |
| 804 } |
| 805 if (maxResults != null) { |
| 806 _queryParams["maxResults"] = ["${maxResults}"]; |
| 807 } |
| 808 if (pageToken != null) { |
| 809 _queryParams["pageToken"] = [pageToken]; |
| 810 } |
| 811 |
| 812 _url = commons.Escaper.ecapeVariable('$project') + '/global/operations'; |
| 813 |
| 814 var _response = _requester.request(_url, |
| 815 "GET", |
| 816 body: _body, |
| 817 queryParams: _queryParams, |
| 818 uploadOptions: _uploadOptions, |
| 819 uploadMedia: _uploadMedia, |
| 820 downloadOptions: _downloadOptions); |
| 821 return _response.then((data) => new OperationsListResponse.fromJson(data)); |
| 822 } |
| 823 |
| 824 } |
| 825 |
| 826 |
| 827 class ResourcesResourceApi { |
| 828 final commons.ApiRequester _requester; |
| 829 |
| 830 ResourcesResourceApi(commons.ApiRequester client) : |
| 831 _requester = client; |
| 832 |
| 833 /** |
| 834 * Gets information about a single resource. |
| 835 * |
| 836 * Request parameters: |
| 837 * |
| 838 * [project] - The project ID for this request. |
| 839 * Value must have pattern |
| 840 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 841 * |
| 842 * [deployment] - The name of the deployment for this request. |
| 843 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 844 * |
| 845 * [resource] - The name of the resource for this request. |
| 846 * |
| 847 * Completes with a [Resource]. |
| 848 * |
| 849 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 850 * error. |
| 851 * |
| 852 * If the used [http.Client] completes with an error when making a REST call, |
| 853 * this method will complete with the same error. |
| 854 */ |
| 855 async.Future<Resource> get(core.String project, core.String deployment, core.S
tring resource) { |
| 856 var _url = null; |
| 857 var _queryParams = new core.Map(); |
| 858 var _uploadMedia = null; |
| 859 var _uploadOptions = null; |
| 860 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 861 var _body = null; |
| 862 |
| 863 if (project == null) { |
| 864 throw new core.ArgumentError("Parameter project is required."); |
| 865 } |
| 866 if (deployment == null) { |
| 867 throw new core.ArgumentError("Parameter deployment is required."); |
| 868 } |
| 869 if (resource == null) { |
| 870 throw new core.ArgumentError("Parameter resource is required."); |
| 871 } |
| 872 |
| 873 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/resources/' + commons.Escaper.e
capeVariable('$resource'); |
| 874 |
| 875 var _response = _requester.request(_url, |
| 876 "GET", |
| 877 body: _body, |
| 878 queryParams: _queryParams, |
| 879 uploadOptions: _uploadOptions, |
| 880 uploadMedia: _uploadMedia, |
| 881 downloadOptions: _downloadOptions); |
| 882 return _response.then((data) => new Resource.fromJson(data)); |
| 883 } |
| 884 |
| 885 /** |
| 886 * Lists all resources in a given deployment. |
| 887 * |
| 888 * Request parameters: |
| 889 * |
| 890 * [project] - The project ID for this request. |
| 891 * Value must have pattern |
| 892 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 893 * |
| 894 * [deployment] - The name of the deployment for this request. |
| 895 * Value must have pattern "[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?". |
| 896 * |
| 897 * [filter] - Sets a filter expression for filtering listed resources, in the |
| 898 * form filter={expression}. Your {expression} must be in the format: |
| 899 * FIELD_NAME COMPARISON_STRING LITERAL_STRING. |
| 900 * |
| 901 * The FIELD_NAME is the name of the field you want to compare. Only atomic |
| 902 * field types are supported (string, number, boolean). The COMPARISON_STRING |
| 903 * must be either eq (equals) or ne (not equals). The LITERAL_STRING is the |
| 904 * string value to filter to. The literal value must be valid for the type of |
| 905 * field (string, number, boolean). For string fields, the literal value is |
| 906 * interpreted as a regular expression using RE2 syntax. The literal value |
| 907 * must match the entire field. |
| 908 * |
| 909 * For example, filter=name ne example-instance. |
| 910 * |
| 911 * [maxResults] - Maximum count of results to be returned. |
| 912 * Value must be between "0" and "500". |
| 913 * |
| 914 * [pageToken] - Specifies a page token to use. Use this parameter if you want |
| 915 * to list the next page of results. Set pageToken to the nextPageToken |
| 916 * returned by a previous list request. |
| 917 * |
| 918 * Completes with a [ResourcesListResponse]. |
| 919 * |
| 920 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 921 * error. |
| 922 * |
| 923 * If the used [http.Client] completes with an error when making a REST call, |
| 924 * this method will complete with the same error. |
| 925 */ |
| 926 async.Future<ResourcesListResponse> list(core.String project, core.String depl
oyment, {core.String filter, core.int maxResults, core.String pageToken}) { |
| 927 var _url = null; |
| 928 var _queryParams = new core.Map(); |
| 929 var _uploadMedia = null; |
| 930 var _uploadOptions = null; |
| 931 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 932 var _body = null; |
| 933 |
| 934 if (project == null) { |
| 935 throw new core.ArgumentError("Parameter project is required."); |
| 936 } |
| 937 if (deployment == null) { |
| 938 throw new core.ArgumentError("Parameter deployment is required."); |
| 939 } |
| 940 if (filter != null) { |
| 941 _queryParams["filter"] = [filter]; |
| 942 } |
| 943 if (maxResults != null) { |
| 944 _queryParams["maxResults"] = ["${maxResults}"]; |
| 945 } |
| 946 if (pageToken != null) { |
| 947 _queryParams["pageToken"] = [pageToken]; |
| 948 } |
| 949 |
| 950 _url = commons.Escaper.ecapeVariable('$project') + '/global/deployments/' +
commons.Escaper.ecapeVariable('$deployment') + '/resources'; |
| 951 |
| 952 var _response = _requester.request(_url, |
| 953 "GET", |
| 954 body: _body, |
| 955 queryParams: _queryParams, |
| 956 uploadOptions: _uploadOptions, |
| 957 uploadMedia: _uploadMedia, |
| 958 downloadOptions: _downloadOptions); |
| 959 return _response.then((data) => new ResourcesListResponse.fromJson(data)); |
| 960 } |
| 961 |
| 962 } |
| 963 |
| 964 |
| 965 class TypesResourceApi { |
| 966 final commons.ApiRequester _requester; |
| 967 |
| 968 TypesResourceApi(commons.ApiRequester client) : |
| 969 _requester = client; |
| 970 |
| 971 /** |
| 972 * Lists all resource types for Deployment Manager. |
| 973 * |
| 974 * Request parameters: |
| 975 * |
| 976 * [project] - The project ID for this request. |
| 977 * Value must have pattern |
| 978 * "(?:(?:[-a-z0-9]{1,63}\.)*(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?):)?(?:[0-9]{
1,19}|(?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?))". |
| 979 * |
| 980 * [filter] - Sets a filter expression for filtering listed resources, in the |
| 981 * form filter={expression}. Your {expression} must be in the format: |
| 982 * FIELD_NAME COMPARISON_STRING LITERAL_STRING. |
| 983 * |
| 984 * The FIELD_NAME is the name of the field you want to compare. Only atomic |
| 985 * field types are supported (string, number, boolean). The COMPARISON_STRING |
| 986 * must be either eq (equals) or ne (not equals). The LITERAL_STRING is the |
| 987 * string value to filter to. The literal value must be valid for the type of |
| 988 * field (string, number, boolean). For string fields, the literal value is |
| 989 * interpreted as a regular expression using RE2 syntax. The literal value |
| 990 * must match the entire field. |
| 991 * |
| 992 * For example, filter=name ne example-instance. |
| 993 * |
| 994 * [maxResults] - Maximum count of results to be returned. |
| 995 * Value must be between "0" and "500". |
| 996 * |
| 997 * [pageToken] - Specifies a page token to use. Use this parameter if you want |
| 998 * to list the next page of results. Set pageToken to the nextPageToken |
| 999 * returned by a previous list request. |
| 1000 * |
| 1001 * Completes with a [TypesListResponse]. |
| 1002 * |
| 1003 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1004 * error. |
| 1005 * |
| 1006 * If the used [http.Client] completes with an error when making a REST call, |
| 1007 * this method will complete with the same error. |
| 1008 */ |
| 1009 async.Future<TypesListResponse> list(core.String project, {core.String filter,
core.int maxResults, core.String pageToken}) { |
| 1010 var _url = null; |
| 1011 var _queryParams = new core.Map(); |
| 1012 var _uploadMedia = null; |
| 1013 var _uploadOptions = null; |
| 1014 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1015 var _body = null; |
| 1016 |
| 1017 if (project == null) { |
| 1018 throw new core.ArgumentError("Parameter project is required."); |
| 1019 } |
| 1020 if (filter != null) { |
| 1021 _queryParams["filter"] = [filter]; |
| 1022 } |
| 1023 if (maxResults != null) { |
| 1024 _queryParams["maxResults"] = ["${maxResults}"]; |
| 1025 } |
| 1026 if (pageToken != null) { |
| 1027 _queryParams["pageToken"] = [pageToken]; |
| 1028 } |
| 1029 |
| 1030 _url = commons.Escaper.ecapeVariable('$project') + '/global/types'; |
| 1031 |
| 1032 var _response = _requester.request(_url, |
| 1033 "GET", |
| 1034 body: _body, |
| 1035 queryParams: _queryParams, |
| 1036 uploadOptions: _uploadOptions, |
| 1037 uploadMedia: _uploadMedia, |
| 1038 downloadOptions: _downloadOptions); |
| 1039 return _response.then((data) => new TypesListResponse.fromJson(data)); |
| 1040 } |
| 1041 |
| 1042 } |
| 1043 |
| 1044 |
| 1045 |
| 1046 class ConfigFile { |
| 1047 /** The contents of the file. */ |
| 1048 core.String content; |
| 1049 |
| 1050 ConfigFile(); |
| 1051 |
| 1052 ConfigFile.fromJson(core.Map _json) { |
| 1053 if (_json.containsKey("content")) { |
| 1054 content = _json["content"]; |
| 1055 } |
| 1056 } |
| 1057 |
| 1058 core.Map toJson() { |
| 1059 var _json = new core.Map(); |
| 1060 if (content != null) { |
| 1061 _json["content"] = content; |
| 1062 } |
| 1063 return _json; |
| 1064 } |
| 1065 } |
| 1066 |
| 1067 class Deployment { |
| 1068 /** An optional user-provided description of the deployment. */ |
| 1069 core.String description; |
| 1070 /** |
| 1071 * Provides a fingerprint to use in requests to modify a deployment, such as |
| 1072 * update(), stop(), and cancelPreview() requests. A fingerprint is a randomly |
| 1073 * generated value that must be provided with update(), stop(), and |
| 1074 * cancelPreview() requests to perform optimistic locking. This ensures |
| 1075 * optimistic concurrency so that only one request happens at a time. |
| 1076 * |
| 1077 * The fingerprint is initially generated by Deployment Manager and changes |
| 1078 * after every request to modify data. To get the latest fingerprint value, |
| 1079 * perform a get() request to a deployment. |
| 1080 */ |
| 1081 core.String fingerprint; |
| 1082 core.List<core.int> get fingerprintAsBytes { |
| 1083 return crypto.CryptoUtils.base64StringToBytes(fingerprint); |
| 1084 } |
| 1085 |
| 1086 void set fingerprintAsBytes(core.List<core.int> _bytes) { |
| 1087 fingerprint = crypto.CryptoUtils.bytesToBase64(_bytes, urlSafe: true); |
| 1088 } |
| 1089 /** |
| 1090 * [Output Only] Unique identifier for the resource; defined by the server. |
| 1091 */ |
| 1092 core.String id; |
| 1093 /** |
| 1094 * [Output Only] Timestamp when the deployment was created, in RFC3339 text |
| 1095 * format . |
| 1096 */ |
| 1097 core.String insertTime; |
| 1098 /** |
| 1099 * [Output Only] URL of the manifest representing the last manifest that was |
| 1100 * successfully deployed. |
| 1101 */ |
| 1102 core.String manifest; |
| 1103 /** |
| 1104 * Name of the resource; provided by the client when the resource is created. |
| 1105 * The name must be 1-63 characters long, and comply with RFC1035. |
| 1106 * Specifically, the name must be 1-63 characters long and match the regular |
| 1107 * expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must |
| 1108 * be a lowercase letter, and all following characters must be a dash, |
| 1109 * lowercase letter, or digit, except the last character, which cannot be a |
| 1110 * dash. |
| 1111 */ |
| 1112 core.String name; |
| 1113 /** |
| 1114 * [Output Only] The Operation that most recently ran, or is currently |
| 1115 * running, on this deployment. |
| 1116 */ |
| 1117 Operation operation; |
| 1118 /** |
| 1119 * [Input Only] The parameters that define your deployment, including the |
| 1120 * deployment configuration and relevant templates. |
| 1121 */ |
| 1122 TargetConfiguration target; |
| 1123 /** |
| 1124 * [Output Only] If Deployment Manager is currently updating or previewing an |
| 1125 * update to this deployment, the updated configuration appears here. |
| 1126 */ |
| 1127 DeploymentUpdate update; |
| 1128 |
| 1129 Deployment(); |
| 1130 |
| 1131 Deployment.fromJson(core.Map _json) { |
| 1132 if (_json.containsKey("description")) { |
| 1133 description = _json["description"]; |
| 1134 } |
| 1135 if (_json.containsKey("fingerprint")) { |
| 1136 fingerprint = _json["fingerprint"]; |
| 1137 } |
| 1138 if (_json.containsKey("id")) { |
| 1139 id = _json["id"]; |
| 1140 } |
| 1141 if (_json.containsKey("insertTime")) { |
| 1142 insertTime = _json["insertTime"]; |
| 1143 } |
| 1144 if (_json.containsKey("manifest")) { |
| 1145 manifest = _json["manifest"]; |
| 1146 } |
| 1147 if (_json.containsKey("name")) { |
| 1148 name = _json["name"]; |
| 1149 } |
| 1150 if (_json.containsKey("operation")) { |
| 1151 operation = new Operation.fromJson(_json["operation"]); |
| 1152 } |
| 1153 if (_json.containsKey("target")) { |
| 1154 target = new TargetConfiguration.fromJson(_json["target"]); |
| 1155 } |
| 1156 if (_json.containsKey("update")) { |
| 1157 update = new DeploymentUpdate.fromJson(_json["update"]); |
| 1158 } |
| 1159 } |
| 1160 |
| 1161 core.Map toJson() { |
| 1162 var _json = new core.Map(); |
| 1163 if (description != null) { |
| 1164 _json["description"] = description; |
| 1165 } |
| 1166 if (fingerprint != null) { |
| 1167 _json["fingerprint"] = fingerprint; |
| 1168 } |
| 1169 if (id != null) { |
| 1170 _json["id"] = id; |
| 1171 } |
| 1172 if (insertTime != null) { |
| 1173 _json["insertTime"] = insertTime; |
| 1174 } |
| 1175 if (manifest != null) { |
| 1176 _json["manifest"] = manifest; |
| 1177 } |
| 1178 if (name != null) { |
| 1179 _json["name"] = name; |
| 1180 } |
| 1181 if (operation != null) { |
| 1182 _json["operation"] = (operation).toJson(); |
| 1183 } |
| 1184 if (target != null) { |
| 1185 _json["target"] = (target).toJson(); |
| 1186 } |
| 1187 if (update != null) { |
| 1188 _json["update"] = (update).toJson(); |
| 1189 } |
| 1190 return _json; |
| 1191 } |
| 1192 } |
| 1193 |
| 1194 class DeploymentUpdate { |
| 1195 /** |
| 1196 * [Output Only] URL of the manifest representing the update configuration of |
| 1197 * this deployment. |
| 1198 */ |
| 1199 core.String manifest; |
| 1200 |
| 1201 DeploymentUpdate(); |
| 1202 |
| 1203 DeploymentUpdate.fromJson(core.Map _json) { |
| 1204 if (_json.containsKey("manifest")) { |
| 1205 manifest = _json["manifest"]; |
| 1206 } |
| 1207 } |
| 1208 |
| 1209 core.Map toJson() { |
| 1210 var _json = new core.Map(); |
| 1211 if (manifest != null) { |
| 1212 _json["manifest"] = manifest; |
| 1213 } |
| 1214 return _json; |
| 1215 } |
| 1216 } |
| 1217 |
| 1218 class DeploymentsCancelPreviewRequest { |
| 1219 /** |
| 1220 * Specifies a fingerprint for cancelPreview() requests. A fingerprint is a |
| 1221 * randomly generated value that must be provided in cancelPreview() requests |
| 1222 * to perform optimistic locking. This ensures optimistic concurrency so that |
| 1223 * the deployment does not have conflicting requests (e.g. if someone attempts |
| 1224 * to make a new update request while another user attempts to cancel a |
| 1225 * preview, this would prevent one of the requests). |
| 1226 * |
| 1227 * The fingerprint is initially generated by Deployment Manager and changes |
| 1228 * after every request to modify a deployment. To get the latest fingerprint |
| 1229 * value, perform a get() request to a deployment. |
| 1230 */ |
| 1231 core.String fingerprint; |
| 1232 core.List<core.int> get fingerprintAsBytes { |
| 1233 return crypto.CryptoUtils.base64StringToBytes(fingerprint); |
| 1234 } |
| 1235 |
| 1236 void set fingerprintAsBytes(core.List<core.int> _bytes) { |
| 1237 fingerprint = crypto.CryptoUtils.bytesToBase64(_bytes, urlSafe: true); |
| 1238 } |
| 1239 |
| 1240 DeploymentsCancelPreviewRequest(); |
| 1241 |
| 1242 DeploymentsCancelPreviewRequest.fromJson(core.Map _json) { |
| 1243 if (_json.containsKey("fingerprint")) { |
| 1244 fingerprint = _json["fingerprint"]; |
| 1245 } |
| 1246 } |
| 1247 |
| 1248 core.Map toJson() { |
| 1249 var _json = new core.Map(); |
| 1250 if (fingerprint != null) { |
| 1251 _json["fingerprint"] = fingerprint; |
| 1252 } |
| 1253 return _json; |
| 1254 } |
| 1255 } |
| 1256 |
| 1257 /** |
| 1258 * A response containing a partial list of deployments and a page token used to |
| 1259 * build the next request if the request has been truncated. |
| 1260 */ |
| 1261 class DeploymentsListResponse { |
| 1262 /** [Output Only] The deployments contained in this response. */ |
| 1263 core.List<Deployment> deployments; |
| 1264 /** [Output Only] A token used to continue a truncated list request. */ |
| 1265 core.String nextPageToken; |
| 1266 |
| 1267 DeploymentsListResponse(); |
| 1268 |
| 1269 DeploymentsListResponse.fromJson(core.Map _json) { |
| 1270 if (_json.containsKey("deployments")) { |
| 1271 deployments = _json["deployments"].map((value) => new Deployment.fromJson(
value)).toList(); |
| 1272 } |
| 1273 if (_json.containsKey("nextPageToken")) { |
| 1274 nextPageToken = _json["nextPageToken"]; |
| 1275 } |
| 1276 } |
| 1277 |
| 1278 core.Map toJson() { |
| 1279 var _json = new core.Map(); |
| 1280 if (deployments != null) { |
| 1281 _json["deployments"] = deployments.map((value) => (value).toJson()).toList
(); |
| 1282 } |
| 1283 if (nextPageToken != null) { |
| 1284 _json["nextPageToken"] = nextPageToken; |
| 1285 } |
| 1286 return _json; |
| 1287 } |
| 1288 } |
| 1289 |
| 1290 class DeploymentsStopRequest { |
| 1291 /** |
| 1292 * Specifies a fingerprint for stop() requests. A fingerprint is a randomly |
| 1293 * generated value that must be provided in stop() requests to perform |
| 1294 * optimistic locking. This ensures optimistic concurrency so that the |
| 1295 * deployment does not have conflicting requests (e.g. if someone attempts to |
| 1296 * make a new update request while another user attempts to stop an ongoing |
| 1297 * update request, this would prevent a collision). |
| 1298 * |
| 1299 * The fingerprint is initially generated by Deployment Manager and changes |
| 1300 * after every request to modify a deployment. To get the latest fingerprint |
| 1301 * value, perform a get() request to a deployment. |
| 1302 */ |
| 1303 core.String fingerprint; |
| 1304 core.List<core.int> get fingerprintAsBytes { |
| 1305 return crypto.CryptoUtils.base64StringToBytes(fingerprint); |
| 1306 } |
| 1307 |
| 1308 void set fingerprintAsBytes(core.List<core.int> _bytes) { |
| 1309 fingerprint = crypto.CryptoUtils.bytesToBase64(_bytes, urlSafe: true); |
| 1310 } |
| 1311 |
| 1312 DeploymentsStopRequest(); |
| 1313 |
| 1314 DeploymentsStopRequest.fromJson(core.Map _json) { |
| 1315 if (_json.containsKey("fingerprint")) { |
| 1316 fingerprint = _json["fingerprint"]; |
| 1317 } |
| 1318 } |
| 1319 |
| 1320 core.Map toJson() { |
| 1321 var _json = new core.Map(); |
| 1322 if (fingerprint != null) { |
| 1323 _json["fingerprint"] = fingerprint; |
| 1324 } |
| 1325 return _json; |
| 1326 } |
| 1327 } |
| 1328 |
| 1329 class ImportFile { |
| 1330 /** The contents of the file. */ |
| 1331 core.String content; |
| 1332 /** The name of the file. */ |
| 1333 core.String name; |
| 1334 |
| 1335 ImportFile(); |
| 1336 |
| 1337 ImportFile.fromJson(core.Map _json) { |
| 1338 if (_json.containsKey("content")) { |
| 1339 content = _json["content"]; |
| 1340 } |
| 1341 if (_json.containsKey("name")) { |
| 1342 name = _json["name"]; |
| 1343 } |
| 1344 } |
| 1345 |
| 1346 core.Map toJson() { |
| 1347 var _json = new core.Map(); |
| 1348 if (content != null) { |
| 1349 _json["content"] = content; |
| 1350 } |
| 1351 if (name != null) { |
| 1352 _json["name"] = name; |
| 1353 } |
| 1354 return _json; |
| 1355 } |
| 1356 } |
| 1357 |
| 1358 class Manifest { |
| 1359 /** [Output Only] The YAML configuration for this manifest. */ |
| 1360 ConfigFile config; |
| 1361 /** |
| 1362 * [Output Only] The fully-expanded configuration file, including any |
| 1363 * templates and references. |
| 1364 */ |
| 1365 core.String expandedConfig; |
| 1366 /** |
| 1367 * [Output Only] Unique identifier for the resource; defined by the server. |
| 1368 */ |
| 1369 core.String id; |
| 1370 /** [Output Only] The imported files for this manifest. */ |
| 1371 core.List<ImportFile> imports; |
| 1372 /** |
| 1373 * [Output Only] Timestamp when the manifest was created, in RFC3339 text |
| 1374 * format. |
| 1375 */ |
| 1376 core.String insertTime; |
| 1377 /** [Output Only] The YAML layout for this manifest. */ |
| 1378 core.String layout; |
| 1379 /** [Output Only] The name of the manifest. */ |
| 1380 core.String name; |
| 1381 /** [Output Only] Self link for the manifest. */ |
| 1382 core.String selfLink; |
| 1383 |
| 1384 Manifest(); |
| 1385 |
| 1386 Manifest.fromJson(core.Map _json) { |
| 1387 if (_json.containsKey("config")) { |
| 1388 config = new ConfigFile.fromJson(_json["config"]); |
| 1389 } |
| 1390 if (_json.containsKey("expandedConfig")) { |
| 1391 expandedConfig = _json["expandedConfig"]; |
| 1392 } |
| 1393 if (_json.containsKey("id")) { |
| 1394 id = _json["id"]; |
| 1395 } |
| 1396 if (_json.containsKey("imports")) { |
| 1397 imports = _json["imports"].map((value) => new ImportFile.fromJson(value)).
toList(); |
| 1398 } |
| 1399 if (_json.containsKey("insertTime")) { |
| 1400 insertTime = _json["insertTime"]; |
| 1401 } |
| 1402 if (_json.containsKey("layout")) { |
| 1403 layout = _json["layout"]; |
| 1404 } |
| 1405 if (_json.containsKey("name")) { |
| 1406 name = _json["name"]; |
| 1407 } |
| 1408 if (_json.containsKey("selfLink")) { |
| 1409 selfLink = _json["selfLink"]; |
| 1410 } |
| 1411 } |
| 1412 |
| 1413 core.Map toJson() { |
| 1414 var _json = new core.Map(); |
| 1415 if (config != null) { |
| 1416 _json["config"] = (config).toJson(); |
| 1417 } |
| 1418 if (expandedConfig != null) { |
| 1419 _json["expandedConfig"] = expandedConfig; |
| 1420 } |
| 1421 if (id != null) { |
| 1422 _json["id"] = id; |
| 1423 } |
| 1424 if (imports != null) { |
| 1425 _json["imports"] = imports.map((value) => (value).toJson()).toList(); |
| 1426 } |
| 1427 if (insertTime != null) { |
| 1428 _json["insertTime"] = insertTime; |
| 1429 } |
| 1430 if (layout != null) { |
| 1431 _json["layout"] = layout; |
| 1432 } |
| 1433 if (name != null) { |
| 1434 _json["name"] = name; |
| 1435 } |
| 1436 if (selfLink != null) { |
| 1437 _json["selfLink"] = selfLink; |
| 1438 } |
| 1439 return _json; |
| 1440 } |
| 1441 } |
| 1442 |
| 1443 /** |
| 1444 * A response containing a partial list of manifests and a page token used to |
| 1445 * build the next request if the request has been truncated. |
| 1446 */ |
| 1447 class ManifestsListResponse { |
| 1448 /** [Output Only] Manifests contained in this list response. */ |
| 1449 core.List<Manifest> manifests; |
| 1450 /** [Output Only] A token used to continue a truncated list request. */ |
| 1451 core.String nextPageToken; |
| 1452 |
| 1453 ManifestsListResponse(); |
| 1454 |
| 1455 ManifestsListResponse.fromJson(core.Map _json) { |
| 1456 if (_json.containsKey("manifests")) { |
| 1457 manifests = _json["manifests"].map((value) => new Manifest.fromJson(value)
).toList(); |
| 1458 } |
| 1459 if (_json.containsKey("nextPageToken")) { |
| 1460 nextPageToken = _json["nextPageToken"]; |
| 1461 } |
| 1462 } |
| 1463 |
| 1464 core.Map toJson() { |
| 1465 var _json = new core.Map(); |
| 1466 if (manifests != null) { |
| 1467 _json["manifests"] = manifests.map((value) => (value).toJson()).toList(); |
| 1468 } |
| 1469 if (nextPageToken != null) { |
| 1470 _json["nextPageToken"] = nextPageToken; |
| 1471 } |
| 1472 return _json; |
| 1473 } |
| 1474 } |
| 1475 |
| 1476 class OperationErrorErrors { |
| 1477 /** [Output Only] The error type identifier for this error. */ |
| 1478 core.String code; |
| 1479 /** |
| 1480 * [Output Only] Indicates the field in the request which caused the error. |
| 1481 * This property is optional. |
| 1482 */ |
| 1483 core.String location; |
| 1484 /** [Output Only] An optional, human-readable error message. */ |
| 1485 core.String message; |
| 1486 |
| 1487 OperationErrorErrors(); |
| 1488 |
| 1489 OperationErrorErrors.fromJson(core.Map _json) { |
| 1490 if (_json.containsKey("code")) { |
| 1491 code = _json["code"]; |
| 1492 } |
| 1493 if (_json.containsKey("location")) { |
| 1494 location = _json["location"]; |
| 1495 } |
| 1496 if (_json.containsKey("message")) { |
| 1497 message = _json["message"]; |
| 1498 } |
| 1499 } |
| 1500 |
| 1501 core.Map toJson() { |
| 1502 var _json = new core.Map(); |
| 1503 if (code != null) { |
| 1504 _json["code"] = code; |
| 1505 } |
| 1506 if (location != null) { |
| 1507 _json["location"] = location; |
| 1508 } |
| 1509 if (message != null) { |
| 1510 _json["message"] = message; |
| 1511 } |
| 1512 return _json; |
| 1513 } |
| 1514 } |
| 1515 |
| 1516 /** |
| 1517 * [Output Only] If errors are generated during processing of the operation, |
| 1518 * this field will be populated. |
| 1519 */ |
| 1520 class OperationError { |
| 1521 /** |
| 1522 * [Output Only] The array of errors encountered while processing this |
| 1523 * operation. |
| 1524 */ |
| 1525 core.List<OperationErrorErrors> errors; |
| 1526 |
| 1527 OperationError(); |
| 1528 |
| 1529 OperationError.fromJson(core.Map _json) { |
| 1530 if (_json.containsKey("errors")) { |
| 1531 errors = _json["errors"].map((value) => new OperationErrorErrors.fromJson(
value)).toList(); |
| 1532 } |
| 1533 } |
| 1534 |
| 1535 core.Map toJson() { |
| 1536 var _json = new core.Map(); |
| 1537 if (errors != null) { |
| 1538 _json["errors"] = errors.map((value) => (value).toJson()).toList(); |
| 1539 } |
| 1540 return _json; |
| 1541 } |
| 1542 } |
| 1543 |
| 1544 class OperationWarningsData { |
| 1545 /** [Output Only] A key for the warning data. */ |
| 1546 core.String key; |
| 1547 /** [Output Only] A warning data value corresponding to the key. */ |
| 1548 core.String value; |
| 1549 |
| 1550 OperationWarningsData(); |
| 1551 |
| 1552 OperationWarningsData.fromJson(core.Map _json) { |
| 1553 if (_json.containsKey("key")) { |
| 1554 key = _json["key"]; |
| 1555 } |
| 1556 if (_json.containsKey("value")) { |
| 1557 value = _json["value"]; |
| 1558 } |
| 1559 } |
| 1560 |
| 1561 core.Map toJson() { |
| 1562 var _json = new core.Map(); |
| 1563 if (key != null) { |
| 1564 _json["key"] = key; |
| 1565 } |
| 1566 if (value != null) { |
| 1567 _json["value"] = value; |
| 1568 } |
| 1569 return _json; |
| 1570 } |
| 1571 } |
| 1572 |
| 1573 class OperationWarnings { |
| 1574 /** [Output Only] The warning type identifier for this warning. */ |
| 1575 core.String code; |
| 1576 /** [Output Only] Metadata for this warning in key: value format. */ |
| 1577 core.List<OperationWarningsData> data; |
| 1578 /** [Output Only] Optional human-readable details for this warning. */ |
| 1579 core.String message; |
| 1580 |
| 1581 OperationWarnings(); |
| 1582 |
| 1583 OperationWarnings.fromJson(core.Map _json) { |
| 1584 if (_json.containsKey("code")) { |
| 1585 code = _json["code"]; |
| 1586 } |
| 1587 if (_json.containsKey("data")) { |
| 1588 data = _json["data"].map((value) => new OperationWarningsData.fromJson(val
ue)).toList(); |
| 1589 } |
| 1590 if (_json.containsKey("message")) { |
| 1591 message = _json["message"]; |
| 1592 } |
| 1593 } |
| 1594 |
| 1595 core.Map toJson() { |
| 1596 var _json = new core.Map(); |
| 1597 if (code != null) { |
| 1598 _json["code"] = code; |
| 1599 } |
| 1600 if (data != null) { |
| 1601 _json["data"] = data.map((value) => (value).toJson()).toList(); |
| 1602 } |
| 1603 if (message != null) { |
| 1604 _json["message"] = message; |
| 1605 } |
| 1606 return _json; |
| 1607 } |
| 1608 } |
| 1609 |
| 1610 /** An Operation resource, used to manage asynchronous API requests. */ |
| 1611 class Operation { |
| 1612 /** |
| 1613 * [Output Only] An optional identifier specified by the client when the |
| 1614 * mutation was initiated. Must be unique for all Operation resources in the |
| 1615 * project. |
| 1616 */ |
| 1617 core.String clientOperationId; |
| 1618 /** [Output Only] Creation timestamp in RFC3339 text format. */ |
| 1619 core.String creationTimestamp; |
| 1620 /** |
| 1621 * [Output Only] The time that this operation was completed. This is in |
| 1622 * RFC3339 text format. |
| 1623 */ |
| 1624 core.String endTime; |
| 1625 /** |
| 1626 * [Output Only] If errors are generated during processing of the operation, |
| 1627 * this field will be populated. |
| 1628 */ |
| 1629 OperationError error; |
| 1630 /** |
| 1631 * [Output Only] If the operation fails, this field contains the HTTP error |
| 1632 * message that was returned, such as NOT FOUND. |
| 1633 */ |
| 1634 core.String httpErrorMessage; |
| 1635 /** |
| 1636 * [Output Only] If the operation fails, this field contains the HTTP error |
| 1637 * message that was returned, such as 404. |
| 1638 */ |
| 1639 core.int httpErrorStatusCode; |
| 1640 /** |
| 1641 * [Output Only] Unique identifier for the resource; defined by the server. |
| 1642 */ |
| 1643 core.String id; |
| 1644 /** |
| 1645 * [Output Only] The time that this operation was requested. This is in |
| 1646 * RFC3339 text format. |
| 1647 */ |
| 1648 core.String insertTime; |
| 1649 /** |
| 1650 * [Output Only] Type of the resource. Always compute#Operation for Operation |
| 1651 * resources. |
| 1652 */ |
| 1653 core.String kind; |
| 1654 /** [Output Only] Name of the resource. */ |
| 1655 core.String name; |
| 1656 /** |
| 1657 * [Output Only] Type of the operation, such as insert, update, and delete. |
| 1658 */ |
| 1659 core.String operationType; |
| 1660 /** |
| 1661 * [Output Only] An optional progress indicator that ranges from 0 to 100. |
| 1662 * There is no requirement that this be linear or support any granularity of |
| 1663 * operations. This should not be used to guess at when the operation will be |
| 1664 * complete. This number should monotonically increase as the operation |
| 1665 * progresses. |
| 1666 */ |
| 1667 core.int progress; |
| 1668 /** |
| 1669 * [Output Only] URL of the region where the operation resides. Only |
| 1670 * applicable for regional resources. |
| 1671 */ |
| 1672 core.String region; |
| 1673 /** [Output Only] Server defined URL for the resource. */ |
| 1674 core.String selfLink; |
| 1675 /** |
| 1676 * [Output Only] The time that this operation was started by the server. This |
| 1677 * is in RFC3339 text format. |
| 1678 */ |
| 1679 core.String startTime; |
| 1680 /** |
| 1681 * [Output Only] Status of the operation. Can be one of the following: |
| 1682 * PENDING, RUNNING, or DONE. |
| 1683 */ |
| 1684 core.String status; |
| 1685 /** |
| 1686 * [Output Only] An optional textual description of the current status of the |
| 1687 * operation. |
| 1688 */ |
| 1689 core.String statusMessage; |
| 1690 /** |
| 1691 * [Output Only] Unique target ID which identifies a particular incarnation of |
| 1692 * the target. |
| 1693 */ |
| 1694 core.String targetId; |
| 1695 /** [Output Only] URL of the resource the operation is mutating. */ |
| 1696 core.String targetLink; |
| 1697 /** |
| 1698 * [Output Only] User who requested the operation, for example: |
| 1699 * user@example.com. |
| 1700 */ |
| 1701 core.String user; |
| 1702 /** |
| 1703 * [Output Only] If warning messages are generated during processing of the |
| 1704 * operation, this field will be populated. |
| 1705 */ |
| 1706 core.List<OperationWarnings> warnings; |
| 1707 /** [Output Only] URL of the zone where the operation resides. */ |
| 1708 core.String zone; |
| 1709 |
| 1710 Operation(); |
| 1711 |
| 1712 Operation.fromJson(core.Map _json) { |
| 1713 if (_json.containsKey("clientOperationId")) { |
| 1714 clientOperationId = _json["clientOperationId"]; |
| 1715 } |
| 1716 if (_json.containsKey("creationTimestamp")) { |
| 1717 creationTimestamp = _json["creationTimestamp"]; |
| 1718 } |
| 1719 if (_json.containsKey("endTime")) { |
| 1720 endTime = _json["endTime"]; |
| 1721 } |
| 1722 if (_json.containsKey("error")) { |
| 1723 error = new OperationError.fromJson(_json["error"]); |
| 1724 } |
| 1725 if (_json.containsKey("httpErrorMessage")) { |
| 1726 httpErrorMessage = _json["httpErrorMessage"]; |
| 1727 } |
| 1728 if (_json.containsKey("httpErrorStatusCode")) { |
| 1729 httpErrorStatusCode = _json["httpErrorStatusCode"]; |
| 1730 } |
| 1731 if (_json.containsKey("id")) { |
| 1732 id = _json["id"]; |
| 1733 } |
| 1734 if (_json.containsKey("insertTime")) { |
| 1735 insertTime = _json["insertTime"]; |
| 1736 } |
| 1737 if (_json.containsKey("kind")) { |
| 1738 kind = _json["kind"]; |
| 1739 } |
| 1740 if (_json.containsKey("name")) { |
| 1741 name = _json["name"]; |
| 1742 } |
| 1743 if (_json.containsKey("operationType")) { |
| 1744 operationType = _json["operationType"]; |
| 1745 } |
| 1746 if (_json.containsKey("progress")) { |
| 1747 progress = _json["progress"]; |
| 1748 } |
| 1749 if (_json.containsKey("region")) { |
| 1750 region = _json["region"]; |
| 1751 } |
| 1752 if (_json.containsKey("selfLink")) { |
| 1753 selfLink = _json["selfLink"]; |
| 1754 } |
| 1755 if (_json.containsKey("startTime")) { |
| 1756 startTime = _json["startTime"]; |
| 1757 } |
| 1758 if (_json.containsKey("status")) { |
| 1759 status = _json["status"]; |
| 1760 } |
| 1761 if (_json.containsKey("statusMessage")) { |
| 1762 statusMessage = _json["statusMessage"]; |
| 1763 } |
| 1764 if (_json.containsKey("targetId")) { |
| 1765 targetId = _json["targetId"]; |
| 1766 } |
| 1767 if (_json.containsKey("targetLink")) { |
| 1768 targetLink = _json["targetLink"]; |
| 1769 } |
| 1770 if (_json.containsKey("user")) { |
| 1771 user = _json["user"]; |
| 1772 } |
| 1773 if (_json.containsKey("warnings")) { |
| 1774 warnings = _json["warnings"].map((value) => new OperationWarnings.fromJson
(value)).toList(); |
| 1775 } |
| 1776 if (_json.containsKey("zone")) { |
| 1777 zone = _json["zone"]; |
| 1778 } |
| 1779 } |
| 1780 |
| 1781 core.Map toJson() { |
| 1782 var _json = new core.Map(); |
| 1783 if (clientOperationId != null) { |
| 1784 _json["clientOperationId"] = clientOperationId; |
| 1785 } |
| 1786 if (creationTimestamp != null) { |
| 1787 _json["creationTimestamp"] = creationTimestamp; |
| 1788 } |
| 1789 if (endTime != null) { |
| 1790 _json["endTime"] = endTime; |
| 1791 } |
| 1792 if (error != null) { |
| 1793 _json["error"] = (error).toJson(); |
| 1794 } |
| 1795 if (httpErrorMessage != null) { |
| 1796 _json["httpErrorMessage"] = httpErrorMessage; |
| 1797 } |
| 1798 if (httpErrorStatusCode != null) { |
| 1799 _json["httpErrorStatusCode"] = httpErrorStatusCode; |
| 1800 } |
| 1801 if (id != null) { |
| 1802 _json["id"] = id; |
| 1803 } |
| 1804 if (insertTime != null) { |
| 1805 _json["insertTime"] = insertTime; |
| 1806 } |
| 1807 if (kind != null) { |
| 1808 _json["kind"] = kind; |
| 1809 } |
| 1810 if (name != null) { |
| 1811 _json["name"] = name; |
| 1812 } |
| 1813 if (operationType != null) { |
| 1814 _json["operationType"] = operationType; |
| 1815 } |
| 1816 if (progress != null) { |
| 1817 _json["progress"] = progress; |
| 1818 } |
| 1819 if (region != null) { |
| 1820 _json["region"] = region; |
| 1821 } |
| 1822 if (selfLink != null) { |
| 1823 _json["selfLink"] = selfLink; |
| 1824 } |
| 1825 if (startTime != null) { |
| 1826 _json["startTime"] = startTime; |
| 1827 } |
| 1828 if (status != null) { |
| 1829 _json["status"] = status; |
| 1830 } |
| 1831 if (statusMessage != null) { |
| 1832 _json["statusMessage"] = statusMessage; |
| 1833 } |
| 1834 if (targetId != null) { |
| 1835 _json["targetId"] = targetId; |
| 1836 } |
| 1837 if (targetLink != null) { |
| 1838 _json["targetLink"] = targetLink; |
| 1839 } |
| 1840 if (user != null) { |
| 1841 _json["user"] = user; |
| 1842 } |
| 1843 if (warnings != null) { |
| 1844 _json["warnings"] = warnings.map((value) => (value).toJson()).toList(); |
| 1845 } |
| 1846 if (zone != null) { |
| 1847 _json["zone"] = zone; |
| 1848 } |
| 1849 return _json; |
| 1850 } |
| 1851 } |
| 1852 |
| 1853 /** |
| 1854 * A response containing a partial list of operations and a page token used to |
| 1855 * build the next request if the request has been truncated. |
| 1856 */ |
| 1857 class OperationsListResponse { |
| 1858 /** [Output Only] A token used to continue a truncated list request. */ |
| 1859 core.String nextPageToken; |
| 1860 /** [Output Only] Operations contained in this list response. */ |
| 1861 core.List<Operation> operations; |
| 1862 |
| 1863 OperationsListResponse(); |
| 1864 |
| 1865 OperationsListResponse.fromJson(core.Map _json) { |
| 1866 if (_json.containsKey("nextPageToken")) { |
| 1867 nextPageToken = _json["nextPageToken"]; |
| 1868 } |
| 1869 if (_json.containsKey("operations")) { |
| 1870 operations = _json["operations"].map((value) => new Operation.fromJson(val
ue)).toList(); |
| 1871 } |
| 1872 } |
| 1873 |
| 1874 core.Map toJson() { |
| 1875 var _json = new core.Map(); |
| 1876 if (nextPageToken != null) { |
| 1877 _json["nextPageToken"] = nextPageToken; |
| 1878 } |
| 1879 if (operations != null) { |
| 1880 _json["operations"] = operations.map((value) => (value).toJson()).toList()
; |
| 1881 } |
| 1882 return _json; |
| 1883 } |
| 1884 } |
| 1885 |
| 1886 class ResourceWarningsData { |
| 1887 /** [Output Only] A key for the warning data. */ |
| 1888 core.String key; |
| 1889 /** [Output Only] A warning data value corresponding to the key. */ |
| 1890 core.String value; |
| 1891 |
| 1892 ResourceWarningsData(); |
| 1893 |
| 1894 ResourceWarningsData.fromJson(core.Map _json) { |
| 1895 if (_json.containsKey("key")) { |
| 1896 key = _json["key"]; |
| 1897 } |
| 1898 if (_json.containsKey("value")) { |
| 1899 value = _json["value"]; |
| 1900 } |
| 1901 } |
| 1902 |
| 1903 core.Map toJson() { |
| 1904 var _json = new core.Map(); |
| 1905 if (key != null) { |
| 1906 _json["key"] = key; |
| 1907 } |
| 1908 if (value != null) { |
| 1909 _json["value"] = value; |
| 1910 } |
| 1911 return _json; |
| 1912 } |
| 1913 } |
| 1914 |
| 1915 class ResourceWarnings { |
| 1916 /** [Output Only] The warning type identifier for this warning. */ |
| 1917 core.String code; |
| 1918 /** [Output Only] Metadata for this warning in key: value format. */ |
| 1919 core.List<ResourceWarningsData> data; |
| 1920 /** [Output Only] Optional human-readable details for this warning. */ |
| 1921 core.String message; |
| 1922 |
| 1923 ResourceWarnings(); |
| 1924 |
| 1925 ResourceWarnings.fromJson(core.Map _json) { |
| 1926 if (_json.containsKey("code")) { |
| 1927 code = _json["code"]; |
| 1928 } |
| 1929 if (_json.containsKey("data")) { |
| 1930 data = _json["data"].map((value) => new ResourceWarningsData.fromJson(valu
e)).toList(); |
| 1931 } |
| 1932 if (_json.containsKey("message")) { |
| 1933 message = _json["message"]; |
| 1934 } |
| 1935 } |
| 1936 |
| 1937 core.Map toJson() { |
| 1938 var _json = new core.Map(); |
| 1939 if (code != null) { |
| 1940 _json["code"] = code; |
| 1941 } |
| 1942 if (data != null) { |
| 1943 _json["data"] = data.map((value) => (value).toJson()).toList(); |
| 1944 } |
| 1945 if (message != null) { |
| 1946 _json["message"] = message; |
| 1947 } |
| 1948 return _json; |
| 1949 } |
| 1950 } |
| 1951 |
| 1952 class Resource { |
| 1953 /** |
| 1954 * [Output Only] The evaluated properties of the resource with references |
| 1955 * expanded. Returned as serialized YAML. |
| 1956 */ |
| 1957 core.String finalProperties; |
| 1958 /** |
| 1959 * [Output Only] Unique identifier for the resource; defined by the server. |
| 1960 */ |
| 1961 core.String id; |
| 1962 /** |
| 1963 * [Output Only] Timestamp when the resource was created or acquired, in |
| 1964 * RFC3339 text format . |
| 1965 */ |
| 1966 core.String insertTime; |
| 1967 /** |
| 1968 * [Output Only] URL of the manifest representing the current configuration of |
| 1969 * this resource. |
| 1970 */ |
| 1971 core.String manifest; |
| 1972 /** |
| 1973 * [Output Only] The name of the resource as it appears in the YAML config. |
| 1974 */ |
| 1975 core.String name; |
| 1976 /** |
| 1977 * [Output Only] The current properties of the resource before any references |
| 1978 * have been filled in. Returned as serialized YAML. |
| 1979 */ |
| 1980 core.String properties; |
| 1981 /** |
| 1982 * [Output Only] The type of the resource, for example compute.v1.instance, or |
| 1983 * replicaPools.v1beta2.instanceGroupManager. |
| 1984 */ |
| 1985 core.String type; |
| 1986 /** |
| 1987 * [Output Only] If Deployment Manager is currently updating or previewing an |
| 1988 * update to this resource, the updated configuration appears here. |
| 1989 */ |
| 1990 ResourceUpdate update; |
| 1991 /** |
| 1992 * [Output Only] Timestamp when the resource was updated, in RFC3339 text |
| 1993 * format . |
| 1994 */ |
| 1995 core.String updateTime; |
| 1996 /** [Output Only] The URL of the actual resource. */ |
| 1997 core.String url; |
| 1998 /** |
| 1999 * [Output Only] If warning messages are generated during processing of this |
| 2000 * resource, this field will be populated. |
| 2001 */ |
| 2002 core.List<ResourceWarnings> warnings; |
| 2003 |
| 2004 Resource(); |
| 2005 |
| 2006 Resource.fromJson(core.Map _json) { |
| 2007 if (_json.containsKey("finalProperties")) { |
| 2008 finalProperties = _json["finalProperties"]; |
| 2009 } |
| 2010 if (_json.containsKey("id")) { |
| 2011 id = _json["id"]; |
| 2012 } |
| 2013 if (_json.containsKey("insertTime")) { |
| 2014 insertTime = _json["insertTime"]; |
| 2015 } |
| 2016 if (_json.containsKey("manifest")) { |
| 2017 manifest = _json["manifest"]; |
| 2018 } |
| 2019 if (_json.containsKey("name")) { |
| 2020 name = _json["name"]; |
| 2021 } |
| 2022 if (_json.containsKey("properties")) { |
| 2023 properties = _json["properties"]; |
| 2024 } |
| 2025 if (_json.containsKey("type")) { |
| 2026 type = _json["type"]; |
| 2027 } |
| 2028 if (_json.containsKey("update")) { |
| 2029 update = new ResourceUpdate.fromJson(_json["update"]); |
| 2030 } |
| 2031 if (_json.containsKey("updateTime")) { |
| 2032 updateTime = _json["updateTime"]; |
| 2033 } |
| 2034 if (_json.containsKey("url")) { |
| 2035 url = _json["url"]; |
| 2036 } |
| 2037 if (_json.containsKey("warnings")) { |
| 2038 warnings = _json["warnings"].map((value) => new ResourceWarnings.fromJson(
value)).toList(); |
| 2039 } |
| 2040 } |
| 2041 |
| 2042 core.Map toJson() { |
| 2043 var _json = new core.Map(); |
| 2044 if (finalProperties != null) { |
| 2045 _json["finalProperties"] = finalProperties; |
| 2046 } |
| 2047 if (id != null) { |
| 2048 _json["id"] = id; |
| 2049 } |
| 2050 if (insertTime != null) { |
| 2051 _json["insertTime"] = insertTime; |
| 2052 } |
| 2053 if (manifest != null) { |
| 2054 _json["manifest"] = manifest; |
| 2055 } |
| 2056 if (name != null) { |
| 2057 _json["name"] = name; |
| 2058 } |
| 2059 if (properties != null) { |
| 2060 _json["properties"] = properties; |
| 2061 } |
| 2062 if (type != null) { |
| 2063 _json["type"] = type; |
| 2064 } |
| 2065 if (update != null) { |
| 2066 _json["update"] = (update).toJson(); |
| 2067 } |
| 2068 if (updateTime != null) { |
| 2069 _json["updateTime"] = updateTime; |
| 2070 } |
| 2071 if (url != null) { |
| 2072 _json["url"] = url; |
| 2073 } |
| 2074 if (warnings != null) { |
| 2075 _json["warnings"] = warnings.map((value) => (value).toJson()).toList(); |
| 2076 } |
| 2077 return _json; |
| 2078 } |
| 2079 } |
| 2080 |
| 2081 class ResourceUpdateErrorErrors { |
| 2082 /** [Output Only] The error type identifier for this error. */ |
| 2083 core.String code; |
| 2084 /** |
| 2085 * [Output Only] Indicates the field in the request which caused the error. |
| 2086 * This property is optional. |
| 2087 */ |
| 2088 core.String location; |
| 2089 /** [Output Only] An optional, human-readable error message. */ |
| 2090 core.String message; |
| 2091 |
| 2092 ResourceUpdateErrorErrors(); |
| 2093 |
| 2094 ResourceUpdateErrorErrors.fromJson(core.Map _json) { |
| 2095 if (_json.containsKey("code")) { |
| 2096 code = _json["code"]; |
| 2097 } |
| 2098 if (_json.containsKey("location")) { |
| 2099 location = _json["location"]; |
| 2100 } |
| 2101 if (_json.containsKey("message")) { |
| 2102 message = _json["message"]; |
| 2103 } |
| 2104 } |
| 2105 |
| 2106 core.Map toJson() { |
| 2107 var _json = new core.Map(); |
| 2108 if (code != null) { |
| 2109 _json["code"] = code; |
| 2110 } |
| 2111 if (location != null) { |
| 2112 _json["location"] = location; |
| 2113 } |
| 2114 if (message != null) { |
| 2115 _json["message"] = message; |
| 2116 } |
| 2117 return _json; |
| 2118 } |
| 2119 } |
| 2120 |
| 2121 /** |
| 2122 * [Output Only] If errors are generated during update of the resource, this |
| 2123 * field will be populated. |
| 2124 */ |
| 2125 class ResourceUpdateError { |
| 2126 /** |
| 2127 * [Output Only] The array of errors encountered while processing this |
| 2128 * operation. |
| 2129 */ |
| 2130 core.List<ResourceUpdateErrorErrors> errors; |
| 2131 |
| 2132 ResourceUpdateError(); |
| 2133 |
| 2134 ResourceUpdateError.fromJson(core.Map _json) { |
| 2135 if (_json.containsKey("errors")) { |
| 2136 errors = _json["errors"].map((value) => new ResourceUpdateErrorErrors.from
Json(value)).toList(); |
| 2137 } |
| 2138 } |
| 2139 |
| 2140 core.Map toJson() { |
| 2141 var _json = new core.Map(); |
| 2142 if (errors != null) { |
| 2143 _json["errors"] = errors.map((value) => (value).toJson()).toList(); |
| 2144 } |
| 2145 return _json; |
| 2146 } |
| 2147 } |
| 2148 |
| 2149 class ResourceUpdateWarningsData { |
| 2150 /** [Output Only] A key for the warning data. */ |
| 2151 core.String key; |
| 2152 /** [Output Only] A warning data value corresponding to the key. */ |
| 2153 core.String value; |
| 2154 |
| 2155 ResourceUpdateWarningsData(); |
| 2156 |
| 2157 ResourceUpdateWarningsData.fromJson(core.Map _json) { |
| 2158 if (_json.containsKey("key")) { |
| 2159 key = _json["key"]; |
| 2160 } |
| 2161 if (_json.containsKey("value")) { |
| 2162 value = _json["value"]; |
| 2163 } |
| 2164 } |
| 2165 |
| 2166 core.Map toJson() { |
| 2167 var _json = new core.Map(); |
| 2168 if (key != null) { |
| 2169 _json["key"] = key; |
| 2170 } |
| 2171 if (value != null) { |
| 2172 _json["value"] = value; |
| 2173 } |
| 2174 return _json; |
| 2175 } |
| 2176 } |
| 2177 |
| 2178 class ResourceUpdateWarnings { |
| 2179 /** [Output Only] The warning type identifier for this warning. */ |
| 2180 core.String code; |
| 2181 /** [Output Only] Metadata for this warning in key: value format. */ |
| 2182 core.List<ResourceUpdateWarningsData> data; |
| 2183 /** [Output Only] Optional human-readable details for this warning. */ |
| 2184 core.String message; |
| 2185 |
| 2186 ResourceUpdateWarnings(); |
| 2187 |
| 2188 ResourceUpdateWarnings.fromJson(core.Map _json) { |
| 2189 if (_json.containsKey("code")) { |
| 2190 code = _json["code"]; |
| 2191 } |
| 2192 if (_json.containsKey("data")) { |
| 2193 data = _json["data"].map((value) => new ResourceUpdateWarningsData.fromJso
n(value)).toList(); |
| 2194 } |
| 2195 if (_json.containsKey("message")) { |
| 2196 message = _json["message"]; |
| 2197 } |
| 2198 } |
| 2199 |
| 2200 core.Map toJson() { |
| 2201 var _json = new core.Map(); |
| 2202 if (code != null) { |
| 2203 _json["code"] = code; |
| 2204 } |
| 2205 if (data != null) { |
| 2206 _json["data"] = data.map((value) => (value).toJson()).toList(); |
| 2207 } |
| 2208 if (message != null) { |
| 2209 _json["message"] = message; |
| 2210 } |
| 2211 return _json; |
| 2212 } |
| 2213 } |
| 2214 |
| 2215 class ResourceUpdate { |
| 2216 /** |
| 2217 * [Output Only] If errors are generated during update of the resource, this |
| 2218 * field will be populated. |
| 2219 */ |
| 2220 ResourceUpdateError error; |
| 2221 /** |
| 2222 * [Output Only] The expanded properties of the resource with reference values |
| 2223 * expanded. Returned as serialized YAML. |
| 2224 */ |
| 2225 core.String finalProperties; |
| 2226 /** [Output Only] The intent of the resource: PREVIEW, UPDATE, or CANCEL. */ |
| 2227 core.String intent; |
| 2228 /** |
| 2229 * [Output Only] URL of the manifest representing the update configuration of |
| 2230 * this resource. |
| 2231 */ |
| 2232 core.String manifest; |
| 2233 /** |
| 2234 * [Output Only] The set of updated properties for this resource, before |
| 2235 * references are expanded. Returned as serialized YAML. |
| 2236 */ |
| 2237 core.String properties; |
| 2238 /** [Output Only] The state of the resource. */ |
| 2239 core.String state; |
| 2240 /** |
| 2241 * [Output Only] If warning messages are generated during processing of this |
| 2242 * resource, this field will be populated. |
| 2243 */ |
| 2244 core.List<ResourceUpdateWarnings> warnings; |
| 2245 |
| 2246 ResourceUpdate(); |
| 2247 |
| 2248 ResourceUpdate.fromJson(core.Map _json) { |
| 2249 if (_json.containsKey("error")) { |
| 2250 error = new ResourceUpdateError.fromJson(_json["error"]); |
| 2251 } |
| 2252 if (_json.containsKey("finalProperties")) { |
| 2253 finalProperties = _json["finalProperties"]; |
| 2254 } |
| 2255 if (_json.containsKey("intent")) { |
| 2256 intent = _json["intent"]; |
| 2257 } |
| 2258 if (_json.containsKey("manifest")) { |
| 2259 manifest = _json["manifest"]; |
| 2260 } |
| 2261 if (_json.containsKey("properties")) { |
| 2262 properties = _json["properties"]; |
| 2263 } |
| 2264 if (_json.containsKey("state")) { |
| 2265 state = _json["state"]; |
| 2266 } |
| 2267 if (_json.containsKey("warnings")) { |
| 2268 warnings = _json["warnings"].map((value) => new ResourceUpdateWarnings.fro
mJson(value)).toList(); |
| 2269 } |
| 2270 } |
| 2271 |
| 2272 core.Map toJson() { |
| 2273 var _json = new core.Map(); |
| 2274 if (error != null) { |
| 2275 _json["error"] = (error).toJson(); |
| 2276 } |
| 2277 if (finalProperties != null) { |
| 2278 _json["finalProperties"] = finalProperties; |
| 2279 } |
| 2280 if (intent != null) { |
| 2281 _json["intent"] = intent; |
| 2282 } |
| 2283 if (manifest != null) { |
| 2284 _json["manifest"] = manifest; |
| 2285 } |
| 2286 if (properties != null) { |
| 2287 _json["properties"] = properties; |
| 2288 } |
| 2289 if (state != null) { |
| 2290 _json["state"] = state; |
| 2291 } |
| 2292 if (warnings != null) { |
| 2293 _json["warnings"] = warnings.map((value) => (value).toJson()).toList(); |
| 2294 } |
| 2295 return _json; |
| 2296 } |
| 2297 } |
| 2298 |
| 2299 /** |
| 2300 * A response containing a partial list of resources and a page token used to |
| 2301 * build the next request if the request has been truncated. |
| 2302 */ |
| 2303 class ResourcesListResponse { |
| 2304 /** A token used to continue a truncated list request. */ |
| 2305 core.String nextPageToken; |
| 2306 /** Resources contained in this list response. */ |
| 2307 core.List<Resource> resources; |
| 2308 |
| 2309 ResourcesListResponse(); |
| 2310 |
| 2311 ResourcesListResponse.fromJson(core.Map _json) { |
| 2312 if (_json.containsKey("nextPageToken")) { |
| 2313 nextPageToken = _json["nextPageToken"]; |
| 2314 } |
| 2315 if (_json.containsKey("resources")) { |
| 2316 resources = _json["resources"].map((value) => new Resource.fromJson(value)
).toList(); |
| 2317 } |
| 2318 } |
| 2319 |
| 2320 core.Map toJson() { |
| 2321 var _json = new core.Map(); |
| 2322 if (nextPageToken != null) { |
| 2323 _json["nextPageToken"] = nextPageToken; |
| 2324 } |
| 2325 if (resources != null) { |
| 2326 _json["resources"] = resources.map((value) => (value).toJson()).toList(); |
| 2327 } |
| 2328 return _json; |
| 2329 } |
| 2330 } |
| 2331 |
| 2332 class TargetConfiguration { |
| 2333 /** The configuration to use for this deployment. */ |
| 2334 ConfigFile config; |
| 2335 /** |
| 2336 * Specifies any files to import for this configuration. This can be used to |
| 2337 * import templates or other files. For example, you might import a text file |
| 2338 * in order to use the file in a template. |
| 2339 */ |
| 2340 core.List<ImportFile> imports; |
| 2341 |
| 2342 TargetConfiguration(); |
| 2343 |
| 2344 TargetConfiguration.fromJson(core.Map _json) { |
| 2345 if (_json.containsKey("config")) { |
| 2346 config = new ConfigFile.fromJson(_json["config"]); |
| 2347 } |
| 2348 if (_json.containsKey("imports")) { |
| 2349 imports = _json["imports"].map((value) => new ImportFile.fromJson(value)).
toList(); |
| 2350 } |
| 2351 } |
| 2352 |
| 2353 core.Map toJson() { |
| 2354 var _json = new core.Map(); |
| 2355 if (config != null) { |
| 2356 _json["config"] = (config).toJson(); |
| 2357 } |
| 2358 if (imports != null) { |
| 2359 _json["imports"] = imports.map((value) => (value).toJson()).toList(); |
| 2360 } |
| 2361 return _json; |
| 2362 } |
| 2363 } |
| 2364 |
| 2365 /** A resource type supported by Deployment Manager. */ |
| 2366 class Type { |
| 2367 /** Name of the type. */ |
| 2368 core.String name; |
| 2369 |
| 2370 Type(); |
| 2371 |
| 2372 Type.fromJson(core.Map _json) { |
| 2373 if (_json.containsKey("name")) { |
| 2374 name = _json["name"]; |
| 2375 } |
| 2376 } |
| 2377 |
| 2378 core.Map toJson() { |
| 2379 var _json = new core.Map(); |
| 2380 if (name != null) { |
| 2381 _json["name"] = name; |
| 2382 } |
| 2383 return _json; |
| 2384 } |
| 2385 } |
| 2386 |
| 2387 /** A response that returns all Types supported by Deployment Manager */ |
| 2388 class TypesListResponse { |
| 2389 /** A token used to continue a truncated list request. */ |
| 2390 core.String nextPageToken; |
| 2391 /** |
| 2392 * [Output Only] A list of resource types supported by Deployment Manager. |
| 2393 */ |
| 2394 core.List<Type> types; |
| 2395 |
| 2396 TypesListResponse(); |
| 2397 |
| 2398 TypesListResponse.fromJson(core.Map _json) { |
| 2399 if (_json.containsKey("nextPageToken")) { |
| 2400 nextPageToken = _json["nextPageToken"]; |
| 2401 } |
| 2402 if (_json.containsKey("types")) { |
| 2403 types = _json["types"].map((value) => new Type.fromJson(value)).toList(); |
| 2404 } |
| 2405 } |
| 2406 |
| 2407 core.Map toJson() { |
| 2408 var _json = new core.Map(); |
| 2409 if (nextPageToken != null) { |
| 2410 _json["nextPageToken"] = nextPageToken; |
| 2411 } |
| 2412 if (types != null) { |
| 2413 _json["types"] = types.map((value) => (value).toJson()).toList(); |
| 2414 } |
| 2415 return _json; |
| 2416 } |
| 2417 } |
OLD | NEW |