| 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.pubsub.v1; | 3 library googleapis.pubsub.v1; |
| 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 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 | 54 |
| 55 /** | 55 /** |
| 56 * Gets the access control policy for a resource. | 56 * Gets the access control policy for a resource. |
| 57 * Returns an empty policy if the resource exists and does not have a policy | 57 * Returns an empty policy if the resource exists and does not have a policy |
| 58 * set. | 58 * set. |
| 59 * | 59 * |
| 60 * Request parameters: | 60 * Request parameters: |
| 61 * | 61 * |
| 62 * [resource] - REQUIRED: The resource for which the policy is being | 62 * [resource] - REQUIRED: The resource for which the policy is being |
| 63 * requested. | 63 * requested. |
| 64 * `resource` is usually specified as a path. For example, a Project | 64 * See the operation documentation for the appropriate value for this field. |
| 65 * resource is specified as `projects/{project}`. | |
| 66 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". | 65 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". |
| 67 * | 66 * |
| 68 * Completes with a [Policy]. | 67 * Completes with a [Policy]. |
| 69 * | 68 * |
| 70 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 69 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 71 * error. | 70 * error. |
| 72 * | 71 * |
| 73 * If the used [http.Client] completes with an error when making a REST call, | 72 * If the used [http.Client] completes with an error when making a REST call, |
| 74 * this method will complete with the same error. | 73 * this method will complete with the same error. |
| 75 */ | 74 */ |
| (...skipping 24 matching lines...) Expand all Loading... |
| 100 /** | 99 /** |
| 101 * Sets the access control policy on the specified resource. Replaces any | 100 * Sets the access control policy on the specified resource. Replaces any |
| 102 * existing policy. | 101 * existing policy. |
| 103 * | 102 * |
| 104 * [request] - The metadata request object. | 103 * [request] - The metadata request object. |
| 105 * | 104 * |
| 106 * Request parameters: | 105 * Request parameters: |
| 107 * | 106 * |
| 108 * [resource] - REQUIRED: The resource for which the policy is being | 107 * [resource] - REQUIRED: The resource for which the policy is being |
| 109 * specified. | 108 * specified. |
| 110 * `resource` is usually specified as a path. For example, a Project | 109 * See the operation documentation for the appropriate value for this field. |
| 111 * resource is specified as `projects/{project}`. | |
| 112 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". | 110 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". |
| 113 * | 111 * |
| 114 * Completes with a [Policy]. | 112 * Completes with a [Policy]. |
| 115 * | 113 * |
| 116 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 114 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 117 * error. | 115 * error. |
| 118 * | 116 * |
| 119 * If the used [http.Client] completes with an error when making a REST call, | 117 * If the used [http.Client] completes with an error when making a REST call, |
| 120 * this method will complete with the same error. | 118 * this method will complete with the same error. |
| 121 */ | 119 */ |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 154 * Note: This operation is designed to be used for building permission-aware | 152 * Note: This operation is designed to be used for building permission-aware |
| 155 * UIs and command-line tools, not for authorization checking. This operation | 153 * UIs and command-line tools, not for authorization checking. This operation |
| 156 * may "fail open" without warning. | 154 * may "fail open" without warning. |
| 157 * | 155 * |
| 158 * [request] - The metadata request object. | 156 * [request] - The metadata request object. |
| 159 * | 157 * |
| 160 * Request parameters: | 158 * Request parameters: |
| 161 * | 159 * |
| 162 * [resource] - REQUIRED: The resource for which the policy detail is being | 160 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 163 * requested. | 161 * requested. |
| 164 * `resource` is usually specified as a path. For example, a Project | 162 * See the operation documentation for the appropriate value for this field. |
| 165 * resource is specified as `projects/{project}`. | |
| 166 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". | 163 * Value must have pattern "^projects/[^/]+/snapshots/[^/]+$". |
| 167 * | 164 * |
| 168 * Completes with a [TestIamPermissionsResponse]. | 165 * Completes with a [TestIamPermissionsResponse]. |
| 169 * | 166 * |
| 170 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 167 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 171 * error. | 168 * error. |
| 172 * | 169 * |
| 173 * If the used [http.Client] completes with an error when making a REST call, | 170 * If the used [http.Client] completes with an error when making a REST call, |
| 174 * this method will complete with the same error. | 171 * this method will complete with the same error. |
| 175 */ | 172 */ |
| (...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 409 | 406 |
| 410 /** | 407 /** |
| 411 * Gets the access control policy for a resource. | 408 * Gets the access control policy for a resource. |
| 412 * Returns an empty policy if the resource exists and does not have a policy | 409 * Returns an empty policy if the resource exists and does not have a policy |
| 413 * set. | 410 * set. |
| 414 * | 411 * |
| 415 * Request parameters: | 412 * Request parameters: |
| 416 * | 413 * |
| 417 * [resource] - REQUIRED: The resource for which the policy is being | 414 * [resource] - REQUIRED: The resource for which the policy is being |
| 418 * requested. | 415 * requested. |
| 419 * `resource` is usually specified as a path. For example, a Project | 416 * See the operation documentation for the appropriate value for this field. |
| 420 * resource is specified as `projects/{project}`. | |
| 421 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". | 417 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". |
| 422 * | 418 * |
| 423 * Completes with a [Policy]. | 419 * Completes with a [Policy]. |
| 424 * | 420 * |
| 425 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 421 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 426 * error. | 422 * error. |
| 427 * | 423 * |
| 428 * If the used [http.Client] completes with an error when making a REST call, | 424 * If the used [http.Client] completes with an error when making a REST call, |
| 429 * this method will complete with the same error. | 425 * this method will complete with the same error. |
| 430 */ | 426 */ |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 659 /** | 655 /** |
| 660 * Sets the access control policy on the specified resource. Replaces any | 656 * Sets the access control policy on the specified resource. Replaces any |
| 661 * existing policy. | 657 * existing policy. |
| 662 * | 658 * |
| 663 * [request] - The metadata request object. | 659 * [request] - The metadata request object. |
| 664 * | 660 * |
| 665 * Request parameters: | 661 * Request parameters: |
| 666 * | 662 * |
| 667 * [resource] - REQUIRED: The resource for which the policy is being | 663 * [resource] - REQUIRED: The resource for which the policy is being |
| 668 * specified. | 664 * specified. |
| 669 * `resource` is usually specified as a path. For example, a Project | 665 * See the operation documentation for the appropriate value for this field. |
| 670 * resource is specified as `projects/{project}`. | |
| 671 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". | 666 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". |
| 672 * | 667 * |
| 673 * Completes with a [Policy]. | 668 * Completes with a [Policy]. |
| 674 * | 669 * |
| 675 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 670 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 676 * error. | 671 * error. |
| 677 * | 672 * |
| 678 * If the used [http.Client] completes with an error when making a REST call, | 673 * If the used [http.Client] completes with an error when making a REST call, |
| 679 * this method will complete with the same error. | 674 * this method will complete with the same error. |
| 680 */ | 675 */ |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 713 * Note: This operation is designed to be used for building permission-aware | 708 * Note: This operation is designed to be used for building permission-aware |
| 714 * UIs and command-line tools, not for authorization checking. This operation | 709 * UIs and command-line tools, not for authorization checking. This operation |
| 715 * may "fail open" without warning. | 710 * may "fail open" without warning. |
| 716 * | 711 * |
| 717 * [request] - The metadata request object. | 712 * [request] - The metadata request object. |
| 718 * | 713 * |
| 719 * Request parameters: | 714 * Request parameters: |
| 720 * | 715 * |
| 721 * [resource] - REQUIRED: The resource for which the policy detail is being | 716 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 722 * requested. | 717 * requested. |
| 723 * `resource` is usually specified as a path. For example, a Project | 718 * See the operation documentation for the appropriate value for this field. |
| 724 * resource is specified as `projects/{project}`. | |
| 725 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". | 719 * Value must have pattern "^projects/[^/]+/subscriptions/[^/]+$". |
| 726 * | 720 * |
| 727 * Completes with a [TestIamPermissionsResponse]. | 721 * Completes with a [TestIamPermissionsResponse]. |
| 728 * | 722 * |
| 729 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 723 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 730 * error. | 724 * error. |
| 731 * | 725 * |
| 732 * If the used [http.Client] completes with an error when making a REST call, | 726 * If the used [http.Client] completes with an error when making a REST call, |
| 733 * this method will complete with the same error. | 727 * this method will complete with the same error. |
| 734 */ | 728 */ |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 908 | 902 |
| 909 /** | 903 /** |
| 910 * Gets the access control policy for a resource. | 904 * Gets the access control policy for a resource. |
| 911 * Returns an empty policy if the resource exists and does not have a policy | 905 * Returns an empty policy if the resource exists and does not have a policy |
| 912 * set. | 906 * set. |
| 913 * | 907 * |
| 914 * Request parameters: | 908 * Request parameters: |
| 915 * | 909 * |
| 916 * [resource] - REQUIRED: The resource for which the policy is being | 910 * [resource] - REQUIRED: The resource for which the policy is being |
| 917 * requested. | 911 * requested. |
| 918 * `resource` is usually specified as a path. For example, a Project | 912 * See the operation documentation for the appropriate value for this field. |
| 919 * resource is specified as `projects/{project}`. | |
| 920 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". | 913 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". |
| 921 * | 914 * |
| 922 * Completes with a [Policy]. | 915 * Completes with a [Policy]. |
| 923 * | 916 * |
| 924 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 917 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 925 * error. | 918 * error. |
| 926 * | 919 * |
| 927 * If the used [http.Client] completes with an error when making a REST call, | 920 * If the used [http.Client] completes with an error when making a REST call, |
| 928 * this method will complete with the same error. | 921 * this method will complete with the same error. |
| 929 */ | 922 */ |
| (...skipping 23 matching lines...) Expand all Loading... |
| 953 | 946 |
| 954 /** | 947 /** |
| 955 * Lists matching topics. | 948 * Lists matching topics. |
| 956 * | 949 * |
| 957 * Request parameters: | 950 * Request parameters: |
| 958 * | 951 * |
| 959 * [project] - The name of the cloud project that topics belong to. | 952 * [project] - The name of the cloud project that topics belong to. |
| 960 * Format is `projects/{project}`. | 953 * Format is `projects/{project}`. |
| 961 * Value must have pattern "^projects/[^/]+$". | 954 * Value must have pattern "^projects/[^/]+$". |
| 962 * | 955 * |
| 963 * [pageSize] - Maximum number of topics to return. | |
| 964 * | |
| 965 * [pageToken] - The value returned by the last `ListTopicsResponse`; | 956 * [pageToken] - The value returned by the last `ListTopicsResponse`; |
| 966 * indicates that this is | 957 * indicates that this is |
| 967 * a continuation of a prior `ListTopics` call, and that the system should | 958 * a continuation of a prior `ListTopics` call, and that the system should |
| 968 * return the next page of data. | 959 * return the next page of data. |
| 969 * | 960 * |
| 961 * [pageSize] - Maximum number of topics to return. |
| 962 * |
| 970 * Completes with a [ListTopicsResponse]. | 963 * Completes with a [ListTopicsResponse]. |
| 971 * | 964 * |
| 972 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 965 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 973 * error. | 966 * error. |
| 974 * | 967 * |
| 975 * If the used [http.Client] completes with an error when making a REST call, | 968 * If the used [http.Client] completes with an error when making a REST call, |
| 976 * this method will complete with the same error. | 969 * this method will complete with the same error. |
| 977 */ | 970 */ |
| 978 async.Future<ListTopicsResponse> list(core.String project, {core.int pageSize,
core.String pageToken}) { | 971 async.Future<ListTopicsResponse> list(core.String project, {core.String pageTo
ken, core.int pageSize}) { |
| 979 var _url = null; | 972 var _url = null; |
| 980 var _queryParams = new core.Map(); | 973 var _queryParams = new core.Map(); |
| 981 var _uploadMedia = null; | 974 var _uploadMedia = null; |
| 982 var _uploadOptions = null; | 975 var _uploadOptions = null; |
| 983 var _downloadOptions = commons.DownloadOptions.Metadata; | 976 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 984 var _body = null; | 977 var _body = null; |
| 985 | 978 |
| 986 if (project == null) { | 979 if (project == null) { |
| 987 throw new core.ArgumentError("Parameter project is required."); | 980 throw new core.ArgumentError("Parameter project is required."); |
| 988 } | 981 } |
| 982 if (pageToken != null) { |
| 983 _queryParams["pageToken"] = [pageToken]; |
| 984 } |
| 989 if (pageSize != null) { | 985 if (pageSize != null) { |
| 990 _queryParams["pageSize"] = ["${pageSize}"]; | 986 _queryParams["pageSize"] = ["${pageSize}"]; |
| 991 } | 987 } |
| 992 if (pageToken != null) { | |
| 993 _queryParams["pageToken"] = [pageToken]; | |
| 994 } | |
| 995 | 988 |
| 996 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$project') + '/topics'
; | 989 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$project') + '/topics'
; |
| 997 | 990 |
| 998 var _response = _requester.request(_url, | 991 var _response = _requester.request(_url, |
| 999 "GET", | 992 "GET", |
| 1000 body: _body, | 993 body: _body, |
| 1001 queryParams: _queryParams, | 994 queryParams: _queryParams, |
| 1002 uploadOptions: _uploadOptions, | 995 uploadOptions: _uploadOptions, |
| 1003 uploadMedia: _uploadMedia, | 996 uploadMedia: _uploadMedia, |
| 1004 downloadOptions: _downloadOptions); | 997 downloadOptions: _downloadOptions); |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1056 /** | 1049 /** |
| 1057 * Sets the access control policy on the specified resource. Replaces any | 1050 * Sets the access control policy on the specified resource. Replaces any |
| 1058 * existing policy. | 1051 * existing policy. |
| 1059 * | 1052 * |
| 1060 * [request] - The metadata request object. | 1053 * [request] - The metadata request object. |
| 1061 * | 1054 * |
| 1062 * Request parameters: | 1055 * Request parameters: |
| 1063 * | 1056 * |
| 1064 * [resource] - REQUIRED: The resource for which the policy is being | 1057 * [resource] - REQUIRED: The resource for which the policy is being |
| 1065 * specified. | 1058 * specified. |
| 1066 * `resource` is usually specified as a path. For example, a Project | 1059 * See the operation documentation for the appropriate value for this field. |
| 1067 * resource is specified as `projects/{project}`. | |
| 1068 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". | 1060 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". |
| 1069 * | 1061 * |
| 1070 * Completes with a [Policy]. | 1062 * Completes with a [Policy]. |
| 1071 * | 1063 * |
| 1072 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1064 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1073 * error. | 1065 * error. |
| 1074 * | 1066 * |
| 1075 * If the used [http.Client] completes with an error when making a REST call, | 1067 * If the used [http.Client] completes with an error when making a REST call, |
| 1076 * this method will complete with the same error. | 1068 * this method will complete with the same error. |
| 1077 */ | 1069 */ |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1110 * Note: This operation is designed to be used for building permission-aware | 1102 * Note: This operation is designed to be used for building permission-aware |
| 1111 * UIs and command-line tools, not for authorization checking. This operation | 1103 * UIs and command-line tools, not for authorization checking. This operation |
| 1112 * may "fail open" without warning. | 1104 * may "fail open" without warning. |
| 1113 * | 1105 * |
| 1114 * [request] - The metadata request object. | 1106 * [request] - The metadata request object. |
| 1115 * | 1107 * |
| 1116 * Request parameters: | 1108 * Request parameters: |
| 1117 * | 1109 * |
| 1118 * [resource] - REQUIRED: The resource for which the policy detail is being | 1110 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 1119 * requested. | 1111 * requested. |
| 1120 * `resource` is usually specified as a path. For example, a Project | 1112 * See the operation documentation for the appropriate value for this field. |
| 1121 * resource is specified as `projects/{project}`. | |
| 1122 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". | 1113 * Value must have pattern "^projects/[^/]+/topics/[^/]+$". |
| 1123 * | 1114 * |
| 1124 * Completes with a [TestIamPermissionsResponse]. | 1115 * Completes with a [TestIamPermissionsResponse]. |
| 1125 * | 1116 * |
| 1126 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1117 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1127 * error. | 1118 * error. |
| 1128 * | 1119 * |
| 1129 * If the used [http.Client] completes with an error when making a REST call, | 1120 * If the used [http.Client] completes with an error when making a REST call, |
| 1130 * this method will complete with the same error. | 1121 * this method will complete with the same error. |
| 1131 */ | 1122 */ |
| (...skipping 638 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1770 | 1761 |
| 1771 /** Configuration for a push delivery endpoint. */ | 1762 /** Configuration for a push delivery endpoint. */ |
| 1772 class PushConfig { | 1763 class PushConfig { |
| 1773 /** | 1764 /** |
| 1774 * Endpoint configuration attributes. | 1765 * Endpoint configuration attributes. |
| 1775 * | 1766 * |
| 1776 * Every endpoint has a set of API supported attributes that can be used to | 1767 * Every endpoint has a set of API supported attributes that can be used to |
| 1777 * control different aspects of the message delivery. | 1768 * control different aspects of the message delivery. |
| 1778 * | 1769 * |
| 1779 * The currently supported attribute is `x-goog-version`, which you can | 1770 * The currently supported attribute is `x-goog-version`, which you can |
| 1780 * use to change the format of the push message. This attribute | 1771 * use to change the format of the pushed message. This attribute |
| 1781 * indicates the version of the data expected by the endpoint. This | 1772 * indicates the version of the data expected by the endpoint. This |
| 1782 * controls the shape of the envelope (i.e. its fields and metadata). | 1773 * controls the shape of the pushed message (i.e., its fields and metadata). |
| 1783 * The endpoint version is based on the version of the Pub/Sub | 1774 * The endpoint version is based on the version of the Pub/Sub API. |
| 1784 * API. | |
| 1785 * | 1775 * |
| 1786 * If not present during the `CreateSubscription` call, it will default to | 1776 * If not present during the `CreateSubscription` call, it will default to |
| 1787 * the version of the API used to make such call. If not present during a | 1777 * the version of the API used to make such call. If not present during a |
| 1788 * `ModifyPushConfig` call, its value will not be changed. `GetSubscription` | 1778 * `ModifyPushConfig` call, its value will not be changed. `GetSubscription` |
| 1789 * calls will always return a valid version, even if the subscription was | 1779 * calls will always return a valid version, even if the subscription was |
| 1790 * created without this attribute. | 1780 * created without this attribute. |
| 1791 * | 1781 * |
| 1792 * The possible values for this attribute are: | 1782 * The possible values for this attribute are: |
| 1793 * | 1783 * |
| 1794 * * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API. | 1784 * * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API. |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2036 } | 2026 } |
| 2037 | 2027 |
| 2038 core.Map toJson() { | 2028 core.Map toJson() { |
| 2039 var _json = new core.Map(); | 2029 var _json = new core.Map(); |
| 2040 if (name != null) { | 2030 if (name != null) { |
| 2041 _json["name"] = name; | 2031 _json["name"] = name; |
| 2042 } | 2032 } |
| 2043 return _json; | 2033 return _json; |
| 2044 } | 2034 } |
| 2045 } | 2035 } |
| OLD | NEW |