| 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.cloudkms.v1; | 3 library googleapis.cloudkms.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 1108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1119 * Lists CryptoKeyVersions. | 1119 * Lists CryptoKeyVersions. |
| 1120 * | 1120 * |
| 1121 * Request parameters: | 1121 * Request parameters: |
| 1122 * | 1122 * |
| 1123 * [parent] - Required. The resource name of the CryptoKey to list, in the | 1123 * [parent] - Required. The resource name of the CryptoKey to list, in the |
| 1124 * format | 1124 * format |
| 1125 * `projects / * /locations / * /keyRings / * /cryptoKeys / * `. | 1125 * `projects / * /locations / * /keyRings / * /cryptoKeys / * `. |
| 1126 * Value must have pattern | 1126 * Value must have pattern |
| 1127 * "^projects/[^/]+/locations/[^/]+/keyRings/[^/]+/cryptoKeys/[^/]+$". | 1127 * "^projects/[^/]+/locations/[^/]+/keyRings/[^/]+/cryptoKeys/[^/]+$". |
| 1128 * | 1128 * |
| 1129 * [pageToken] - Optional pagination token, returned earlier via | |
| 1130 * ListCryptoKeyVersionsResponse.next_page_token. | |
| 1131 * | |
| 1132 * [pageSize] - Optional limit on the number of CryptoKeyVersions to | 1129 * [pageSize] - Optional limit on the number of CryptoKeyVersions to |
| 1133 * include in the response. Further CryptoKeyVersions can | 1130 * include in the response. Further CryptoKeyVersions can |
| 1134 * subsequently be obtained by including the | 1131 * subsequently be obtained by including the |
| 1135 * ListCryptoKeyVersionsResponse.next_page_token in a subsequent request. | 1132 * ListCryptoKeyVersionsResponse.next_page_token in a subsequent request. |
| 1136 * If unspecified, the server will pick an appropriate default. | 1133 * If unspecified, the server will pick an appropriate default. |
| 1137 * | 1134 * |
| 1135 * [pageToken] - Optional pagination token, returned earlier via |
| 1136 * ListCryptoKeyVersionsResponse.next_page_token. |
| 1137 * |
| 1138 * Completes with a [ListCryptoKeyVersionsResponse]. | 1138 * Completes with a [ListCryptoKeyVersionsResponse]. |
| 1139 * | 1139 * |
| 1140 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1140 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1141 * error. | 1141 * error. |
| 1142 * | 1142 * |
| 1143 * If the used [http.Client] completes with an error when making a REST call, | 1143 * If the used [http.Client] completes with an error when making a REST call, |
| 1144 * this method will complete with the same error. | 1144 * this method will complete with the same error. |
| 1145 */ | 1145 */ |
| 1146 async.Future<ListCryptoKeyVersionsResponse> list(core.String parent, {core.Str
ing pageToken, core.int pageSize}) { | 1146 async.Future<ListCryptoKeyVersionsResponse> list(core.String parent, {core.int
pageSize, core.String pageToken}) { |
| 1147 var _url = null; | 1147 var _url = null; |
| 1148 var _queryParams = new core.Map(); | 1148 var _queryParams = new core.Map(); |
| 1149 var _uploadMedia = null; | 1149 var _uploadMedia = null; |
| 1150 var _uploadOptions = null; | 1150 var _uploadOptions = null; |
| 1151 var _downloadOptions = commons.DownloadOptions.Metadata; | 1151 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1152 var _body = null; | 1152 var _body = null; |
| 1153 | 1153 |
| 1154 if (parent == null) { | 1154 if (parent == null) { |
| 1155 throw new core.ArgumentError("Parameter parent is required."); | 1155 throw new core.ArgumentError("Parameter parent is required."); |
| 1156 } | 1156 } |
| 1157 if (pageSize != null) { |
| 1158 _queryParams["pageSize"] = ["${pageSize}"]; |
| 1159 } |
| 1157 if (pageToken != null) { | 1160 if (pageToken != null) { |
| 1158 _queryParams["pageToken"] = [pageToken]; | 1161 _queryParams["pageToken"] = [pageToken]; |
| 1159 } | 1162 } |
| 1160 if (pageSize != null) { | |
| 1161 _queryParams["pageSize"] = ["${pageSize}"]; | |
| 1162 } | |
| 1163 | 1163 |
| 1164 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/cryptoKe
yVersions'; | 1164 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$parent') + '/cryptoKe
yVersions'; |
| 1165 | 1165 |
| 1166 var _response = _requester.request(_url, | 1166 var _response = _requester.request(_url, |
| 1167 "GET", | 1167 "GET", |
| 1168 body: _body, | 1168 body: _body, |
| 1169 queryParams: _queryParams, | 1169 queryParams: _queryParams, |
| 1170 uploadOptions: _uploadOptions, | 1170 uploadOptions: _uploadOptions, |
| 1171 uploadMedia: _uploadMedia, | 1171 uploadMedia: _uploadMedia, |
| 1172 downloadOptions: _downloadOptions); | 1172 downloadOptions: _downloadOptions); |
| (...skipping 1616 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2789 } | 2789 } |
| 2790 | 2790 |
| 2791 core.Map<core.String, core.Object> toJson() { | 2791 core.Map<core.String, core.Object> toJson() { |
| 2792 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 2792 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 2793 if (cryptoKeyVersionId != null) { | 2793 if (cryptoKeyVersionId != null) { |
| 2794 _json["cryptoKeyVersionId"] = cryptoKeyVersionId; | 2794 _json["cryptoKeyVersionId"] = cryptoKeyVersionId; |
| 2795 } | 2795 } |
| 2796 return _json; | 2796 return _json; |
| 2797 } | 2797 } |
| 2798 } | 2798 } |
| OLD | NEW |