| 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.clouderrorreporting.v1beta1; | 3 library googleapis_beta.clouderrorreporting.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 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 * Request parameters: | 103 * Request parameters: |
| 104 * | 104 * |
| 105 * [projectName] - [Required] The resource name of the Google Cloud Platform | 105 * [projectName] - [Required] The resource name of the Google Cloud Platform |
| 106 * project. Written | 106 * project. Written |
| 107 * as `projects/` plus the | 107 * as `projects/` plus the |
| 108 * [Google Cloud Platform project | 108 * [Google Cloud Platform project |
| 109 * ID](https://support.google.com/cloud/answer/6158840). | 109 * ID](https://support.google.com/cloud/answer/6158840). |
| 110 * Example: `projects/my-project-123`. | 110 * Example: `projects/my-project-123`. |
| 111 * Value must have pattern "^projects/[^/]+$". | 111 * Value must have pattern "^projects/[^/]+$". |
| 112 * | 112 * |
| 113 * [pageToken] - [Optional] A `next_page_token` provided by a previous |
| 114 * response. |
| 115 * |
| 116 * [serviceFilter_service] - [Optional] The exact value to match against |
| 117 * [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.service). |
| 118 * |
| 119 * [pageSize] - [Optional] The maximum number of results to return per |
| 120 * response. |
| 121 * |
| 122 * [serviceFilter_version] - [Optional] The exact value to match against |
| 123 * [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.version). |
| 124 * |
| 113 * [serviceFilter_resourceType] - [Optional] The exact value to match against | 125 * [serviceFilter_resourceType] - [Optional] The exact value to match against |
| 114 * [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/Se
rviceContext#FIELDS.resource_type). | 126 * [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/Se
rviceContext#FIELDS.resource_type). |
| 115 * | 127 * |
| 116 * [timeRange_period] - Restricts the query to the specified time range. | 128 * [timeRange_period] - Restricts the query to the specified time range. |
| 117 * Possible string values are: | 129 * Possible string values are: |
| 118 * - "PERIOD_UNSPECIFIED" : A PERIOD_UNSPECIFIED. | 130 * - "PERIOD_UNSPECIFIED" : A PERIOD_UNSPECIFIED. |
| 119 * - "PERIOD_1_HOUR" : A PERIOD_1_HOUR. | 131 * - "PERIOD_1_HOUR" : A PERIOD_1_HOUR. |
| 120 * - "PERIOD_6_HOURS" : A PERIOD_6_HOURS. | 132 * - "PERIOD_6_HOURS" : A PERIOD_6_HOURS. |
| 121 * - "PERIOD_1_DAY" : A PERIOD_1_DAY. | 133 * - "PERIOD_1_DAY" : A PERIOD_1_DAY. |
| 122 * - "PERIOD_1_WEEK" : A PERIOD_1_WEEK. | 134 * - "PERIOD_1_WEEK" : A PERIOD_1_WEEK. |
| 123 * - "PERIOD_30_DAYS" : A PERIOD_30_DAYS. | 135 * - "PERIOD_30_DAYS" : A PERIOD_30_DAYS. |
| 124 * | 136 * |
| 125 * [groupId] - [Required] The group for which events shall be returned. | 137 * [groupId] - [Required] The group for which events shall be returned. |
| 126 * | 138 * |
| 127 * [pageToken] - [Optional] A `next_page_token` provided by a previous | |
| 128 * response. | |
| 129 * | |
| 130 * [serviceFilter_service] - [Optional] The exact value to match against | |
| 131 * [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.service). | |
| 132 * | |
| 133 * [pageSize] - [Optional] The maximum number of results to return per | |
| 134 * response. | |
| 135 * | |
| 136 * [serviceFilter_version] - [Optional] The exact value to match against | |
| 137 * [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.version). | |
| 138 * | |
| 139 * Completes with a [ListEventsResponse]. | 139 * Completes with a [ListEventsResponse]. |
| 140 * | 140 * |
| 141 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 141 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 142 * error. | 142 * error. |
| 143 * | 143 * |
| 144 * If the used [http.Client] completes with an error when making a REST call, | 144 * If the used [http.Client] completes with an error when making a REST call, |
| 145 * this method will complete with the same error. | 145 * this method will complete with the same error. |
| 146 */ | 146 */ |
| 147 async.Future<ListEventsResponse> list(core.String projectName, {core.String se
rviceFilter_resourceType, core.String timeRange_period, core.String groupId, cor
e.String pageToken, core.String serviceFilter_service, core.int pageSize, core.S
tring serviceFilter_version}) { | 147 async.Future<ListEventsResponse> list(core.String projectName, {core.String pa
geToken, core.String serviceFilter_service, core.int pageSize, core.String servi
ceFilter_version, core.String serviceFilter_resourceType, core.String timeRange_
period, core.String groupId}) { |
| 148 var _url = null; | 148 var _url = null; |
| 149 var _queryParams = new core.Map(); | 149 var _queryParams = new core.Map(); |
| 150 var _uploadMedia = null; | 150 var _uploadMedia = null; |
| 151 var _uploadOptions = null; | 151 var _uploadOptions = null; |
| 152 var _downloadOptions = commons.DownloadOptions.Metadata; | 152 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 153 var _body = null; | 153 var _body = null; |
| 154 | 154 |
| 155 if (projectName == null) { | 155 if (projectName == null) { |
| 156 throw new core.ArgumentError("Parameter projectName is required."); | 156 throw new core.ArgumentError("Parameter projectName is required."); |
| 157 } | 157 } |
| 158 if (serviceFilter_resourceType != null) { | |
| 159 _queryParams["serviceFilter.resourceType"] = [serviceFilter_resourceType]; | |
| 160 } | |
| 161 if (timeRange_period != null) { | |
| 162 _queryParams["timeRange.period"] = [timeRange_period]; | |
| 163 } | |
| 164 if (groupId != null) { | |
| 165 _queryParams["groupId"] = [groupId]; | |
| 166 } | |
| 167 if (pageToken != null) { | 158 if (pageToken != null) { |
| 168 _queryParams["pageToken"] = [pageToken]; | 159 _queryParams["pageToken"] = [pageToken]; |
| 169 } | 160 } |
| 170 if (serviceFilter_service != null) { | 161 if (serviceFilter_service != null) { |
| 171 _queryParams["serviceFilter.service"] = [serviceFilter_service]; | 162 _queryParams["serviceFilter.service"] = [serviceFilter_service]; |
| 172 } | 163 } |
| 173 if (pageSize != null) { | 164 if (pageSize != null) { |
| 174 _queryParams["pageSize"] = ["${pageSize}"]; | 165 _queryParams["pageSize"] = ["${pageSize}"]; |
| 175 } | 166 } |
| 176 if (serviceFilter_version != null) { | 167 if (serviceFilter_version != null) { |
| 177 _queryParams["serviceFilter.version"] = [serviceFilter_version]; | 168 _queryParams["serviceFilter.version"] = [serviceFilter_version]; |
| 178 } | 169 } |
| 170 if (serviceFilter_resourceType != null) { |
| 171 _queryParams["serviceFilter.resourceType"] = [serviceFilter_resourceType]; |
| 172 } |
| 173 if (timeRange_period != null) { |
| 174 _queryParams["timeRange.period"] = [timeRange_period]; |
| 175 } |
| 176 if (groupId != null) { |
| 177 _queryParams["groupId"] = [groupId]; |
| 178 } |
| 179 | 179 |
| 180 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$projectName') +
'/events'; | 180 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$projectName') +
'/events'; |
| 181 | 181 |
| 182 var _response = _requester.request(_url, | 182 var _response = _requester.request(_url, |
| 183 "GET", | 183 "GET", |
| 184 body: _body, | 184 body: _body, |
| 185 queryParams: _queryParams, | 185 queryParams: _queryParams, |
| 186 uploadOptions: _uploadOptions, | 186 uploadOptions: _uploadOptions, |
| 187 uploadMedia: _uploadMedia, | 187 uploadMedia: _uploadMedia, |
| 188 downloadOptions: _downloadOptions); | 188 downloadOptions: _downloadOptions); |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 263 * | 263 * |
| 264 * [projectName] - [Required] The resource name of the Google Cloud Platform | 264 * [projectName] - [Required] The resource name of the Google Cloud Platform |
| 265 * project. Written | 265 * project. Written |
| 266 * as <code>projects/</code> plus the | 266 * as <code>projects/</code> plus the |
| 267 * <a href="https://support.google.com/cloud/answer/6158840">Google Cloud | 267 * <a href="https://support.google.com/cloud/answer/6158840">Google Cloud |
| 268 * Platform project ID</a>. | 268 * Platform project ID</a>. |
| 269 * | 269 * |
| 270 * Example: <code>projects/my-project-123</code>. | 270 * Example: <code>projects/my-project-123</code>. |
| 271 * Value must have pattern "^projects/[^/]+$". | 271 * Value must have pattern "^projects/[^/]+$". |
| 272 * | 272 * |
| 273 * [serviceFilter_service] - [Optional] The exact value to match against |
| 274 * [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.service). |
| 275 * |
| 276 * [pageSize] - [Optional] The maximum number of results to return per |
| 277 * response. |
| 278 * Default is 20. |
| 279 * |
| 280 * [order] - [Optional] The sort order in which the results are returned. |
| 281 * Default is `COUNT_DESC`. |
| 282 * Possible string values are: |
| 283 * - "GROUP_ORDER_UNSPECIFIED" : A GROUP_ORDER_UNSPECIFIED. |
| 284 * - "COUNT_DESC" : A COUNT_DESC. |
| 285 * - "LAST_SEEN_DESC" : A LAST_SEEN_DESC. |
| 286 * - "CREATED_DESC" : A CREATED_DESC. |
| 287 * - "AFFECTED_USERS_DESC" : A AFFECTED_USERS_DESC. |
| 288 * |
| 289 * [serviceFilter_version] - [Optional] The exact value to match against |
| 290 * [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.version). |
| 291 * |
| 292 * [alignmentTime] - [Optional] Time where the timed counts shall be aligned |
| 293 * if rounded |
| 294 * alignment is chosen. Default is 00:00 UTC. |
| 295 * |
| 296 * [serviceFilter_resourceType] - [Optional] The exact value to match against |
| 297 * [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/Se
rviceContext#FIELDS.resource_type). |
| 298 * |
| 273 * [timedCountDuration] - [Optional] The preferred duration for a single | 299 * [timedCountDuration] - [Optional] The preferred duration for a single |
| 274 * returned `TimedCount`. | 300 * returned `TimedCount`. |
| 275 * If not set, no timed counts are returned. | 301 * If not set, no timed counts are returned. |
| 276 * | 302 * |
| 277 * [pageToken] - [Optional] A `next_page_token` provided by a previous | 303 * [pageToken] - [Optional] A `next_page_token` provided by a previous |
| 278 * response. To view | 304 * response. To view |
| 279 * additional results, pass this token along with the identical query | 305 * additional results, pass this token along with the identical query |
| 280 * parameters as the first request. | 306 * parameters as the first request. |
| 281 * | 307 * |
| 282 * [timeRange_period] - Restricts the query to the specified time range. | 308 * [timeRange_period] - Restricts the query to the specified time range. |
| 283 * Possible string values are: | 309 * Possible string values are: |
| 284 * - "PERIOD_UNSPECIFIED" : A PERIOD_UNSPECIFIED. | 310 * - "PERIOD_UNSPECIFIED" : A PERIOD_UNSPECIFIED. |
| 285 * - "PERIOD_1_HOUR" : A PERIOD_1_HOUR. | 311 * - "PERIOD_1_HOUR" : A PERIOD_1_HOUR. |
| 286 * - "PERIOD_6_HOURS" : A PERIOD_6_HOURS. | 312 * - "PERIOD_6_HOURS" : A PERIOD_6_HOURS. |
| 287 * - "PERIOD_1_DAY" : A PERIOD_1_DAY. | 313 * - "PERIOD_1_DAY" : A PERIOD_1_DAY. |
| 288 * - "PERIOD_1_WEEK" : A PERIOD_1_WEEK. | 314 * - "PERIOD_1_WEEK" : A PERIOD_1_WEEK. |
| 289 * - "PERIOD_30_DAYS" : A PERIOD_30_DAYS. | 315 * - "PERIOD_30_DAYS" : A PERIOD_30_DAYS. |
| 290 * | 316 * |
| 291 * [alignment] - [Optional] The alignment of the timed counts to be returned. | 317 * [alignment] - [Optional] The alignment of the timed counts to be returned. |
| 292 * Default is `ALIGNMENT_EQUAL_AT_END`. | 318 * Default is `ALIGNMENT_EQUAL_AT_END`. |
| 293 * Possible string values are: | 319 * Possible string values are: |
| 294 * - "ERROR_COUNT_ALIGNMENT_UNSPECIFIED" : A | 320 * - "ERROR_COUNT_ALIGNMENT_UNSPECIFIED" : A |
| 295 * ERROR_COUNT_ALIGNMENT_UNSPECIFIED. | 321 * ERROR_COUNT_ALIGNMENT_UNSPECIFIED. |
| 296 * - "ALIGNMENT_EQUAL_ROUNDED" : A ALIGNMENT_EQUAL_ROUNDED. | 322 * - "ALIGNMENT_EQUAL_ROUNDED" : A ALIGNMENT_EQUAL_ROUNDED. |
| 297 * - "ALIGNMENT_EQUAL_AT_END" : A ALIGNMENT_EQUAL_AT_END. | 323 * - "ALIGNMENT_EQUAL_AT_END" : A ALIGNMENT_EQUAL_AT_END. |
| 298 * | 324 * |
| 299 * [groupId] - [Optional] List all <code>ErrorGroupStats</code> with these | 325 * [groupId] - [Optional] List all <code>ErrorGroupStats</code> with these |
| 300 * IDs. | 326 * IDs. |
| 301 * | 327 * |
| 302 * [serviceFilter_service] - [Optional] The exact value to match against | |
| 303 * [`ServiceContext.service`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.service). | |
| 304 * | |
| 305 * [pageSize] - [Optional] The maximum number of results to return per | |
| 306 * response. | |
| 307 * Default is 20. | |
| 308 * | |
| 309 * [order] - [Optional] The sort order in which the results are returned. | |
| 310 * Default is `COUNT_DESC`. | |
| 311 * Possible string values are: | |
| 312 * - "GROUP_ORDER_UNSPECIFIED" : A GROUP_ORDER_UNSPECIFIED. | |
| 313 * - "COUNT_DESC" : A COUNT_DESC. | |
| 314 * - "LAST_SEEN_DESC" : A LAST_SEEN_DESC. | |
| 315 * - "CREATED_DESC" : A CREATED_DESC. | |
| 316 * - "AFFECTED_USERS_DESC" : A AFFECTED_USERS_DESC. | |
| 317 * | |
| 318 * [serviceFilter_version] - [Optional] The exact value to match against | |
| 319 * [`ServiceContext.version`](/error-reporting/reference/rest/v1beta1/ServiceC
ontext#FIELDS.version). | |
| 320 * | |
| 321 * [serviceFilter_resourceType] - [Optional] The exact value to match against | |
| 322 * [`ServiceContext.resource_type`](/error-reporting/reference/rest/v1beta1/Se
rviceContext#FIELDS.resource_type). | |
| 323 * | |
| 324 * [alignmentTime] - [Optional] Time where the timed counts shall be aligned | |
| 325 * if rounded | |
| 326 * alignment is chosen. Default is 00:00 UTC. | |
| 327 * | |
| 328 * Completes with a [ListGroupStatsResponse]. | 328 * Completes with a [ListGroupStatsResponse]. |
| 329 * | 329 * |
| 330 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 330 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 331 * error. | 331 * error. |
| 332 * | 332 * |
| 333 * If the used [http.Client] completes with an error when making a REST call, | 333 * If the used [http.Client] completes with an error when making a REST call, |
| 334 * this method will complete with the same error. | 334 * this method will complete with the same error. |
| 335 */ | 335 */ |
| 336 async.Future<ListGroupStatsResponse> list(core.String projectName, {core.Strin
g timedCountDuration, core.String pageToken, core.String timeRange_period, core.
String alignment, core.List<core.String> groupId, core.String serviceFilter_serv
ice, core.int pageSize, core.String order, core.String serviceFilter_version, co
re.String serviceFilter_resourceType, core.String alignmentTime}) { | 336 async.Future<ListGroupStatsResponse> list(core.String projectName, {core.Strin
g serviceFilter_service, core.int pageSize, core.String order, core.String servi
ceFilter_version, core.String alignmentTime, core.String serviceFilter_resourceT
ype, core.String timedCountDuration, core.String pageToken, core.String timeRang
e_period, core.String alignment, core.List<core.String> groupId}) { |
| 337 var _url = null; | 337 var _url = null; |
| 338 var _queryParams = new core.Map(); | 338 var _queryParams = new core.Map(); |
| 339 var _uploadMedia = null; | 339 var _uploadMedia = null; |
| 340 var _uploadOptions = null; | 340 var _uploadOptions = null; |
| 341 var _downloadOptions = commons.DownloadOptions.Metadata; | 341 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 342 var _body = null; | 342 var _body = null; |
| 343 | 343 |
| 344 if (projectName == null) { | 344 if (projectName == null) { |
| 345 throw new core.ArgumentError("Parameter projectName is required."); | 345 throw new core.ArgumentError("Parameter projectName is required."); |
| 346 } | 346 } |
| 347 if (timedCountDuration != null) { | |
| 348 _queryParams["timedCountDuration"] = [timedCountDuration]; | |
| 349 } | |
| 350 if (pageToken != null) { | |
| 351 _queryParams["pageToken"] = [pageToken]; | |
| 352 } | |
| 353 if (timeRange_period != null) { | |
| 354 _queryParams["timeRange.period"] = [timeRange_period]; | |
| 355 } | |
| 356 if (alignment != null) { | |
| 357 _queryParams["alignment"] = [alignment]; | |
| 358 } | |
| 359 if (groupId != null) { | |
| 360 _queryParams["groupId"] = groupId; | |
| 361 } | |
| 362 if (serviceFilter_service != null) { | 347 if (serviceFilter_service != null) { |
| 363 _queryParams["serviceFilter.service"] = [serviceFilter_service]; | 348 _queryParams["serviceFilter.service"] = [serviceFilter_service]; |
| 364 } | 349 } |
| 365 if (pageSize != null) { | 350 if (pageSize != null) { |
| 366 _queryParams["pageSize"] = ["${pageSize}"]; | 351 _queryParams["pageSize"] = ["${pageSize}"]; |
| 367 } | 352 } |
| 368 if (order != null) { | 353 if (order != null) { |
| 369 _queryParams["order"] = [order]; | 354 _queryParams["order"] = [order]; |
| 370 } | 355 } |
| 371 if (serviceFilter_version != null) { | 356 if (serviceFilter_version != null) { |
| 372 _queryParams["serviceFilter.version"] = [serviceFilter_version]; | 357 _queryParams["serviceFilter.version"] = [serviceFilter_version]; |
| 373 } | 358 } |
| 359 if (alignmentTime != null) { |
| 360 _queryParams["alignmentTime"] = [alignmentTime]; |
| 361 } |
| 374 if (serviceFilter_resourceType != null) { | 362 if (serviceFilter_resourceType != null) { |
| 375 _queryParams["serviceFilter.resourceType"] = [serviceFilter_resourceType]; | 363 _queryParams["serviceFilter.resourceType"] = [serviceFilter_resourceType]; |
| 376 } | 364 } |
| 377 if (alignmentTime != null) { | 365 if (timedCountDuration != null) { |
| 378 _queryParams["alignmentTime"] = [alignmentTime]; | 366 _queryParams["timedCountDuration"] = [timedCountDuration]; |
| 367 } |
| 368 if (pageToken != null) { |
| 369 _queryParams["pageToken"] = [pageToken]; |
| 370 } |
| 371 if (timeRange_period != null) { |
| 372 _queryParams["timeRange.period"] = [timeRange_period]; |
| 373 } |
| 374 if (alignment != null) { |
| 375 _queryParams["alignment"] = [alignment]; |
| 376 } |
| 377 if (groupId != null) { |
| 378 _queryParams["groupId"] = groupId; |
| 379 } | 379 } |
| 380 | 380 |
| 381 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$projectName') +
'/groupStats'; | 381 _url = 'v1beta1/' + commons.Escaper.ecapeVariableReserved('$projectName') +
'/groupStats'; |
| 382 | 382 |
| 383 var _response = _requester.request(_url, | 383 var _response = _requester.request(_url, |
| 384 "GET", | 384 "GET", |
| 385 body: _body, | 385 body: _body, |
| 386 queryParams: _queryParams, | 386 queryParams: _queryParams, |
| 387 uploadOptions: _uploadOptions, | 387 uploadOptions: _uploadOptions, |
| 388 uploadMedia: _uploadMedia, | 388 uploadMedia: _uploadMedia, |
| (...skipping 885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1274 } | 1274 } |
| 1275 | 1275 |
| 1276 core.Map<core.String, core.Object> toJson() { | 1276 core.Map<core.String, core.Object> toJson() { |
| 1277 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 1277 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1278 if (url != null) { | 1278 if (url != null) { |
| 1279 _json["url"] = url; | 1279 _json["url"] = url; |
| 1280 } | 1280 } |
| 1281 return _json; | 1281 return _json; |
| 1282 } | 1282 } |
| 1283 } | 1283 } |
| OLD | NEW |