OLD | NEW |
1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
2 | 2 |
3 library googleapis_beta.runtimeconfig.v1beta1; | 3 library googleapis_beta.runtimeconfig.v1beta1; |
4 | 4 |
5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
8 | 8 |
9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 * | 61 * |
62 * [request] - The metadata request object. | 62 * [request] - The metadata request object. |
63 * | 63 * |
64 * Request parameters: | 64 * Request parameters: |
65 * | 65 * |
66 * [parent] - The [project | 66 * [parent] - The [project |
67 * ID](https://support.google.com/cloud/answer/6158840?hl=en&ref_topic=6158848
) | 67 * ID](https://support.google.com/cloud/answer/6158840?hl=en&ref_topic=6158848
) |
68 * for this request, in the format `projects/[PROJECT_ID]`. | 68 * for this request, in the format `projects/[PROJECT_ID]`. |
69 * Value must have pattern "^projects/[^/]+$". | 69 * Value must have pattern "^projects/[^/]+$". |
70 * | 70 * |
71 * [requestId] - An optional unique request_id. If server receives two Create | 71 * [requestId] - An optional but recommended unique <code>request_id</code>. |
72 * requests with | 72 * If the server |
73 * the same request_id then second request will be ignored and the resource | 73 * receives two <code>create()</code> requests with the same |
74 * stored in the backend will be returned. Empty request_id fields are | 74 * <code>request_id</code>, then the second request will be ignored and the |
75 * ignored. | 75 * first resource created and stored in the backend is returned. |
76 * It is responsibility of the client to ensure uniqueness of the request_id | 76 * Empty <code>request_id</code> fields are ignored. |
77 * strings. | 77 * |
78 * The strings are limited to 64 characters. | 78 * It is responsibility of the client to ensure uniqueness of the |
| 79 * <code>request_id</code> strings. |
| 80 * |
| 81 * <code>request_id</code> strings are limited to 64 characters. |
79 * | 82 * |
80 * Completes with a [RuntimeConfig]. | 83 * Completes with a [RuntimeConfig]. |
81 * | 84 * |
82 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 85 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
83 * error. | 86 * error. |
84 * | 87 * |
85 * If the used [http.Client] completes with an error when making a REST call, | 88 * If the used [http.Client] completes with an error when making a REST call, |
86 * this method will complete with the same error. | 89 * this method will complete with the same error. |
87 */ | 90 */ |
88 async.Future<RuntimeConfig> create(RuntimeConfig request, core.String parent,
{core.String requestId}) { | 91 async.Future<RuntimeConfig> create(RuntimeConfig request, core.String parent,
{core.String requestId}) { |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
193 "GET", | 196 "GET", |
194 body: _body, | 197 body: _body, |
195 queryParams: _queryParams, | 198 queryParams: _queryParams, |
196 uploadOptions: _uploadOptions, | 199 uploadOptions: _uploadOptions, |
197 uploadMedia: _uploadMedia, | 200 uploadMedia: _uploadMedia, |
198 downloadOptions: _downloadOptions); | 201 downloadOptions: _downloadOptions); |
199 return _response.then((data) => new RuntimeConfig.fromJson(data)); | 202 return _response.then((data) => new RuntimeConfig.fromJson(data)); |
200 } | 203 } |
201 | 204 |
202 /** | 205 /** |
| 206 * Gets the access control policy for a resource. |
| 207 * Returns an empty policy if the resource exists and does not have a policy |
| 208 * set. |
| 209 * |
| 210 * Request parameters: |
| 211 * |
| 212 * [resource] - REQUIRED: The resource for which the policy is being |
| 213 * requested. |
| 214 * `resource` is usually specified as a path. For example, a Project |
| 215 * resource is specified as `projects/{project}`. |
| 216 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
| 217 * |
| 218 * Completes with a [Policy]. |
| 219 * |
| 220 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 221 * error. |
| 222 * |
| 223 * If the used [http.Client] completes with an error when making a REST call, |
| 224 * this method will complete with the same error. |
| 225 */ |
| 226 async.Future<Policy> getIamPolicy(core.String resource) { |
| 227 var _url = null; |
| 228 var _queryParams = new core.Map(); |
| 229 var _uploadMedia = null; |
| 230 var _uploadOptions = null; |
| 231 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 232 var _body = null; |
| 233 |
| 234 if (resource == null) { |
| 235 throw new core.ArgumentError("Parameter resource is required."); |
| 236 } |
| 237 |
| 238 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':g
etIamPolicy'; |
| 239 |
| 240 var _response = _requester.request(_url, |
| 241 "GET", |
| 242 body: _body, |
| 243 queryParams: _queryParams, |
| 244 uploadOptions: _uploadOptions, |
| 245 uploadMedia: _uploadMedia, |
| 246 downloadOptions: _downloadOptions); |
| 247 return _response.then((data) => new Policy.fromJson(data)); |
| 248 } |
| 249 |
| 250 /** |
203 * Lists all the RuntimeConfig resources within project. | 251 * Lists all the RuntimeConfig resources within project. |
204 * | 252 * |
205 * Request parameters: | 253 * Request parameters: |
206 * | 254 * |
207 * [parent] - The [project | 255 * [parent] - The [project |
208 * ID](https://support.google.com/cloud/answer/6158840?hl=en&ref_topic=6158848
) | 256 * ID](https://support.google.com/cloud/answer/6158840?hl=en&ref_topic=6158848
) |
209 * for this request, in the format `projects/[PROJECT_ID]`. | 257 * for this request, in the format `projects/[PROJECT_ID]`. |
210 * Value must have pattern "^projects/[^/]+$". | 258 * Value must have pattern "^projects/[^/]+$". |
211 * | 259 * |
212 * [pageSize] - Specifies the number of results to return per page. If there | 260 * [pageSize] - Specifies the number of results to return per page. If there |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
249 "GET", | 297 "GET", |
250 body: _body, | 298 body: _body, |
251 queryParams: _queryParams, | 299 queryParams: _queryParams, |
252 uploadOptions: _uploadOptions, | 300 uploadOptions: _uploadOptions, |
253 uploadMedia: _uploadMedia, | 301 uploadMedia: _uploadMedia, |
254 downloadOptions: _downloadOptions); | 302 downloadOptions: _downloadOptions); |
255 return _response.then((data) => new ListConfigsResponse.fromJson(data)); | 303 return _response.then((data) => new ListConfigsResponse.fromJson(data)); |
256 } | 304 } |
257 | 305 |
258 /** | 306 /** |
| 307 * Sets the access control policy on the specified resource. Replaces any |
| 308 * existing policy. |
| 309 * |
| 310 * [request] - The metadata request object. |
| 311 * |
| 312 * Request parameters: |
| 313 * |
| 314 * [resource] - REQUIRED: The resource for which the policy is being |
| 315 * specified. |
| 316 * `resource` is usually specified as a path. For example, a Project |
| 317 * resource is specified as `projects/{project}`. |
| 318 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
| 319 * |
| 320 * Completes with a [Policy]. |
| 321 * |
| 322 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 323 * error. |
| 324 * |
| 325 * If the used [http.Client] completes with an error when making a REST call, |
| 326 * this method will complete with the same error. |
| 327 */ |
| 328 async.Future<Policy> setIamPolicy(SetIamPolicyRequest request, core.String res
ource) { |
| 329 var _url = null; |
| 330 var _queryParams = new core.Map(); |
| 331 var _uploadMedia = null; |
| 332 var _uploadOptions = null; |
| 333 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 334 var _body = null; |
| 335 |
| 336 if (request != null) { |
| 337 _body = convert.JSON.encode((request).toJson()); |
| 338 } |
| 339 if (resource == null) { |
| 340 throw new core.ArgumentError("Parameter resource is required."); |
| 341 } |
| 342 |
| 343 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':s
etIamPolicy'; |
| 344 |
| 345 var _response = _requester.request(_url, |
| 346 "POST", |
| 347 body: _body, |
| 348 queryParams: _queryParams, |
| 349 uploadOptions: _uploadOptions, |
| 350 uploadMedia: _uploadMedia, |
| 351 downloadOptions: _downloadOptions); |
| 352 return _response.then((data) => new Policy.fromJson(data)); |
| 353 } |
| 354 |
| 355 /** |
| 356 * Returns permissions that a caller has on the specified resource. |
| 357 * If the resource does not exist, this will return an empty set of |
| 358 * permissions, not a NOT_FOUND error. |
| 359 * |
| 360 * [request] - The metadata request object. |
| 361 * |
| 362 * Request parameters: |
| 363 * |
| 364 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 365 * requested. |
| 366 * `resource` is usually specified as a path. For example, a Project |
| 367 * resource is specified as `projects/{project}`. |
| 368 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
| 369 * |
| 370 * Completes with a [TestIamPermissionsResponse]. |
| 371 * |
| 372 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 373 * error. |
| 374 * |
| 375 * If the used [http.Client] completes with an error when making a REST call, |
| 376 * this method will complete with the same error. |
| 377 */ |
| 378 async.Future<TestIamPermissionsResponse> testIamPermissions(TestIamPermissions
Request request, core.String resource) { |
| 379 var _url = null; |
| 380 var _queryParams = new core.Map(); |
| 381 var _uploadMedia = null; |
| 382 var _uploadOptions = null; |
| 383 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 384 var _body = null; |
| 385 |
| 386 if (request != null) { |
| 387 _body = convert.JSON.encode((request).toJson()); |
| 388 } |
| 389 if (resource == null) { |
| 390 throw new core.ArgumentError("Parameter resource is required."); |
| 391 } |
| 392 |
| 393 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':t
estIamPermissions'; |
| 394 |
| 395 var _response = _requester.request(_url, |
| 396 "POST", |
| 397 body: _body, |
| 398 queryParams: _queryParams, |
| 399 uploadOptions: _uploadOptions, |
| 400 uploadMedia: _uploadMedia, |
| 401 downloadOptions: _downloadOptions); |
| 402 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); |
| 403 } |
| 404 |
| 405 /** |
259 * Updates a RuntimeConfig resource. The configuration must exist beforehand. | 406 * Updates a RuntimeConfig resource. The configuration must exist beforehand. |
260 * | 407 * |
261 * [request] - The metadata request object. | 408 * [request] - The metadata request object. |
262 * | 409 * |
263 * Request parameters: | 410 * Request parameters: |
264 * | 411 * |
265 * [name] - The name of the RuntimeConfig resource to update, in the format: | 412 * [name] - The name of the RuntimeConfig resource to update, in the format: |
266 * | 413 * |
267 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]` | 414 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]` |
268 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". | 415 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
346 var _response = _requester.request(_url, | 493 var _response = _requester.request(_url, |
347 "GET", | 494 "GET", |
348 body: _body, | 495 body: _body, |
349 queryParams: _queryParams, | 496 queryParams: _queryParams, |
350 uploadOptions: _uploadOptions, | 497 uploadOptions: _uploadOptions, |
351 uploadMedia: _uploadMedia, | 498 uploadMedia: _uploadMedia, |
352 downloadOptions: _downloadOptions); | 499 downloadOptions: _downloadOptions); |
353 return _response.then((data) => new Operation.fromJson(data)); | 500 return _response.then((data) => new Operation.fromJson(data)); |
354 } | 501 } |
355 | 502 |
| 503 /** |
| 504 * Returns permissions that a caller has on the specified resource. |
| 505 * If the resource does not exist, this will return an empty set of |
| 506 * permissions, not a NOT_FOUND error. |
| 507 * |
| 508 * Request parameters: |
| 509 * |
| 510 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 511 * requested. |
| 512 * `resource` is usually specified as a path. For example, a Project |
| 513 * resource is specified as `projects/{project}`. |
| 514 * Value must have pattern "^projects/[^/]+/configs/[^/]+/operations/.+$". |
| 515 * |
| 516 * [permissions] - The set of permissions to check for the `resource`. |
| 517 * Permissions with |
| 518 * wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 519 * information see |
| 520 * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
| 521 * |
| 522 * Completes with a [TestIamPermissionsResponse]. |
| 523 * |
| 524 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 525 * error. |
| 526 * |
| 527 * If the used [http.Client] completes with an error when making a REST call, |
| 528 * this method will complete with the same error. |
| 529 */ |
| 530 async.Future<TestIamPermissionsResponse> testIamPermissions(core.String resour
ce, {core.List<core.String> permissions}) { |
| 531 var _url = null; |
| 532 var _queryParams = new core.Map(); |
| 533 var _uploadMedia = null; |
| 534 var _uploadOptions = null; |
| 535 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 536 var _body = null; |
| 537 |
| 538 if (resource == null) { |
| 539 throw new core.ArgumentError("Parameter resource is required."); |
| 540 } |
| 541 if (permissions != null) { |
| 542 _queryParams["permissions"] = permissions; |
| 543 } |
| 544 |
| 545 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':t
estIamPermissions'; |
| 546 |
| 547 var _response = _requester.request(_url, |
| 548 "GET", |
| 549 body: _body, |
| 550 queryParams: _queryParams, |
| 551 uploadOptions: _uploadOptions, |
| 552 uploadMedia: _uploadMedia, |
| 553 downloadOptions: _downloadOptions); |
| 554 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); |
| 555 } |
| 556 |
356 } | 557 } |
357 | 558 |
358 | 559 |
359 class ProjectsConfigsVariablesResourceApi { | 560 class ProjectsConfigsVariablesResourceApi { |
360 final commons.ApiRequester _requester; | 561 final commons.ApiRequester _requester; |
361 | 562 |
362 ProjectsConfigsVariablesResourceApi(commons.ApiRequester client) : | 563 ProjectsConfigsVariablesResourceApi(commons.ApiRequester client) : |
363 _requester = client; | 564 _requester = client; |
364 | 565 |
365 /** | 566 /** |
(...skipping 10 matching lines...) Expand all Loading... |
376 * | 577 * |
377 * Request parameters: | 578 * Request parameters: |
378 * | 579 * |
379 * [parent] - The path to the RutimeConfig resource that this variable should | 580 * [parent] - The path to the RutimeConfig resource that this variable should |
380 * belong to. | 581 * belong to. |
381 * The configuration must exist beforehand; the path must by in the format: | 582 * The configuration must exist beforehand; the path must by in the format: |
382 * | 583 * |
383 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]` | 584 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]` |
384 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". | 585 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
385 * | 586 * |
386 * [requestId] - An optional unique request_id. If server receives two Create | 587 * [requestId] - An optional but recommended unique <code>request_id</code>. |
387 * requests with | 588 * If the server |
388 * the same request_id then second request will be ignored and the resource | 589 * receives two <code>create()</code> requests with the same |
389 * stored in the backend will be returned. Empty request_id fields are | 590 * <code>request_id</code>, then the second request will be ignored and the |
390 * ignored. | 591 * first resource created and stored in the backend is returned. |
391 * It is responsibility of the client to ensure uniqueness of the request_id | 592 * Empty <code>request_id</code> fields are ignored. |
392 * strings. | 593 * |
393 * The strings are limited to 64 characters. | 594 * It is responsibility of the client to ensure uniqueness of the |
| 595 * <code>request_id</code> strings. |
| 596 * |
| 597 * <code>request_id</code> strings are limited to 64 characters. |
394 * | 598 * |
395 * Completes with a [Variable]. | 599 * Completes with a [Variable]. |
396 * | 600 * |
397 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 601 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
398 * error. | 602 * error. |
399 * | 603 * |
400 * If the used [http.Client] completes with an error when making a REST call, | 604 * If the used [http.Client] completes with an error when making a REST call, |
401 * this method will complete with the same error. | 605 * this method will complete with the same error. |
402 */ | 606 */ |
403 async.Future<Variable> create(Variable request, core.String parent, {core.Stri
ng requestId}) { | 607 async.Future<Variable> create(Variable request, core.String parent, {core.Stri
ng requestId}) { |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
587 "GET", | 791 "GET", |
588 body: _body, | 792 body: _body, |
589 queryParams: _queryParams, | 793 queryParams: _queryParams, |
590 uploadOptions: _uploadOptions, | 794 uploadOptions: _uploadOptions, |
591 uploadMedia: _uploadMedia, | 795 uploadMedia: _uploadMedia, |
592 downloadOptions: _downloadOptions); | 796 downloadOptions: _downloadOptions); |
593 return _response.then((data) => new ListVariablesResponse.fromJson(data)); | 797 return _response.then((data) => new ListVariablesResponse.fromJson(data)); |
594 } | 798 } |
595 | 799 |
596 /** | 800 /** |
| 801 * Returns permissions that a caller has on the specified resource. |
| 802 * If the resource does not exist, this will return an empty set of |
| 803 * permissions, not a NOT_FOUND error. |
| 804 * |
| 805 * Request parameters: |
| 806 * |
| 807 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 808 * requested. |
| 809 * `resource` is usually specified as a path. For example, a Project |
| 810 * resource is specified as `projects/{project}`. |
| 811 * Value must have pattern "^projects/[^/]+/configs/[^/]+/variables/.+$". |
| 812 * |
| 813 * [permissions] - The set of permissions to check for the `resource`. |
| 814 * Permissions with |
| 815 * wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 816 * information see |
| 817 * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
| 818 * |
| 819 * Completes with a [TestIamPermissionsResponse]. |
| 820 * |
| 821 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 822 * error. |
| 823 * |
| 824 * If the used [http.Client] completes with an error when making a REST call, |
| 825 * this method will complete with the same error. |
| 826 */ |
| 827 async.Future<TestIamPermissionsResponse> testIamPermissions(core.String resour
ce, {core.List<core.String> permissions}) { |
| 828 var _url = null; |
| 829 var _queryParams = new core.Map(); |
| 830 var _uploadMedia = null; |
| 831 var _uploadOptions = null; |
| 832 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 833 var _body = null; |
| 834 |
| 835 if (resource == null) { |
| 836 throw new core.ArgumentError("Parameter resource is required."); |
| 837 } |
| 838 if (permissions != null) { |
| 839 _queryParams["permissions"] = permissions; |
| 840 } |
| 841 |
| 842 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':t
estIamPermissions'; |
| 843 |
| 844 var _response = _requester.request(_url, |
| 845 "GET", |
| 846 body: _body, |
| 847 queryParams: _queryParams, |
| 848 uploadOptions: _uploadOptions, |
| 849 uploadMedia: _uploadMedia, |
| 850 downloadOptions: _downloadOptions); |
| 851 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); |
| 852 } |
| 853 |
| 854 /** |
597 * Updates an existing variable with a new value. | 855 * Updates an existing variable with a new value. |
598 * | 856 * |
599 * [request] - The metadata request object. | 857 * [request] - The metadata request object. |
600 * | 858 * |
601 * Request parameters: | 859 * Request parameters: |
602 * | 860 * |
603 * [name] - The name of the variable to update, in the format: | 861 * [name] - The name of the variable to update, in the format: |
604 * | 862 * |
605 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/variables/[VARIABLE_NAME]` | 863 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/variables/[VARIABLE_NAME]` |
606 * Value must have pattern "^projects/[^/]+/configs/[^/]+/variables/.+$". | 864 * Value must have pattern "^projects/[^/]+/configs/[^/]+/variables/.+$". |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
721 * [request] - The metadata request object. | 979 * [request] - The metadata request object. |
722 * | 980 * |
723 * Request parameters: | 981 * Request parameters: |
724 * | 982 * |
725 * [parent] - The path to the configuration that will own the waiter. | 983 * [parent] - The path to the configuration that will own the waiter. |
726 * The configuration must exist beforehand; the path must by in the format: | 984 * The configuration must exist beforehand; the path must by in the format: |
727 * | 985 * |
728 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`. | 986 * `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`. |
729 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". | 987 * Value must have pattern "^projects/[^/]+/configs/[^/]+$". |
730 * | 988 * |
731 * [requestId] - An optional unique request_id. If server receives two Create | 989 * [requestId] - An optional but recommended unique <code>request_id</code>. |
732 * requests with | 990 * If the server |
733 * the same request_id then second request will be ignored and information | 991 * receives two <code>create()</code> requests with the same |
734 * stored in the backend will be returned. Empty request_id fields are | 992 * <code>request_id</code>, then the second request will be ignored and the |
735 * ignored. | 993 * first resource created and stored in the backend is returned. |
736 * It is responsibility of the client to ensure uniqueness of the request_id | 994 * Empty <code>request_id</code> fields are ignored. |
737 * strings. | 995 * |
738 * The strings are limited to 64 characters. | 996 * It is responsibility of the client to ensure uniqueness of the |
| 997 * <code>request_id</code> strings. |
| 998 * |
| 999 * <code>request_id</code> strings are limited to 64 characters. |
739 * | 1000 * |
740 * Completes with a [Operation]. | 1001 * Completes with a [Operation]. |
741 * | 1002 * |
742 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1003 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
743 * error. | 1004 * error. |
744 * | 1005 * |
745 * If the used [http.Client] completes with an error when making a REST call, | 1006 * If the used [http.Client] completes with an error when making a REST call, |
746 * this method will complete with the same error. | 1007 * this method will complete with the same error. |
747 */ | 1008 */ |
748 async.Future<Operation> create(Waiter request, core.String parent, {core.Strin
g requestId}) { | 1009 async.Future<Operation> create(Waiter request, core.String parent, {core.Strin
g requestId}) { |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
912 var _response = _requester.request(_url, | 1173 var _response = _requester.request(_url, |
913 "GET", | 1174 "GET", |
914 body: _body, | 1175 body: _body, |
915 queryParams: _queryParams, | 1176 queryParams: _queryParams, |
916 uploadOptions: _uploadOptions, | 1177 uploadOptions: _uploadOptions, |
917 uploadMedia: _uploadMedia, | 1178 uploadMedia: _uploadMedia, |
918 downloadOptions: _downloadOptions); | 1179 downloadOptions: _downloadOptions); |
919 return _response.then((data) => new ListWaitersResponse.fromJson(data)); | 1180 return _response.then((data) => new ListWaitersResponse.fromJson(data)); |
920 } | 1181 } |
921 | 1182 |
| 1183 /** |
| 1184 * Returns permissions that a caller has on the specified resource. |
| 1185 * If the resource does not exist, this will return an empty set of |
| 1186 * permissions, not a NOT_FOUND error. |
| 1187 * |
| 1188 * Request parameters: |
| 1189 * |
| 1190 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 1191 * requested. |
| 1192 * `resource` is usually specified as a path. For example, a Project |
| 1193 * resource is specified as `projects/{project}`. |
| 1194 * Value must have pattern "^projects/[^/]+/configs/[^/]+/waiters/[^/]+$". |
| 1195 * |
| 1196 * [permissions] - The set of permissions to check for the `resource`. |
| 1197 * Permissions with |
| 1198 * wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 1199 * information see |
| 1200 * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
| 1201 * |
| 1202 * Completes with a [TestIamPermissionsResponse]. |
| 1203 * |
| 1204 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1205 * error. |
| 1206 * |
| 1207 * If the used [http.Client] completes with an error when making a REST call, |
| 1208 * this method will complete with the same error. |
| 1209 */ |
| 1210 async.Future<TestIamPermissionsResponse> testIamPermissions(core.String resour
ce, {core.List<core.String> permissions}) { |
| 1211 var _url = null; |
| 1212 var _queryParams = new core.Map(); |
| 1213 var _uploadMedia = null; |
| 1214 var _uploadOptions = null; |
| 1215 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1216 var _body = null; |
| 1217 |
| 1218 if (resource == null) { |
| 1219 throw new core.ArgumentError("Parameter resource is required."); |
| 1220 } |
| 1221 if (permissions != null) { |
| 1222 _queryParams["permissions"] = permissions; |
| 1223 } |
| 1224 |
| 1225 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$resource') + ':t
estIamPermissions'; |
| 1226 |
| 1227 var _response = _requester.request(_url, |
| 1228 "GET", |
| 1229 body: _body, |
| 1230 queryParams: _queryParams, |
| 1231 uploadOptions: _uploadOptions, |
| 1232 uploadMedia: _uploadMedia, |
| 1233 downloadOptions: _downloadOptions); |
| 1234 return _response.then((data) => new TestIamPermissionsResponse.fromJson(data
)); |
| 1235 } |
| 1236 |
922 } | 1237 } |
923 | 1238 |
924 | 1239 |
925 | 1240 |
| 1241 /** Associates `members` with a `role`. */ |
| 1242 class Binding { |
| 1243 /** |
| 1244 * Specifies the identities requesting access for a Cloud Platform resource. |
| 1245 * `members` can have the following values: |
| 1246 * |
| 1247 * * `allUsers`: A special identifier that represents anyone who is |
| 1248 * on the internet; with or without a Google account. |
| 1249 * |
| 1250 * * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 1251 * who is authenticated with a Google account or a service account. |
| 1252 * |
| 1253 * * `user:{emailid}`: An email address that represents a specific Google |
| 1254 * account. For example, `alice@gmail.com` or `joe@example.com`. |
| 1255 * |
| 1256 * |
| 1257 * * `serviceAccount:{emailid}`: An email address that represents a service |
| 1258 * account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 1259 * |
| 1260 * * `group:{emailid}`: An email address that represents a Google group. |
| 1261 * For example, `admins@example.com`. |
| 1262 * |
| 1263 * * `domain:{domain}`: A Google Apps domain name that represents all the |
| 1264 * users of that domain. For example, `google.com` or `example.com`. |
| 1265 */ |
| 1266 core.List<core.String> members; |
| 1267 /** |
| 1268 * Role that is assigned to `members`. |
| 1269 * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
| 1270 * Required |
| 1271 */ |
| 1272 core.String role; |
| 1273 |
| 1274 Binding(); |
| 1275 |
| 1276 Binding.fromJson(core.Map _json) { |
| 1277 if (_json.containsKey("members")) { |
| 1278 members = _json["members"]; |
| 1279 } |
| 1280 if (_json.containsKey("role")) { |
| 1281 role = _json["role"]; |
| 1282 } |
| 1283 } |
| 1284 |
| 1285 core.Map toJson() { |
| 1286 var _json = new core.Map(); |
| 1287 if (members != null) { |
| 1288 _json["members"] = members; |
| 1289 } |
| 1290 if (role != null) { |
| 1291 _json["role"] = role; |
| 1292 } |
| 1293 return _json; |
| 1294 } |
| 1295 } |
| 1296 |
926 /** | 1297 /** |
927 * A Cardinality condition for the Waiter resource. A cardinality condition is | 1298 * A Cardinality condition for the Waiter resource. A cardinality condition is |
928 * met when the number of variables under a specified path prefix reaches a | 1299 * met when the number of variables under a specified path prefix reaches a |
929 * predefined number. For example, if you set a Cardinality condition where | 1300 * predefined number. For example, if you set a Cardinality condition where |
930 * the `path` is set to `/foo` and the number of paths is set to 2, the | 1301 * the `path` is set to `/foo` and the number of paths is set to 2, the |
931 * following variables would meet the condition in a RuntimeConfig resource: | 1302 * following variables would meet the condition in a RuntimeConfig resource: |
932 * | 1303 * |
933 * + `/foo/variable1 = "value1"` | 1304 * + `/foo/variable1 = "value1"` |
934 * + `/foo/variable2 = "value2"` | 1305 * + `/foo/variable2 = "value2"` |
935 * + `/bar/variable3 = "value3"` | 1306 * + `/bar/variable3 = "value3"` |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1216 _json["name"] = name; | 1587 _json["name"] = name; |
1217 } | 1588 } |
1218 if (response != null) { | 1589 if (response != null) { |
1219 _json["response"] = response; | 1590 _json["response"] = response; |
1220 } | 1591 } |
1221 return _json; | 1592 return _json; |
1222 } | 1593 } |
1223 } | 1594 } |
1224 | 1595 |
1225 /** | 1596 /** |
| 1597 * Defines an Identity and Access Management (IAM) policy. It is used to |
| 1598 * specify access control policies for Cloud Platform resources. |
| 1599 * |
| 1600 * |
| 1601 * A `Policy` consists of a list of `bindings`. A `Binding` binds a list of |
| 1602 * `members` to a `role`, where the members can be user accounts, Google groups, |
| 1603 * Google domains, and service accounts. A `role` is a named list of permissions |
| 1604 * defined by IAM. |
| 1605 * |
| 1606 * **Example** |
| 1607 * |
| 1608 * { |
| 1609 * "bindings": [ |
| 1610 * { |
| 1611 * "role": "roles/owner", |
| 1612 * "members": [ |
| 1613 * "user:mike@example.com", |
| 1614 * "group:admins@example.com", |
| 1615 * "domain:google.com", |
| 1616 * "serviceAccount:my-other-app@appspot.gserviceaccount.com", |
| 1617 * ] |
| 1618 * }, |
| 1619 * { |
| 1620 * "role": "roles/viewer", |
| 1621 * "members": ["user:sean@example.com"] |
| 1622 * } |
| 1623 * ] |
| 1624 * } |
| 1625 * |
| 1626 * For a description of IAM and its features, see the |
| 1627 * [IAM developer's guide](https://cloud.google.com/iam). |
| 1628 */ |
| 1629 class Policy { |
| 1630 /** |
| 1631 * Associates a list of `members` to a `role`. |
| 1632 * Multiple `bindings` must not be specified for the same `role`. |
| 1633 * `bindings` with no members will result in an error. |
| 1634 */ |
| 1635 core.List<Binding> bindings; |
| 1636 /** |
| 1637 * `etag` is used for optimistic concurrency control as a way to help |
| 1638 * prevent simultaneous updates of a policy from overwriting each other. |
| 1639 * It is strongly suggested that systems make use of the `etag` in the |
| 1640 * read-modify-write cycle to perform policy updates in order to avoid race |
| 1641 * conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 1642 * systems are expected to put that etag in the request to `setIamPolicy` to |
| 1643 * ensure that their change will be applied to the same version of the policy. |
| 1644 * |
| 1645 * If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 1646 * policy is overwritten blindly. |
| 1647 */ |
| 1648 core.String etag; |
| 1649 core.List<core.int> get etagAsBytes { |
| 1650 return convert.BASE64.decode(etag); |
| 1651 } |
| 1652 |
| 1653 void set etagAsBytes(core.List<core.int> _bytes) { |
| 1654 etag = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "-
"); |
| 1655 } |
| 1656 /** Version of the `Policy`. The default version is 0. */ |
| 1657 core.int version; |
| 1658 |
| 1659 Policy(); |
| 1660 |
| 1661 Policy.fromJson(core.Map _json) { |
| 1662 if (_json.containsKey("bindings")) { |
| 1663 bindings = _json["bindings"].map((value) => new Binding.fromJson(value)).t
oList(); |
| 1664 } |
| 1665 if (_json.containsKey("etag")) { |
| 1666 etag = _json["etag"]; |
| 1667 } |
| 1668 if (_json.containsKey("version")) { |
| 1669 version = _json["version"]; |
| 1670 } |
| 1671 } |
| 1672 |
| 1673 core.Map toJson() { |
| 1674 var _json = new core.Map(); |
| 1675 if (bindings != null) { |
| 1676 _json["bindings"] = bindings.map((value) => (value).toJson()).toList(); |
| 1677 } |
| 1678 if (etag != null) { |
| 1679 _json["etag"] = etag; |
| 1680 } |
| 1681 if (version != null) { |
| 1682 _json["version"] = version; |
| 1683 } |
| 1684 return _json; |
| 1685 } |
| 1686 } |
| 1687 |
| 1688 /** |
1226 * A RuntimeConfig resource is the primary resource in the Cloud RuntimeConfig | 1689 * A RuntimeConfig resource is the primary resource in the Cloud RuntimeConfig |
1227 * service. A RuntimeConfig resource consists of metadata and a hierarchy of | 1690 * service. A RuntimeConfig resource consists of metadata and a hierarchy of |
1228 * variables. | 1691 * variables. |
1229 */ | 1692 */ |
1230 class RuntimeConfig { | 1693 class RuntimeConfig { |
1231 /** | 1694 /** An optional description of the RuntimeConfig object. */ |
1232 * An optional description of the RuntimeConfig object. | |
1233 * The length of the description must be less than 256 bytes. | |
1234 */ | |
1235 core.String description; | 1695 core.String description; |
1236 /** | 1696 /** |
1237 * The resource name of a runtime config. The name must have the format: | 1697 * The resource name of a runtime config. The name must have the format: |
1238 * | 1698 * |
1239 * projects/[PROJECT_ID]/configs/[CONFIG_NAME] | 1699 * projects/[PROJECT_ID]/configs/[CONFIG_NAME] |
1240 * | 1700 * |
1241 * The `[PROJECT_ID]` must be a valid project ID, and `[CONFIG_NAME]` is an | 1701 * The `[PROJECT_ID]` must be a valid project ID, and `[CONFIG_NAME]` is an |
1242 * arbitrary name that matches RFC 1035 segment specification. The length of | 1702 * arbitrary name that matches RFC 1035 segment specification. The length of |
1243 * `[CONFIG_NAME]` must be less than 64 bytes. | 1703 * `[CONFIG_NAME]` must be less than 64 bytes. |
1244 * | 1704 * |
(...skipping 19 matching lines...) Expand all Loading... |
1264 if (description != null) { | 1724 if (description != null) { |
1265 _json["description"] = description; | 1725 _json["description"] = description; |
1266 } | 1726 } |
1267 if (name != null) { | 1727 if (name != null) { |
1268 _json["name"] = name; | 1728 _json["name"] = name; |
1269 } | 1729 } |
1270 return _json; | 1730 return _json; |
1271 } | 1731 } |
1272 } | 1732 } |
1273 | 1733 |
| 1734 /** Request message for `SetIamPolicy` method. */ |
| 1735 class SetIamPolicyRequest { |
| 1736 /** |
| 1737 * REQUIRED: The complete policy to be applied to the `resource`. The size of |
| 1738 * the policy is limited to a few 10s of KB. An empty policy is a |
| 1739 * valid policy but certain Cloud Platform services (such as Projects) |
| 1740 * might reject them. |
| 1741 */ |
| 1742 Policy policy; |
| 1743 |
| 1744 SetIamPolicyRequest(); |
| 1745 |
| 1746 SetIamPolicyRequest.fromJson(core.Map _json) { |
| 1747 if (_json.containsKey("policy")) { |
| 1748 policy = new Policy.fromJson(_json["policy"]); |
| 1749 } |
| 1750 } |
| 1751 |
| 1752 core.Map toJson() { |
| 1753 var _json = new core.Map(); |
| 1754 if (policy != null) { |
| 1755 _json["policy"] = (policy).toJson(); |
| 1756 } |
| 1757 return _json; |
| 1758 } |
| 1759 } |
| 1760 |
1274 /** | 1761 /** |
1275 * The `Status` type defines a logical error model that is suitable for | 1762 * The `Status` type defines a logical error model that is suitable for |
1276 * different | 1763 * different |
1277 * programming environments, including REST APIs and RPC APIs. It is used by | 1764 * programming environments, including REST APIs and RPC APIs. It is used by |
1278 * [gRPC](https://github.com/grpc). The error model is designed to be: | 1765 * [gRPC](https://github.com/grpc). The error model is designed to be: |
1279 * | 1766 * |
1280 * - Simple to use and understand for most users | 1767 * - Simple to use and understand for most users |
1281 * - Flexible enough to meet unexpected needs | 1768 * - Flexible enough to meet unexpected needs |
1282 * | 1769 * |
1283 * # Overview | 1770 * # Overview |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1367 if (details != null) { | 1854 if (details != null) { |
1368 _json["details"] = details; | 1855 _json["details"] = details; |
1369 } | 1856 } |
1370 if (message != null) { | 1857 if (message != null) { |
1371 _json["message"] = message; | 1858 _json["message"] = message; |
1372 } | 1859 } |
1373 return _json; | 1860 return _json; |
1374 } | 1861 } |
1375 } | 1862 } |
1376 | 1863 |
| 1864 /** Request message for `TestIamPermissions` method. */ |
| 1865 class TestIamPermissionsRequest { |
| 1866 /** |
| 1867 * The set of permissions to check for the `resource`. Permissions with |
| 1868 * wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 1869 * information see |
| 1870 * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
| 1871 */ |
| 1872 core.List<core.String> permissions; |
| 1873 |
| 1874 TestIamPermissionsRequest(); |
| 1875 |
| 1876 TestIamPermissionsRequest.fromJson(core.Map _json) { |
| 1877 if (_json.containsKey("permissions")) { |
| 1878 permissions = _json["permissions"]; |
| 1879 } |
| 1880 } |
| 1881 |
| 1882 core.Map toJson() { |
| 1883 var _json = new core.Map(); |
| 1884 if (permissions != null) { |
| 1885 _json["permissions"] = permissions; |
| 1886 } |
| 1887 return _json; |
| 1888 } |
| 1889 } |
| 1890 |
| 1891 /** Response message for `TestIamPermissions` method. */ |
| 1892 class TestIamPermissionsResponse { |
| 1893 /** |
| 1894 * A subset of `TestPermissionsRequest.permissions` that the caller is |
| 1895 * allowed. |
| 1896 */ |
| 1897 core.List<core.String> permissions; |
| 1898 |
| 1899 TestIamPermissionsResponse(); |
| 1900 |
| 1901 TestIamPermissionsResponse.fromJson(core.Map _json) { |
| 1902 if (_json.containsKey("permissions")) { |
| 1903 permissions = _json["permissions"]; |
| 1904 } |
| 1905 } |
| 1906 |
| 1907 core.Map toJson() { |
| 1908 var _json = new core.Map(); |
| 1909 if (permissions != null) { |
| 1910 _json["permissions"] = permissions; |
| 1911 } |
| 1912 return _json; |
| 1913 } |
| 1914 } |
| 1915 |
1377 /** | 1916 /** |
1378 * Describes a single variable within a RuntimeConfig resource. | 1917 * Describes a single variable within a RuntimeConfig resource. |
1379 * The name denotes the hierarchical variable name. For example, | 1918 * The name denotes the hierarchical variable name. For example, |
1380 * `ports/serving_port` is a valid variable name. The variable value is an | 1919 * `ports/serving_port` is a valid variable name. The variable value is an |
1381 * opaque string and only leaf variables can have values (that is, variables | 1920 * opaque string and only leaf variables can have values (that is, variables |
1382 * that do not have any child variables). | 1921 * that do not have any child variables). |
1383 */ | 1922 */ |
1384 class Variable { | 1923 class Variable { |
1385 /** | 1924 /** |
1386 * The name of the variable resource, in the format: | 1925 * The name of the variable resource, in the format: |
(...skipping 21 matching lines...) Expand all Loading... |
1408 * `get` and `list` calls. | 1947 * `get` and `list` calls. |
1409 * Possible string values are: | 1948 * Possible string values are: |
1410 * - "VARIABLE_STATE_UNSPECIFIED" : Default variable state. | 1949 * - "VARIABLE_STATE_UNSPECIFIED" : Default variable state. |
1411 * - "UPDATED" : The variable was updated, while `variables().watch` was | 1950 * - "UPDATED" : The variable was updated, while `variables().watch` was |
1412 * executing. | 1951 * executing. |
1413 * - "DELETED" : The variable was deleted, while `variables().watch` was | 1952 * - "DELETED" : The variable was deleted, while `variables().watch` was |
1414 * executing. | 1953 * executing. |
1415 */ | 1954 */ |
1416 core.String state; | 1955 core.String state; |
1417 /** | 1956 /** |
1418 * The textual value of the variable. The length of the value must be less | 1957 * The string value of the variable. The length of the value must be less |
1419 * than 4096 bytes. Empty values are also accepted. | 1958 * than 4096 bytes. Empty values are also accepted. For example, |
1420 * NB: Only one of value and string_value can be set at the same time. | 1959 * <code>text: "my text value"</code>. |
1421 */ | 1960 */ |
1422 core.String text; | 1961 core.String text; |
1423 /** [Output Only] The time of the last variable update. */ | 1962 /** [Output Only] The time of the last variable update. */ |
1424 core.String updateTime; | 1963 core.String updateTime; |
1425 /** | 1964 /** |
1426 * The binary value of the variable. The length of the value must be less | 1965 * The binary value of the variable. The length of the value must be less |
1427 * than 4096 bytes. Empty values are also accepted. The value must be | 1966 * than 4096 bytes. Empty values are also accepted. The value must be |
1428 * Base64 encoded. | 1967 * base64 encoded. Only one of `value` or `text` can be set. |
1429 * NB: Only one of value and string_value can be set at the same time. | |
1430 */ | 1968 */ |
1431 core.String value; | 1969 core.String value; |
1432 core.List<core.int> get valueAsBytes { | 1970 core.List<core.int> get valueAsBytes { |
1433 return convert.BASE64.decode(value); | 1971 return convert.BASE64.decode(value); |
1434 } | 1972 } |
1435 | 1973 |
1436 void set valueAsBytes(core.List<core.int> _bytes) { | 1974 void set valueAsBytes(core.List<core.int> _bytes) { |
1437 value = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "
-"); | 1975 value = convert.BASE64.encode(_bytes).replaceAll("/", "_").replaceAll("+", "
-"); |
1438 } | 1976 } |
1439 | 1977 |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1628 } | 2166 } |
1629 | 2167 |
1630 core.Map toJson() { | 2168 core.Map toJson() { |
1631 var _json = new core.Map(); | 2169 var _json = new core.Map(); |
1632 if (newerThan != null) { | 2170 if (newerThan != null) { |
1633 _json["newerThan"] = newerThan; | 2171 _json["newerThan"] = newerThan; |
1634 } | 2172 } |
1635 return _json; | 2173 return _json; |
1636 } | 2174 } |
1637 } | 2175 } |
OLD | NEW |