| 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.pubsub.v1beta2; | 3 library googleapis_beta.pubsub.v1beta2; |
| 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 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 } | 288 } |
| 289 | 289 |
| 290 /** | 290 /** |
| 291 * Lists matching subscriptions. | 291 * Lists matching subscriptions. |
| 292 * | 292 * |
| 293 * Request parameters: | 293 * Request parameters: |
| 294 * | 294 * |
| 295 * [project] - The name of the cloud project that subscriptions belong to. | 295 * [project] - The name of the cloud project that subscriptions belong to. |
| 296 * Value must have pattern "^projects/[^/]+$". | 296 * Value must have pattern "^projects/[^/]+$". |
| 297 * | 297 * |
| 298 * [pageSize] - Maximum number of subscriptions to return. | |
| 299 * | |
| 300 * [pageToken] - The value returned by the last `ListSubscriptionsResponse`; | 298 * [pageToken] - The value returned by the last `ListSubscriptionsResponse`; |
| 301 * indicates that | 299 * indicates that |
| 302 * this is a continuation of a prior `ListSubscriptions` call, and that the | 300 * this is a continuation of a prior `ListSubscriptions` call, and that the |
| 303 * system should return the next page of data. | 301 * system should return the next page of data. |
| 304 * | 302 * |
| 303 * [pageSize] - Maximum number of subscriptions to return. |
| 304 * |
| 305 * Completes with a [ListSubscriptionsResponse]. | 305 * Completes with a [ListSubscriptionsResponse]. |
| 306 * | 306 * |
| 307 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 307 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 308 * error. | 308 * error. |
| 309 * | 309 * |
| 310 * If the used [http.Client] completes with an error when making a REST call, | 310 * If the used [http.Client] completes with an error when making a REST call, |
| 311 * this method will complete with the same error. | 311 * this method will complete with the same error. |
| 312 */ | 312 */ |
| 313 async.Future<ListSubscriptionsResponse> list(core.String project, {core.int pa
geSize, core.String pageToken}) { | 313 async.Future<ListSubscriptionsResponse> list(core.String project, {core.String
pageToken, core.int pageSize}) { |
| 314 var _url = null; | 314 var _url = null; |
| 315 var _queryParams = new core.Map(); | 315 var _queryParams = new core.Map(); |
| 316 var _uploadMedia = null; | 316 var _uploadMedia = null; |
| 317 var _uploadOptions = null; | 317 var _uploadOptions = null; |
| 318 var _downloadOptions = commons.DownloadOptions.Metadata; | 318 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 319 var _body = null; | 319 var _body = null; |
| 320 | 320 |
| 321 if (project == null) { | 321 if (project == null) { |
| 322 throw new core.ArgumentError("Parameter project is required."); | 322 throw new core.ArgumentError("Parameter project is required."); |
| 323 } | 323 } |
| 324 if (pageToken != null) { |
| 325 _queryParams["pageToken"] = [pageToken]; |
| 326 } |
| 324 if (pageSize != null) { | 327 if (pageSize != null) { |
| 325 _queryParams["pageSize"] = ["${pageSize}"]; | 328 _queryParams["pageSize"] = ["${pageSize}"]; |
| 326 } | 329 } |
| 327 if (pageToken != null) { | |
| 328 _queryParams["pageToken"] = [pageToken]; | |
| 329 } | |
| 330 | 330 |
| 331 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$project') + '/su
bscriptions'; | 331 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$project') + '/su
bscriptions'; |
| 332 | 332 |
| 333 var _response = _requester.request(_url, | 333 var _response = _requester.request(_url, |
| 334 "GET", | 334 "GET", |
| 335 body: _body, | 335 body: _body, |
| 336 queryParams: _queryParams, | 336 queryParams: _queryParams, |
| 337 uploadOptions: _uploadOptions, | 337 uploadOptions: _uploadOptions, |
| 338 uploadMedia: _uploadMedia, | 338 uploadMedia: _uploadMedia, |
| 339 downloadOptions: _downloadOptions); | 339 downloadOptions: _downloadOptions); |
| (...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 777 } | 777 } |
| 778 | 778 |
| 779 /** | 779 /** |
| 780 * Lists matching topics. | 780 * Lists matching topics. |
| 781 * | 781 * |
| 782 * Request parameters: | 782 * Request parameters: |
| 783 * | 783 * |
| 784 * [project] - The name of the cloud project that topics belong to. | 784 * [project] - The name of the cloud project that topics belong to. |
| 785 * Value must have pattern "^projects/[^/]+$". | 785 * Value must have pattern "^projects/[^/]+$". |
| 786 * | 786 * |
| 787 * [pageSize] - Maximum number of topics to return. | |
| 788 * | |
| 789 * [pageToken] - The value returned by the last `ListTopicsResponse`; | 787 * [pageToken] - The value returned by the last `ListTopicsResponse`; |
| 790 * indicates that this is | 788 * indicates that this is |
| 791 * a continuation of a prior `ListTopics` call, and that the system should | 789 * a continuation of a prior `ListTopics` call, and that the system should |
| 792 * return the next page of data. | 790 * return the next page of data. |
| 793 * | 791 * |
| 792 * [pageSize] - Maximum number of topics to return. |
| 793 * |
| 794 * Completes with a [ListTopicsResponse]. | 794 * Completes with a [ListTopicsResponse]. |
| 795 * | 795 * |
| 796 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 796 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 797 * error. | 797 * error. |
| 798 * | 798 * |
| 799 * If the used [http.Client] completes with an error when making a REST call, | 799 * If the used [http.Client] completes with an error when making a REST call, |
| 800 * this method will complete with the same error. | 800 * this method will complete with the same error. |
| 801 */ | 801 */ |
| 802 async.Future<ListTopicsResponse> list(core.String project, {core.int pageSize,
core.String pageToken}) { | 802 async.Future<ListTopicsResponse> list(core.String project, {core.String pageTo
ken, core.int pageSize}) { |
| 803 var _url = null; | 803 var _url = null; |
| 804 var _queryParams = new core.Map(); | 804 var _queryParams = new core.Map(); |
| 805 var _uploadMedia = null; | 805 var _uploadMedia = null; |
| 806 var _uploadOptions = null; | 806 var _uploadOptions = null; |
| 807 var _downloadOptions = commons.DownloadOptions.Metadata; | 807 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 808 var _body = null; | 808 var _body = null; |
| 809 | 809 |
| 810 if (project == null) { | 810 if (project == null) { |
| 811 throw new core.ArgumentError("Parameter project is required."); | 811 throw new core.ArgumentError("Parameter project is required."); |
| 812 } | 812 } |
| 813 if (pageToken != null) { |
| 814 _queryParams["pageToken"] = [pageToken]; |
| 815 } |
| 813 if (pageSize != null) { | 816 if (pageSize != null) { |
| 814 _queryParams["pageSize"] = ["${pageSize}"]; | 817 _queryParams["pageSize"] = ["${pageSize}"]; |
| 815 } | 818 } |
| 816 if (pageToken != null) { | |
| 817 _queryParams["pageToken"] = [pageToken]; | |
| 818 } | |
| 819 | 819 |
| 820 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$project') + '/to
pics'; | 820 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$project') + '/to
pics'; |
| 821 | 821 |
| 822 var _response = _requester.request(_url, | 822 var _response = _requester.request(_url, |
| 823 "GET", | 823 "GET", |
| 824 body: _body, | 824 body: _body, |
| 825 queryParams: _queryParams, | 825 queryParams: _queryParams, |
| 826 uploadOptions: _uploadOptions, | 826 uploadOptions: _uploadOptions, |
| 827 uploadMedia: _uploadMedia, | 827 uploadMedia: _uploadMedia, |
| 828 downloadOptions: _downloadOptions); | 828 downloadOptions: _downloadOptions); |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 985 _requester = client; | 985 _requester = client; |
| 986 | 986 |
| 987 /** | 987 /** |
| 988 * Lists the name of the subscriptions for this topic. | 988 * Lists the name of the subscriptions for this topic. |
| 989 * | 989 * |
| 990 * Request parameters: | 990 * Request parameters: |
| 991 * | 991 * |
| 992 * [topic] - The name of the topic that subscriptions are attached to. | 992 * [topic] - The name of the topic that subscriptions are attached to. |
| 993 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". | 993 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". |
| 994 * | 994 * |
| 995 * [pageSize] - Maximum number of subscription names to return. | |
| 996 * | |
| 997 * [pageToken] - The value returned by the last | 995 * [pageToken] - The value returned by the last |
| 998 * `ListTopicSubscriptionsResponse`; indicates | 996 * `ListTopicSubscriptionsResponse`; indicates |
| 999 * that this is a continuation of a prior `ListTopicSubscriptions` call, and | 997 * that this is a continuation of a prior `ListTopicSubscriptions` call, and |
| 1000 * that the system should return the next page of data. | 998 * that the system should return the next page of data. |
| 1001 * | 999 * |
| 1000 * [pageSize] - Maximum number of subscription names to return. |
| 1001 * |
| 1002 * Completes with a [ListTopicSubscriptionsResponse]. | 1002 * Completes with a [ListTopicSubscriptionsResponse]. |
| 1003 * | 1003 * |
| 1004 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1004 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1005 * error. | 1005 * error. |
| 1006 * | 1006 * |
| 1007 * If the used [http.Client] completes with an error when making a REST call, | 1007 * If the used [http.Client] completes with an error when making a REST call, |
| 1008 * this method will complete with the same error. | 1008 * this method will complete with the same error. |
| 1009 */ | 1009 */ |
| 1010 async.Future<ListTopicSubscriptionsResponse> list(core.String topic, {core.int
pageSize, core.String pageToken}) { | 1010 async.Future<ListTopicSubscriptionsResponse> list(core.String topic, {core.Str
ing pageToken, core.int pageSize}) { |
| 1011 var _url = null; | 1011 var _url = null; |
| 1012 var _queryParams = new core.Map(); | 1012 var _queryParams = new core.Map(); |
| 1013 var _uploadMedia = null; | 1013 var _uploadMedia = null; |
| 1014 var _uploadOptions = null; | 1014 var _uploadOptions = null; |
| 1015 var _downloadOptions = commons.DownloadOptions.Metadata; | 1015 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1016 var _body = null; | 1016 var _body = null; |
| 1017 | 1017 |
| 1018 if (topic == null) { | 1018 if (topic == null) { |
| 1019 throw new core.ArgumentError("Parameter topic is required."); | 1019 throw new core.ArgumentError("Parameter topic is required."); |
| 1020 } | 1020 } |
| 1021 if (pageToken != null) { |
| 1022 _queryParams["pageToken"] = [pageToken]; |
| 1023 } |
| 1021 if (pageSize != null) { | 1024 if (pageSize != null) { |
| 1022 _queryParams["pageSize"] = ["${pageSize}"]; | 1025 _queryParams["pageSize"] = ["${pageSize}"]; |
| 1023 } | 1026 } |
| 1024 if (pageToken != null) { | |
| 1025 _queryParams["pageToken"] = [pageToken]; | |
| 1026 } | |
| 1027 | 1027 |
| 1028 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$topic') + '/subs
criptions'; | 1028 _url = 'v1beta2/' + commons.Escaper.ecapeVariableReserved('$topic') + '/subs
criptions'; |
| 1029 | 1029 |
| 1030 var _response = _requester.request(_url, | 1030 var _response = _requester.request(_url, |
| 1031 "GET", | 1031 "GET", |
| 1032 body: _body, | 1032 body: _body, |
| 1033 queryParams: _queryParams, | 1033 queryParams: _queryParams, |
| 1034 uploadOptions: _uploadOptions, | 1034 uploadOptions: _uploadOptions, |
| 1035 uploadMedia: _uploadMedia, | 1035 uploadMedia: _uploadMedia, |
| 1036 downloadOptions: _downloadOptions); | 1036 downloadOptions: _downloadOptions); |
| (...skipping 826 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1863 } | 1863 } |
| 1864 | 1864 |
| 1865 core.Map toJson() { | 1865 core.Map toJson() { |
| 1866 var _json = new core.Map(); | 1866 var _json = new core.Map(); |
| 1867 if (name != null) { | 1867 if (name != null) { |
| 1868 _json["name"] = name; | 1868 _json["name"] = name; |
| 1869 } | 1869 } |
| 1870 return _json; | 1870 return _json; |
| 1871 } | 1871 } |
| 1872 } | 1872 } |
| OLD | NEW |