OLD | NEW |
(Empty) | |
| 1 library googleapis_beta.resourceviews.v1beta1; |
| 2 |
| 3 import "dart:core" as core; |
| 4 import "dart:collection" as collection; |
| 5 import "dart:async" as async; |
| 6 import "dart:convert" as convert; |
| 7 |
| 8 import "package:crypto/crypto.dart" as crypto; |
| 9 import 'package:http/http.dart' as http; |
| 10 import '../src/common_internal.dart' as common_internal; |
| 11 import '../common/common.dart' as common; |
| 12 |
| 13 export '../common/common.dart' show ApiRequestError; |
| 14 export '../common/common.dart' show DetailedApiRequestError; |
| 15 |
| 16 /** |
| 17 * The Resource View API allows users to create and manage logical sets of |
| 18 * Google Compute Engine instances. |
| 19 */ |
| 20 class ResourceviewsApi { |
| 21 /** View and manage your data across Google Cloud Platform services */ |
| 22 static const CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platf
orm"; |
| 23 |
| 24 /** View and manage your Google Compute Engine resources */ |
| 25 static const ComputeScope = "https://www.googleapis.com/auth/compute"; |
| 26 |
| 27 /** View your Google Compute Engine resources */ |
| 28 static const ComputeReadonlyScope = "https://www.googleapis.com/auth/compute.r
eadonly"; |
| 29 |
| 30 /** |
| 31 * View and manage your Google Cloud Platform management resources and |
| 32 * deployment status information |
| 33 */ |
| 34 static const NdevCloudmanScope = "https://www.googleapis.com/auth/ndev.cloudma
n"; |
| 35 |
| 36 /** |
| 37 * View your Google Cloud Platform management resources and deployment status |
| 38 * information |
| 39 */ |
| 40 static const NdevCloudmanReadonlyScope = "https://www.googleapis.com/auth/ndev
.cloudman.readonly"; |
| 41 |
| 42 |
| 43 final common_internal.ApiRequester _requester; |
| 44 |
| 45 RegionViewsResourceApi get regionViews => new RegionViewsResourceApi(_requeste
r); |
| 46 ZoneViewsResourceApi get zoneViews => new ZoneViewsResourceApi(_requester); |
| 47 |
| 48 ResourceviewsApi(http.Client client) : |
| 49 _requester = new common_internal.ApiRequester(client, "https://www.googlea
pis.com/", "/resourceviews/v1beta1/projects/"); |
| 50 } |
| 51 |
| 52 |
| 53 /** Not documented yet. */ |
| 54 class RegionViewsResourceApi { |
| 55 final common_internal.ApiRequester _requester; |
| 56 |
| 57 RegionViewsResourceApi(common_internal.ApiRequester client) : |
| 58 _requester = client; |
| 59 |
| 60 /** |
| 61 * Add resources to the view. |
| 62 * |
| 63 * [request] - The metadata request object. |
| 64 * |
| 65 * Request parameters: |
| 66 * |
| 67 * [projectName] - The project name of the resource view. |
| 68 * |
| 69 * [region] - The region name of the resource view. |
| 70 * |
| 71 * [resourceViewName] - The name of the resource view. |
| 72 * |
| 73 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 74 * error. |
| 75 * |
| 76 * If the used [http.Client] completes with an error when making a REST call, |
| 77 * this method will complete with the same error. |
| 78 */ |
| 79 async.Future addresources(RegionViewsAddResourcesRequest request, core.String
projectName, core.String region, core.String resourceViewName) { |
| 80 var _url = null; |
| 81 var _queryParams = new core.Map(); |
| 82 var _uploadMedia = null; |
| 83 var _uploadOptions = null; |
| 84 var _downloadOptions = common.DownloadOptions.Metadata; |
| 85 var _body = null; |
| 86 |
| 87 if (request != null) { |
| 88 _body = convert.JSON.encode((request).toJson()); |
| 89 } |
| 90 if (projectName == null) { |
| 91 throw new core.ArgumentError("Parameter projectName is required."); |
| 92 } |
| 93 if (region == null) { |
| 94 throw new core.ArgumentError("Parameter region is required."); |
| 95 } |
| 96 if (resourceViewName == null) { |
| 97 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 98 } |
| 99 |
| 100 _downloadOptions = null; |
| 101 |
| 102 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews/' + common_i
nternal.Escaper.ecapeVariable('$resourceViewName') + '/addResources'; |
| 103 |
| 104 var _response = _requester.request(_url, |
| 105 "POST", |
| 106 body: _body, |
| 107 queryParams: _queryParams, |
| 108 uploadOptions: _uploadOptions, |
| 109 uploadMedia: _uploadMedia, |
| 110 downloadOptions: _downloadOptions); |
| 111 return _response.then((data) => null); |
| 112 } |
| 113 |
| 114 /** |
| 115 * Delete a resource view. |
| 116 * |
| 117 * Request parameters: |
| 118 * |
| 119 * [projectName] - The project name of the resource view. |
| 120 * |
| 121 * [region] - The region name of the resource view. |
| 122 * |
| 123 * [resourceViewName] - The name of the resource view. |
| 124 * |
| 125 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 126 * error. |
| 127 * |
| 128 * If the used [http.Client] completes with an error when making a REST call, |
| 129 * this method will complete with the same error. |
| 130 */ |
| 131 async.Future delete(core.String projectName, core.String region, core.String r
esourceViewName) { |
| 132 var _url = null; |
| 133 var _queryParams = new core.Map(); |
| 134 var _uploadMedia = null; |
| 135 var _uploadOptions = null; |
| 136 var _downloadOptions = common.DownloadOptions.Metadata; |
| 137 var _body = null; |
| 138 |
| 139 if (projectName == null) { |
| 140 throw new core.ArgumentError("Parameter projectName is required."); |
| 141 } |
| 142 if (region == null) { |
| 143 throw new core.ArgumentError("Parameter region is required."); |
| 144 } |
| 145 if (resourceViewName == null) { |
| 146 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 147 } |
| 148 |
| 149 _downloadOptions = null; |
| 150 |
| 151 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews/' + common_i
nternal.Escaper.ecapeVariable('$resourceViewName'); |
| 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) => null); |
| 161 } |
| 162 |
| 163 /** |
| 164 * Get the information of a resource view. |
| 165 * |
| 166 * Request parameters: |
| 167 * |
| 168 * [projectName] - The project name of the resource view. |
| 169 * |
| 170 * [region] - The region name of the resource view. |
| 171 * |
| 172 * [resourceViewName] - The name of the resource view. |
| 173 * |
| 174 * Completes with a [ResourceView]. |
| 175 * |
| 176 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 177 * error. |
| 178 * |
| 179 * If the used [http.Client] completes with an error when making a REST call, |
| 180 * this method will complete with the same error. |
| 181 */ |
| 182 async.Future<ResourceView> get(core.String projectName, core.String region, co
re.String resourceViewName) { |
| 183 var _url = null; |
| 184 var _queryParams = new core.Map(); |
| 185 var _uploadMedia = null; |
| 186 var _uploadOptions = null; |
| 187 var _downloadOptions = common.DownloadOptions.Metadata; |
| 188 var _body = null; |
| 189 |
| 190 if (projectName == null) { |
| 191 throw new core.ArgumentError("Parameter projectName is required."); |
| 192 } |
| 193 if (region == null) { |
| 194 throw new core.ArgumentError("Parameter region is required."); |
| 195 } |
| 196 if (resourceViewName == null) { |
| 197 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 198 } |
| 199 |
| 200 |
| 201 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews/' + common_i
nternal.Escaper.ecapeVariable('$resourceViewName'); |
| 202 |
| 203 var _response = _requester.request(_url, |
| 204 "GET", |
| 205 body: _body, |
| 206 queryParams: _queryParams, |
| 207 uploadOptions: _uploadOptions, |
| 208 uploadMedia: _uploadMedia, |
| 209 downloadOptions: _downloadOptions); |
| 210 return _response.then((data) => new ResourceView.fromJson(data)); |
| 211 } |
| 212 |
| 213 /** |
| 214 * Create a resource view. |
| 215 * |
| 216 * [request] - The metadata request object. |
| 217 * |
| 218 * Request parameters: |
| 219 * |
| 220 * [projectName] - The project name of the resource view. |
| 221 * |
| 222 * [region] - The region name of the resource view. |
| 223 * |
| 224 * Completes with a [RegionViewsInsertResponse]. |
| 225 * |
| 226 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 227 * error. |
| 228 * |
| 229 * If the used [http.Client] completes with an error when making a REST call, |
| 230 * this method will complete with the same error. |
| 231 */ |
| 232 async.Future<RegionViewsInsertResponse> insert(ResourceView request, core.Stri
ng projectName, core.String region) { |
| 233 var _url = null; |
| 234 var _queryParams = new core.Map(); |
| 235 var _uploadMedia = null; |
| 236 var _uploadOptions = null; |
| 237 var _downloadOptions = common.DownloadOptions.Metadata; |
| 238 var _body = null; |
| 239 |
| 240 if (request != null) { |
| 241 _body = convert.JSON.encode((request).toJson()); |
| 242 } |
| 243 if (projectName == null) { |
| 244 throw new core.ArgumentError("Parameter projectName is required."); |
| 245 } |
| 246 if (region == null) { |
| 247 throw new core.ArgumentError("Parameter region is required."); |
| 248 } |
| 249 |
| 250 |
| 251 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews'; |
| 252 |
| 253 var _response = _requester.request(_url, |
| 254 "POST", |
| 255 body: _body, |
| 256 queryParams: _queryParams, |
| 257 uploadOptions: _uploadOptions, |
| 258 uploadMedia: _uploadMedia, |
| 259 downloadOptions: _downloadOptions); |
| 260 return _response.then((data) => new RegionViewsInsertResponse.fromJson(data)
); |
| 261 } |
| 262 |
| 263 /** |
| 264 * List resource views. |
| 265 * |
| 266 * Request parameters: |
| 267 * |
| 268 * [projectName] - The project name of the resource view. |
| 269 * |
| 270 * [region] - The region name of the resource view. |
| 271 * |
| 272 * [maxResults] - Maximum count of results to be returned. Acceptable values |
| 273 * are 0 to 5000, inclusive. (Default: 5000) |
| 274 * Value must be between "0" and "5000". |
| 275 * |
| 276 * [pageToken] - Specifies a nextPageToken returned by a previous list |
| 277 * request. This token can be used to request the next page of results from a |
| 278 * previous list request. |
| 279 * |
| 280 * Completes with a [RegionViewsListResponse]. |
| 281 * |
| 282 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 283 * error. |
| 284 * |
| 285 * If the used [http.Client] completes with an error when making a REST call, |
| 286 * this method will complete with the same error. |
| 287 */ |
| 288 async.Future<RegionViewsListResponse> list(core.String projectName, core.Strin
g region, {core.int maxResults, core.String pageToken}) { |
| 289 var _url = null; |
| 290 var _queryParams = new core.Map(); |
| 291 var _uploadMedia = null; |
| 292 var _uploadOptions = null; |
| 293 var _downloadOptions = common.DownloadOptions.Metadata; |
| 294 var _body = null; |
| 295 |
| 296 if (projectName == null) { |
| 297 throw new core.ArgumentError("Parameter projectName is required."); |
| 298 } |
| 299 if (region == null) { |
| 300 throw new core.ArgumentError("Parameter region is required."); |
| 301 } |
| 302 if (maxResults != null) { |
| 303 _queryParams["maxResults"] = ["${maxResults}"]; |
| 304 } |
| 305 if (pageToken != null) { |
| 306 _queryParams["pageToken"] = [pageToken]; |
| 307 } |
| 308 |
| 309 |
| 310 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews'; |
| 311 |
| 312 var _response = _requester.request(_url, |
| 313 "GET", |
| 314 body: _body, |
| 315 queryParams: _queryParams, |
| 316 uploadOptions: _uploadOptions, |
| 317 uploadMedia: _uploadMedia, |
| 318 downloadOptions: _downloadOptions); |
| 319 return _response.then((data) => new RegionViewsListResponse.fromJson(data)); |
| 320 } |
| 321 |
| 322 /** |
| 323 * List the resources in the view. |
| 324 * |
| 325 * Request parameters: |
| 326 * |
| 327 * [projectName] - The project name of the resource view. |
| 328 * |
| 329 * [region] - The region name of the resource view. |
| 330 * |
| 331 * [resourceViewName] - The name of the resource view. |
| 332 * |
| 333 * [maxResults] - Maximum count of results to be returned. Acceptable values |
| 334 * are 0 to 5000, inclusive. (Default: 5000) |
| 335 * Value must be between "0" and "5000". |
| 336 * |
| 337 * [pageToken] - Specifies a nextPageToken returned by a previous list |
| 338 * request. This token can be used to request the next page of results from a |
| 339 * previous list request. |
| 340 * |
| 341 * Completes with a [RegionViewsListResourcesResponse]. |
| 342 * |
| 343 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 344 * error. |
| 345 * |
| 346 * If the used [http.Client] completes with an error when making a REST call, |
| 347 * this method will complete with the same error. |
| 348 */ |
| 349 async.Future<RegionViewsListResourcesResponse> listresources(core.String proje
ctName, core.String region, core.String resourceViewName, {core.int maxResults,
core.String pageToken}) { |
| 350 var _url = null; |
| 351 var _queryParams = new core.Map(); |
| 352 var _uploadMedia = null; |
| 353 var _uploadOptions = null; |
| 354 var _downloadOptions = common.DownloadOptions.Metadata; |
| 355 var _body = null; |
| 356 |
| 357 if (projectName == null) { |
| 358 throw new core.ArgumentError("Parameter projectName is required."); |
| 359 } |
| 360 if (region == null) { |
| 361 throw new core.ArgumentError("Parameter region is required."); |
| 362 } |
| 363 if (resourceViewName == null) { |
| 364 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 365 } |
| 366 if (maxResults != null) { |
| 367 _queryParams["maxResults"] = ["${maxResults}"]; |
| 368 } |
| 369 if (pageToken != null) { |
| 370 _queryParams["pageToken"] = [pageToken]; |
| 371 } |
| 372 |
| 373 |
| 374 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews/' + common_i
nternal.Escaper.ecapeVariable('$resourceViewName') + '/resources'; |
| 375 |
| 376 var _response = _requester.request(_url, |
| 377 "POST", |
| 378 body: _body, |
| 379 queryParams: _queryParams, |
| 380 uploadOptions: _uploadOptions, |
| 381 uploadMedia: _uploadMedia, |
| 382 downloadOptions: _downloadOptions); |
| 383 return _response.then((data) => new RegionViewsListResourcesResponse.fromJso
n(data)); |
| 384 } |
| 385 |
| 386 /** |
| 387 * Remove resources from the view. |
| 388 * |
| 389 * [request] - The metadata request object. |
| 390 * |
| 391 * Request parameters: |
| 392 * |
| 393 * [projectName] - The project name of the resource view. |
| 394 * |
| 395 * [region] - The region name of the resource view. |
| 396 * |
| 397 * [resourceViewName] - The name of the resource view. |
| 398 * |
| 399 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 400 * error. |
| 401 * |
| 402 * If the used [http.Client] completes with an error when making a REST call, |
| 403 * this method will complete with the same error. |
| 404 */ |
| 405 async.Future removeresources(RegionViewsRemoveResourcesRequest request, core.S
tring projectName, core.String region, core.String resourceViewName) { |
| 406 var _url = null; |
| 407 var _queryParams = new core.Map(); |
| 408 var _uploadMedia = null; |
| 409 var _uploadOptions = null; |
| 410 var _downloadOptions = common.DownloadOptions.Metadata; |
| 411 var _body = null; |
| 412 |
| 413 if (request != null) { |
| 414 _body = convert.JSON.encode((request).toJson()); |
| 415 } |
| 416 if (projectName == null) { |
| 417 throw new core.ArgumentError("Parameter projectName is required."); |
| 418 } |
| 419 if (region == null) { |
| 420 throw new core.ArgumentError("Parameter region is required."); |
| 421 } |
| 422 if (resourceViewName == null) { |
| 423 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 424 } |
| 425 |
| 426 _downloadOptions = null; |
| 427 |
| 428 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/regions/' +
common_internal.Escaper.ecapeVariable('$region') + '/resourceViews/' + common_i
nternal.Escaper.ecapeVariable('$resourceViewName') + '/removeResources'; |
| 429 |
| 430 var _response = _requester.request(_url, |
| 431 "POST", |
| 432 body: _body, |
| 433 queryParams: _queryParams, |
| 434 uploadOptions: _uploadOptions, |
| 435 uploadMedia: _uploadMedia, |
| 436 downloadOptions: _downloadOptions); |
| 437 return _response.then((data) => null); |
| 438 } |
| 439 |
| 440 } |
| 441 |
| 442 |
| 443 /** Not documented yet. */ |
| 444 class ZoneViewsResourceApi { |
| 445 final common_internal.ApiRequester _requester; |
| 446 |
| 447 ZoneViewsResourceApi(common_internal.ApiRequester client) : |
| 448 _requester = client; |
| 449 |
| 450 /** |
| 451 * Add resources to the view. |
| 452 * |
| 453 * [request] - The metadata request object. |
| 454 * |
| 455 * Request parameters: |
| 456 * |
| 457 * [projectName] - The project name of the resource view. |
| 458 * |
| 459 * [zone] - The zone name of the resource view. |
| 460 * |
| 461 * [resourceViewName] - The name of the resource view. |
| 462 * |
| 463 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 464 * error. |
| 465 * |
| 466 * If the used [http.Client] completes with an error when making a REST call, |
| 467 * this method will complete with the same error. |
| 468 */ |
| 469 async.Future addresources(ZoneViewsAddResourcesRequest request, core.String pr
ojectName, core.String zone, core.String resourceViewName) { |
| 470 var _url = null; |
| 471 var _queryParams = new core.Map(); |
| 472 var _uploadMedia = null; |
| 473 var _uploadOptions = null; |
| 474 var _downloadOptions = common.DownloadOptions.Metadata; |
| 475 var _body = null; |
| 476 |
| 477 if (request != null) { |
| 478 _body = convert.JSON.encode((request).toJson()); |
| 479 } |
| 480 if (projectName == null) { |
| 481 throw new core.ArgumentError("Parameter projectName is required."); |
| 482 } |
| 483 if (zone == null) { |
| 484 throw new core.ArgumentError("Parameter zone is required."); |
| 485 } |
| 486 if (resourceViewName == null) { |
| 487 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 488 } |
| 489 |
| 490 _downloadOptions = null; |
| 491 |
| 492 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews/' + common_inter
nal.Escaper.ecapeVariable('$resourceViewName') + '/addResources'; |
| 493 |
| 494 var _response = _requester.request(_url, |
| 495 "POST", |
| 496 body: _body, |
| 497 queryParams: _queryParams, |
| 498 uploadOptions: _uploadOptions, |
| 499 uploadMedia: _uploadMedia, |
| 500 downloadOptions: _downloadOptions); |
| 501 return _response.then((data) => null); |
| 502 } |
| 503 |
| 504 /** |
| 505 * Delete a resource view. |
| 506 * |
| 507 * Request parameters: |
| 508 * |
| 509 * [projectName] - The project name of the resource view. |
| 510 * |
| 511 * [zone] - The zone name of the resource view. |
| 512 * |
| 513 * [resourceViewName] - The name of the resource view. |
| 514 * |
| 515 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 516 * error. |
| 517 * |
| 518 * If the used [http.Client] completes with an error when making a REST call, |
| 519 * this method will complete with the same error. |
| 520 */ |
| 521 async.Future delete(core.String projectName, core.String zone, core.String res
ourceViewName) { |
| 522 var _url = null; |
| 523 var _queryParams = new core.Map(); |
| 524 var _uploadMedia = null; |
| 525 var _uploadOptions = null; |
| 526 var _downloadOptions = common.DownloadOptions.Metadata; |
| 527 var _body = null; |
| 528 |
| 529 if (projectName == null) { |
| 530 throw new core.ArgumentError("Parameter projectName is required."); |
| 531 } |
| 532 if (zone == null) { |
| 533 throw new core.ArgumentError("Parameter zone is required."); |
| 534 } |
| 535 if (resourceViewName == null) { |
| 536 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 537 } |
| 538 |
| 539 _downloadOptions = null; |
| 540 |
| 541 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews/' + common_inter
nal.Escaper.ecapeVariable('$resourceViewName'); |
| 542 |
| 543 var _response = _requester.request(_url, |
| 544 "DELETE", |
| 545 body: _body, |
| 546 queryParams: _queryParams, |
| 547 uploadOptions: _uploadOptions, |
| 548 uploadMedia: _uploadMedia, |
| 549 downloadOptions: _downloadOptions); |
| 550 return _response.then((data) => null); |
| 551 } |
| 552 |
| 553 /** |
| 554 * Get the information of a zonal resource view. |
| 555 * |
| 556 * Request parameters: |
| 557 * |
| 558 * [projectName] - The project name of the resource view. |
| 559 * |
| 560 * [zone] - The zone name of the resource view. |
| 561 * |
| 562 * [resourceViewName] - The name of the resource view. |
| 563 * |
| 564 * Completes with a [ResourceView]. |
| 565 * |
| 566 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 567 * error. |
| 568 * |
| 569 * If the used [http.Client] completes with an error when making a REST call, |
| 570 * this method will complete with the same error. |
| 571 */ |
| 572 async.Future<ResourceView> get(core.String projectName, core.String zone, core
.String resourceViewName) { |
| 573 var _url = null; |
| 574 var _queryParams = new core.Map(); |
| 575 var _uploadMedia = null; |
| 576 var _uploadOptions = null; |
| 577 var _downloadOptions = common.DownloadOptions.Metadata; |
| 578 var _body = null; |
| 579 |
| 580 if (projectName == null) { |
| 581 throw new core.ArgumentError("Parameter projectName is required."); |
| 582 } |
| 583 if (zone == null) { |
| 584 throw new core.ArgumentError("Parameter zone is required."); |
| 585 } |
| 586 if (resourceViewName == null) { |
| 587 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 588 } |
| 589 |
| 590 |
| 591 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews/' + common_inter
nal.Escaper.ecapeVariable('$resourceViewName'); |
| 592 |
| 593 var _response = _requester.request(_url, |
| 594 "GET", |
| 595 body: _body, |
| 596 queryParams: _queryParams, |
| 597 uploadOptions: _uploadOptions, |
| 598 uploadMedia: _uploadMedia, |
| 599 downloadOptions: _downloadOptions); |
| 600 return _response.then((data) => new ResourceView.fromJson(data)); |
| 601 } |
| 602 |
| 603 /** |
| 604 * Create a resource view. |
| 605 * |
| 606 * [request] - The metadata request object. |
| 607 * |
| 608 * Request parameters: |
| 609 * |
| 610 * [projectName] - The project name of the resource view. |
| 611 * |
| 612 * [zone] - The zone name of the resource view. |
| 613 * |
| 614 * Completes with a [ZoneViewsInsertResponse]. |
| 615 * |
| 616 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 617 * error. |
| 618 * |
| 619 * If the used [http.Client] completes with an error when making a REST call, |
| 620 * this method will complete with the same error. |
| 621 */ |
| 622 async.Future<ZoneViewsInsertResponse> insert(ResourceView request, core.String
projectName, core.String zone) { |
| 623 var _url = null; |
| 624 var _queryParams = new core.Map(); |
| 625 var _uploadMedia = null; |
| 626 var _uploadOptions = null; |
| 627 var _downloadOptions = common.DownloadOptions.Metadata; |
| 628 var _body = null; |
| 629 |
| 630 if (request != null) { |
| 631 _body = convert.JSON.encode((request).toJson()); |
| 632 } |
| 633 if (projectName == null) { |
| 634 throw new core.ArgumentError("Parameter projectName is required."); |
| 635 } |
| 636 if (zone == null) { |
| 637 throw new core.ArgumentError("Parameter zone is required."); |
| 638 } |
| 639 |
| 640 |
| 641 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews'; |
| 642 |
| 643 var _response = _requester.request(_url, |
| 644 "POST", |
| 645 body: _body, |
| 646 queryParams: _queryParams, |
| 647 uploadOptions: _uploadOptions, |
| 648 uploadMedia: _uploadMedia, |
| 649 downloadOptions: _downloadOptions); |
| 650 return _response.then((data) => new ZoneViewsInsertResponse.fromJson(data)); |
| 651 } |
| 652 |
| 653 /** |
| 654 * List resource views. |
| 655 * |
| 656 * Request parameters: |
| 657 * |
| 658 * [projectName] - The project name of the resource view. |
| 659 * |
| 660 * [zone] - The zone name of the resource view. |
| 661 * |
| 662 * [maxResults] - Maximum count of results to be returned. Acceptable values |
| 663 * are 0 to 5000, inclusive. (Default: 5000) |
| 664 * Value must be between "0" and "5000". |
| 665 * |
| 666 * [pageToken] - Specifies a nextPageToken returned by a previous list |
| 667 * request. This token can be used to request the next page of results from a |
| 668 * previous list request. |
| 669 * |
| 670 * Completes with a [ZoneViewsListResponse]. |
| 671 * |
| 672 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 673 * error. |
| 674 * |
| 675 * If the used [http.Client] completes with an error when making a REST call, |
| 676 * this method will complete with the same error. |
| 677 */ |
| 678 async.Future<ZoneViewsListResponse> list(core.String projectName, core.String
zone, {core.int maxResults, core.String pageToken}) { |
| 679 var _url = null; |
| 680 var _queryParams = new core.Map(); |
| 681 var _uploadMedia = null; |
| 682 var _uploadOptions = null; |
| 683 var _downloadOptions = common.DownloadOptions.Metadata; |
| 684 var _body = null; |
| 685 |
| 686 if (projectName == null) { |
| 687 throw new core.ArgumentError("Parameter projectName is required."); |
| 688 } |
| 689 if (zone == null) { |
| 690 throw new core.ArgumentError("Parameter zone is required."); |
| 691 } |
| 692 if (maxResults != null) { |
| 693 _queryParams["maxResults"] = ["${maxResults}"]; |
| 694 } |
| 695 if (pageToken != null) { |
| 696 _queryParams["pageToken"] = [pageToken]; |
| 697 } |
| 698 |
| 699 |
| 700 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews'; |
| 701 |
| 702 var _response = _requester.request(_url, |
| 703 "GET", |
| 704 body: _body, |
| 705 queryParams: _queryParams, |
| 706 uploadOptions: _uploadOptions, |
| 707 uploadMedia: _uploadMedia, |
| 708 downloadOptions: _downloadOptions); |
| 709 return _response.then((data) => new ZoneViewsListResponse.fromJson(data)); |
| 710 } |
| 711 |
| 712 /** |
| 713 * List the resources of the resource view. |
| 714 * |
| 715 * Request parameters: |
| 716 * |
| 717 * [projectName] - The project name of the resource view. |
| 718 * |
| 719 * [zone] - The zone name of the resource view. |
| 720 * |
| 721 * [resourceViewName] - The name of the resource view. |
| 722 * |
| 723 * [maxResults] - Maximum count of results to be returned. Acceptable values |
| 724 * are 0 to 5000, inclusive. (Default: 5000) |
| 725 * Value must be between "0" and "5000". |
| 726 * |
| 727 * [pageToken] - Specifies a nextPageToken returned by a previous list |
| 728 * request. This token can be used to request the next page of results from a |
| 729 * previous list request. |
| 730 * |
| 731 * Completes with a [ZoneViewsListResourcesResponse]. |
| 732 * |
| 733 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 734 * error. |
| 735 * |
| 736 * If the used [http.Client] completes with an error when making a REST call, |
| 737 * this method will complete with the same error. |
| 738 */ |
| 739 async.Future<ZoneViewsListResourcesResponse> listresources(core.String project
Name, core.String zone, core.String resourceViewName, {core.int maxResults, core
.String pageToken}) { |
| 740 var _url = null; |
| 741 var _queryParams = new core.Map(); |
| 742 var _uploadMedia = null; |
| 743 var _uploadOptions = null; |
| 744 var _downloadOptions = common.DownloadOptions.Metadata; |
| 745 var _body = null; |
| 746 |
| 747 if (projectName == null) { |
| 748 throw new core.ArgumentError("Parameter projectName is required."); |
| 749 } |
| 750 if (zone == null) { |
| 751 throw new core.ArgumentError("Parameter zone is required."); |
| 752 } |
| 753 if (resourceViewName == null) { |
| 754 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 755 } |
| 756 if (maxResults != null) { |
| 757 _queryParams["maxResults"] = ["${maxResults}"]; |
| 758 } |
| 759 if (pageToken != null) { |
| 760 _queryParams["pageToken"] = [pageToken]; |
| 761 } |
| 762 |
| 763 |
| 764 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews/' + common_inter
nal.Escaper.ecapeVariable('$resourceViewName') + '/resources'; |
| 765 |
| 766 var _response = _requester.request(_url, |
| 767 "POST", |
| 768 body: _body, |
| 769 queryParams: _queryParams, |
| 770 uploadOptions: _uploadOptions, |
| 771 uploadMedia: _uploadMedia, |
| 772 downloadOptions: _downloadOptions); |
| 773 return _response.then((data) => new ZoneViewsListResourcesResponse.fromJson(
data)); |
| 774 } |
| 775 |
| 776 /** |
| 777 * Remove resources from the view. |
| 778 * |
| 779 * [request] - The metadata request object. |
| 780 * |
| 781 * Request parameters: |
| 782 * |
| 783 * [projectName] - The project name of the resource view. |
| 784 * |
| 785 * [zone] - The zone name of the resource view. |
| 786 * |
| 787 * [resourceViewName] - The name of the resource view. |
| 788 * |
| 789 * Completes with a [common.ApiRequestError] if the API endpoint returned an |
| 790 * error. |
| 791 * |
| 792 * If the used [http.Client] completes with an error when making a REST call, |
| 793 * this method will complete with the same error. |
| 794 */ |
| 795 async.Future removeresources(ZoneViewsRemoveResourcesRequest request, core.Str
ing projectName, core.String zone, core.String resourceViewName) { |
| 796 var _url = null; |
| 797 var _queryParams = new core.Map(); |
| 798 var _uploadMedia = null; |
| 799 var _uploadOptions = null; |
| 800 var _downloadOptions = common.DownloadOptions.Metadata; |
| 801 var _body = null; |
| 802 |
| 803 if (request != null) { |
| 804 _body = convert.JSON.encode((request).toJson()); |
| 805 } |
| 806 if (projectName == null) { |
| 807 throw new core.ArgumentError("Parameter projectName is required."); |
| 808 } |
| 809 if (zone == null) { |
| 810 throw new core.ArgumentError("Parameter zone is required."); |
| 811 } |
| 812 if (resourceViewName == null) { |
| 813 throw new core.ArgumentError("Parameter resourceViewName is required."); |
| 814 } |
| 815 |
| 816 _downloadOptions = null; |
| 817 |
| 818 _url = common_internal.Escaper.ecapeVariable('$projectName') + '/zones/' + c
ommon_internal.Escaper.ecapeVariable('$zone') + '/resourceViews/' + common_inter
nal.Escaper.ecapeVariable('$resourceViewName') + '/removeResources'; |
| 819 |
| 820 var _response = _requester.request(_url, |
| 821 "POST", |
| 822 body: _body, |
| 823 queryParams: _queryParams, |
| 824 uploadOptions: _uploadOptions, |
| 825 uploadMedia: _uploadMedia, |
| 826 downloadOptions: _downloadOptions); |
| 827 return _response.then((data) => null); |
| 828 } |
| 829 |
| 830 } |
| 831 |
| 832 |
| 833 |
| 834 /** The Label to be applied to the resource views. */ |
| 835 class Label { |
| 836 /** Key of the label. */ |
| 837 core.String key; |
| 838 |
| 839 /** Value of the label. */ |
| 840 core.String value; |
| 841 |
| 842 |
| 843 Label(); |
| 844 |
| 845 Label.fromJson(core.Map _json) { |
| 846 if (_json.containsKey("key")) { |
| 847 key = _json["key"]; |
| 848 } |
| 849 if (_json.containsKey("value")) { |
| 850 value = _json["value"]; |
| 851 } |
| 852 } |
| 853 |
| 854 core.Map toJson() { |
| 855 var _json = new core.Map(); |
| 856 if (key != null) { |
| 857 _json["key"] = key; |
| 858 } |
| 859 if (value != null) { |
| 860 _json["value"] = value; |
| 861 } |
| 862 return _json; |
| 863 } |
| 864 } |
| 865 |
| 866 |
| 867 /** The request to add resources to the resource view. */ |
| 868 class RegionViewsAddResourcesRequest { |
| 869 /** The list of resources to be added. */ |
| 870 core.List<core.String> resources; |
| 871 |
| 872 |
| 873 RegionViewsAddResourcesRequest(); |
| 874 |
| 875 RegionViewsAddResourcesRequest.fromJson(core.Map _json) { |
| 876 if (_json.containsKey("resources")) { |
| 877 resources = _json["resources"]; |
| 878 } |
| 879 } |
| 880 |
| 881 core.Map toJson() { |
| 882 var _json = new core.Map(); |
| 883 if (resources != null) { |
| 884 _json["resources"] = resources; |
| 885 } |
| 886 return _json; |
| 887 } |
| 888 } |
| 889 |
| 890 |
| 891 /** The response to a resource view insert request. */ |
| 892 class RegionViewsInsertResponse { |
| 893 /** The resource view object inserted. */ |
| 894 ResourceView resource; |
| 895 |
| 896 |
| 897 RegionViewsInsertResponse(); |
| 898 |
| 899 RegionViewsInsertResponse.fromJson(core.Map _json) { |
| 900 if (_json.containsKey("resource")) { |
| 901 resource = new ResourceView.fromJson(_json["resource"]); |
| 902 } |
| 903 } |
| 904 |
| 905 core.Map toJson() { |
| 906 var _json = new core.Map(); |
| 907 if (resource != null) { |
| 908 _json["resource"] = (resource).toJson(); |
| 909 } |
| 910 return _json; |
| 911 } |
| 912 } |
| 913 |
| 914 |
| 915 /** The response to the list resource request. */ |
| 916 class RegionViewsListResourcesResponse { |
| 917 /** The resources in the view. */ |
| 918 core.List<core.String> members; |
| 919 |
| 920 /** A token used for pagination. */ |
| 921 core.String nextPageToken; |
| 922 |
| 923 |
| 924 RegionViewsListResourcesResponse(); |
| 925 |
| 926 RegionViewsListResourcesResponse.fromJson(core.Map _json) { |
| 927 if (_json.containsKey("members")) { |
| 928 members = _json["members"]; |
| 929 } |
| 930 if (_json.containsKey("nextPageToken")) { |
| 931 nextPageToken = _json["nextPageToken"]; |
| 932 } |
| 933 } |
| 934 |
| 935 core.Map toJson() { |
| 936 var _json = new core.Map(); |
| 937 if (members != null) { |
| 938 _json["members"] = members; |
| 939 } |
| 940 if (nextPageToken != null) { |
| 941 _json["nextPageToken"] = nextPageToken; |
| 942 } |
| 943 return _json; |
| 944 } |
| 945 } |
| 946 |
| 947 |
| 948 /** The response to the list resource view request. */ |
| 949 class RegionViewsListResponse { |
| 950 /** A token used for pagination. */ |
| 951 core.String nextPageToken; |
| 952 |
| 953 /** The list of resource views that meet the criteria. */ |
| 954 core.List<ResourceView> resourceViews; |
| 955 |
| 956 |
| 957 RegionViewsListResponse(); |
| 958 |
| 959 RegionViewsListResponse.fromJson(core.Map _json) { |
| 960 if (_json.containsKey("nextPageToken")) { |
| 961 nextPageToken = _json["nextPageToken"]; |
| 962 } |
| 963 if (_json.containsKey("resourceViews")) { |
| 964 resourceViews = _json["resourceViews"].map((value) => new ResourceView.fro
mJson(value)).toList(); |
| 965 } |
| 966 } |
| 967 |
| 968 core.Map toJson() { |
| 969 var _json = new core.Map(); |
| 970 if (nextPageToken != null) { |
| 971 _json["nextPageToken"] = nextPageToken; |
| 972 } |
| 973 if (resourceViews != null) { |
| 974 _json["resourceViews"] = resourceViews.map((value) => (value).toJson()).to
List(); |
| 975 } |
| 976 return _json; |
| 977 } |
| 978 } |
| 979 |
| 980 |
| 981 /** The request to remove resources from the resource view. */ |
| 982 class RegionViewsRemoveResourcesRequest { |
| 983 /** The list of resources to be removed. */ |
| 984 core.List<core.String> resources; |
| 985 |
| 986 |
| 987 RegionViewsRemoveResourcesRequest(); |
| 988 |
| 989 RegionViewsRemoveResourcesRequest.fromJson(core.Map _json) { |
| 990 if (_json.containsKey("resources")) { |
| 991 resources = _json["resources"]; |
| 992 } |
| 993 } |
| 994 |
| 995 core.Map toJson() { |
| 996 var _json = new core.Map(); |
| 997 if (resources != null) { |
| 998 _json["resources"] = resources; |
| 999 } |
| 1000 return _json; |
| 1001 } |
| 1002 } |
| 1003 |
| 1004 |
| 1005 /** The resource view object. */ |
| 1006 class ResourceView { |
| 1007 /** The creation time of the resource view. */ |
| 1008 core.String creationTime; |
| 1009 |
| 1010 /** The detailed description of the resource view. */ |
| 1011 core.String description; |
| 1012 |
| 1013 /** [Output Only] The ID of the resource view. */ |
| 1014 core.String id; |
| 1015 |
| 1016 /** Type of the resource. */ |
| 1017 core.String kind; |
| 1018 |
| 1019 /** The labels for events. */ |
| 1020 core.List<Label> labels; |
| 1021 |
| 1022 /** The last modified time of the view. Not supported yet. */ |
| 1023 core.String lastModified; |
| 1024 |
| 1025 /** A list of all resources in the resource view. */ |
| 1026 core.List<core.String> members; |
| 1027 |
| 1028 /** The name of the resource view. */ |
| 1029 core.String name; |
| 1030 |
| 1031 /** The total number of resources in the resource view. */ |
| 1032 core.int numMembers; |
| 1033 |
| 1034 /** [Output Only] A self-link to the resource view. */ |
| 1035 core.String selfLink; |
| 1036 |
| 1037 |
| 1038 ResourceView(); |
| 1039 |
| 1040 ResourceView.fromJson(core.Map _json) { |
| 1041 if (_json.containsKey("creationTime")) { |
| 1042 creationTime = _json["creationTime"]; |
| 1043 } |
| 1044 if (_json.containsKey("description")) { |
| 1045 description = _json["description"]; |
| 1046 } |
| 1047 if (_json.containsKey("id")) { |
| 1048 id = _json["id"]; |
| 1049 } |
| 1050 if (_json.containsKey("kind")) { |
| 1051 kind = _json["kind"]; |
| 1052 } |
| 1053 if (_json.containsKey("labels")) { |
| 1054 labels = _json["labels"].map((value) => new Label.fromJson(value)).toList(
); |
| 1055 } |
| 1056 if (_json.containsKey("lastModified")) { |
| 1057 lastModified = _json["lastModified"]; |
| 1058 } |
| 1059 if (_json.containsKey("members")) { |
| 1060 members = _json["members"]; |
| 1061 } |
| 1062 if (_json.containsKey("name")) { |
| 1063 name = _json["name"]; |
| 1064 } |
| 1065 if (_json.containsKey("numMembers")) { |
| 1066 numMembers = _json["numMembers"]; |
| 1067 } |
| 1068 if (_json.containsKey("selfLink")) { |
| 1069 selfLink = _json["selfLink"]; |
| 1070 } |
| 1071 } |
| 1072 |
| 1073 core.Map toJson() { |
| 1074 var _json = new core.Map(); |
| 1075 if (creationTime != null) { |
| 1076 _json["creationTime"] = creationTime; |
| 1077 } |
| 1078 if (description != null) { |
| 1079 _json["description"] = description; |
| 1080 } |
| 1081 if (id != null) { |
| 1082 _json["id"] = id; |
| 1083 } |
| 1084 if (kind != null) { |
| 1085 _json["kind"] = kind; |
| 1086 } |
| 1087 if (labels != null) { |
| 1088 _json["labels"] = labels.map((value) => (value).toJson()).toList(); |
| 1089 } |
| 1090 if (lastModified != null) { |
| 1091 _json["lastModified"] = lastModified; |
| 1092 } |
| 1093 if (members != null) { |
| 1094 _json["members"] = members; |
| 1095 } |
| 1096 if (name != null) { |
| 1097 _json["name"] = name; |
| 1098 } |
| 1099 if (numMembers != null) { |
| 1100 _json["numMembers"] = numMembers; |
| 1101 } |
| 1102 if (selfLink != null) { |
| 1103 _json["selfLink"] = selfLink; |
| 1104 } |
| 1105 return _json; |
| 1106 } |
| 1107 } |
| 1108 |
| 1109 |
| 1110 /** The request to add resources to the resource view. */ |
| 1111 class ZoneViewsAddResourcesRequest { |
| 1112 /** The list of resources to be added. */ |
| 1113 core.List<core.String> resources; |
| 1114 |
| 1115 |
| 1116 ZoneViewsAddResourcesRequest(); |
| 1117 |
| 1118 ZoneViewsAddResourcesRequest.fromJson(core.Map _json) { |
| 1119 if (_json.containsKey("resources")) { |
| 1120 resources = _json["resources"]; |
| 1121 } |
| 1122 } |
| 1123 |
| 1124 core.Map toJson() { |
| 1125 var _json = new core.Map(); |
| 1126 if (resources != null) { |
| 1127 _json["resources"] = resources; |
| 1128 } |
| 1129 return _json; |
| 1130 } |
| 1131 } |
| 1132 |
| 1133 |
| 1134 /** The response to an insert request. */ |
| 1135 class ZoneViewsInsertResponse { |
| 1136 /** The resource view object that has been inserted. */ |
| 1137 ResourceView resource; |
| 1138 |
| 1139 |
| 1140 ZoneViewsInsertResponse(); |
| 1141 |
| 1142 ZoneViewsInsertResponse.fromJson(core.Map _json) { |
| 1143 if (_json.containsKey("resource")) { |
| 1144 resource = new ResourceView.fromJson(_json["resource"]); |
| 1145 } |
| 1146 } |
| 1147 |
| 1148 core.Map toJson() { |
| 1149 var _json = new core.Map(); |
| 1150 if (resource != null) { |
| 1151 _json["resource"] = (resource).toJson(); |
| 1152 } |
| 1153 return _json; |
| 1154 } |
| 1155 } |
| 1156 |
| 1157 |
| 1158 /** The response to a list resource request. */ |
| 1159 class ZoneViewsListResourcesResponse { |
| 1160 /** The full URL of resources in the view. */ |
| 1161 core.List<core.String> members; |
| 1162 |
| 1163 /** A token used for pagination. */ |
| 1164 core.String nextPageToken; |
| 1165 |
| 1166 |
| 1167 ZoneViewsListResourcesResponse(); |
| 1168 |
| 1169 ZoneViewsListResourcesResponse.fromJson(core.Map _json) { |
| 1170 if (_json.containsKey("members")) { |
| 1171 members = _json["members"]; |
| 1172 } |
| 1173 if (_json.containsKey("nextPageToken")) { |
| 1174 nextPageToken = _json["nextPageToken"]; |
| 1175 } |
| 1176 } |
| 1177 |
| 1178 core.Map toJson() { |
| 1179 var _json = new core.Map(); |
| 1180 if (members != null) { |
| 1181 _json["members"] = members; |
| 1182 } |
| 1183 if (nextPageToken != null) { |
| 1184 _json["nextPageToken"] = nextPageToken; |
| 1185 } |
| 1186 return _json; |
| 1187 } |
| 1188 } |
| 1189 |
| 1190 |
| 1191 /** The response to a list request. */ |
| 1192 class ZoneViewsListResponse { |
| 1193 /** A token used for pagination. */ |
| 1194 core.String nextPageToken; |
| 1195 |
| 1196 /** The result that contains all resource views that meet the criteria. */ |
| 1197 core.List<ResourceView> resourceViews; |
| 1198 |
| 1199 |
| 1200 ZoneViewsListResponse(); |
| 1201 |
| 1202 ZoneViewsListResponse.fromJson(core.Map _json) { |
| 1203 if (_json.containsKey("nextPageToken")) { |
| 1204 nextPageToken = _json["nextPageToken"]; |
| 1205 } |
| 1206 if (_json.containsKey("resourceViews")) { |
| 1207 resourceViews = _json["resourceViews"].map((value) => new ResourceView.fro
mJson(value)).toList(); |
| 1208 } |
| 1209 } |
| 1210 |
| 1211 core.Map toJson() { |
| 1212 var _json = new core.Map(); |
| 1213 if (nextPageToken != null) { |
| 1214 _json["nextPageToken"] = nextPageToken; |
| 1215 } |
| 1216 if (resourceViews != null) { |
| 1217 _json["resourceViews"] = resourceViews.map((value) => (value).toJson()).to
List(); |
| 1218 } |
| 1219 return _json; |
| 1220 } |
| 1221 } |
| 1222 |
| 1223 |
| 1224 /** The request to remove resources from the resource view. */ |
| 1225 class ZoneViewsRemoveResourcesRequest { |
| 1226 /** The list of resources to be removed. */ |
| 1227 core.List<core.String> resources; |
| 1228 |
| 1229 |
| 1230 ZoneViewsRemoveResourcesRequest(); |
| 1231 |
| 1232 ZoneViewsRemoveResourcesRequest.fromJson(core.Map _json) { |
| 1233 if (_json.containsKey("resources")) { |
| 1234 resources = _json["resources"]; |
| 1235 } |
| 1236 } |
| 1237 |
| 1238 core.Map toJson() { |
| 1239 var _json = new core.Map(); |
| 1240 if (resources != null) { |
| 1241 _json["resources"] = resources; |
| 1242 } |
| 1243 return _json; |
| 1244 } |
| 1245 } |
| 1246 |
| 1247 |
OLD | NEW |