| 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.script.v1; | 3 library googleapis.script.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 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 errorMessage = _json["errorMessage"]; | 156 errorMessage = _json["errorMessage"]; |
| 157 } | 157 } |
| 158 if (_json.containsKey("errorType")) { | 158 if (_json.containsKey("errorType")) { |
| 159 errorType = _json["errorType"]; | 159 errorType = _json["errorType"]; |
| 160 } | 160 } |
| 161 if (_json.containsKey("scriptStackTraceElements")) { | 161 if (_json.containsKey("scriptStackTraceElements")) { |
| 162 scriptStackTraceElements = _json["scriptStackTraceElements"].map((value) =
> new ScriptStackTraceElement.fromJson(value)).toList(); | 162 scriptStackTraceElements = _json["scriptStackTraceElements"].map((value) =
> new ScriptStackTraceElement.fromJson(value)).toList(); |
| 163 } | 163 } |
| 164 } | 164 } |
| 165 | 165 |
| 166 core.Map toJson() { | 166 core.Map<core.String, core.Object> toJson() { |
| 167 var _json = new core.Map(); | 167 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 168 if (errorMessage != null) { | 168 if (errorMessage != null) { |
| 169 _json["errorMessage"] = errorMessage; | 169 _json["errorMessage"] = errorMessage; |
| 170 } | 170 } |
| 171 if (errorType != null) { | 171 if (errorType != null) { |
| 172 _json["errorType"] = errorType; | 172 _json["errorType"] = errorType; |
| 173 } | 173 } |
| 174 if (scriptStackTraceElements != null) { | 174 if (scriptStackTraceElements != null) { |
| 175 _json["scriptStackTraceElements"] = scriptStackTraceElements.map((value) =
> (value).toJson()).toList(); | 175 _json["scriptStackTraceElements"] = scriptStackTraceElements.map((value) =
> (value).toJson()).toList(); |
| 176 } | 176 } |
| 177 return _json; | 177 return _json; |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 231 function = _json["function"]; | 231 function = _json["function"]; |
| 232 } | 232 } |
| 233 if (_json.containsKey("parameters")) { | 233 if (_json.containsKey("parameters")) { |
| 234 parameters = _json["parameters"]; | 234 parameters = _json["parameters"]; |
| 235 } | 235 } |
| 236 if (_json.containsKey("sessionState")) { | 236 if (_json.containsKey("sessionState")) { |
| 237 sessionState = _json["sessionState"]; | 237 sessionState = _json["sessionState"]; |
| 238 } | 238 } |
| 239 } | 239 } |
| 240 | 240 |
| 241 core.Map toJson() { | 241 core.Map<core.String, core.Object> toJson() { |
| 242 var _json = new core.Map(); | 242 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 243 if (devMode != null) { | 243 if (devMode != null) { |
| 244 _json["devMode"] = devMode; | 244 _json["devMode"] = devMode; |
| 245 } | 245 } |
| 246 if (function != null) { | 246 if (function != null) { |
| 247 _json["function"] = function; | 247 _json["function"] = function; |
| 248 } | 248 } |
| 249 if (parameters != null) { | 249 if (parameters != null) { |
| 250 _json["parameters"] = parameters; | 250 _json["parameters"] = parameters; |
| 251 } | 251 } |
| 252 if (sessionState != null) { | 252 if (sessionState != null) { |
| (...skipping 25 matching lines...) Expand all Loading... |
| 278 core.Object result; | 278 core.Object result; |
| 279 | 279 |
| 280 ExecutionResponse(); | 280 ExecutionResponse(); |
| 281 | 281 |
| 282 ExecutionResponse.fromJson(core.Map _json) { | 282 ExecutionResponse.fromJson(core.Map _json) { |
| 283 if (_json.containsKey("result")) { | 283 if (_json.containsKey("result")) { |
| 284 result = _json["result"]; | 284 result = _json["result"]; |
| 285 } | 285 } |
| 286 } | 286 } |
| 287 | 287 |
| 288 core.Map toJson() { | 288 core.Map<core.String, core.Object> toJson() { |
| 289 var _json = new core.Map(); | 289 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 290 if (result != null) { | 290 if (result != null) { |
| 291 _json["result"] = result; | 291 _json["result"] = result; |
| 292 } | 292 } |
| 293 return _json; | 293 return _json; |
| 294 } | 294 } |
| 295 } | 295 } |
| 296 | 296 |
| 297 /** | 297 /** |
| 298 * A request to retrieve the results from a collection of requests, | 298 * A request to retrieve the results from a collection of requests, |
| 299 * specified by the operation resource names. | 299 * specified by the operation resource names. |
| (...skipping 19 matching lines...) Expand all Loading... |
| 319 names = _json["names"]; | 319 names = _json["names"]; |
| 320 } | 320 } |
| 321 if (_json.containsKey("scriptId")) { | 321 if (_json.containsKey("scriptId")) { |
| 322 scriptId = _json["scriptId"]; | 322 scriptId = _json["scriptId"]; |
| 323 } | 323 } |
| 324 if (_json.containsKey("timeout")) { | 324 if (_json.containsKey("timeout")) { |
| 325 timeout = _json["timeout"]; | 325 timeout = _json["timeout"]; |
| 326 } | 326 } |
| 327 } | 327 } |
| 328 | 328 |
| 329 core.Map toJson() { | 329 core.Map<core.String, core.Object> toJson() { |
| 330 var _json = new core.Map(); | 330 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 331 if (names != null) { | 331 if (names != null) { |
| 332 _json["names"] = names; | 332 _json["names"] = names; |
| 333 } | 333 } |
| 334 if (scriptId != null) { | 334 if (scriptId != null) { |
| 335 _json["scriptId"] = scriptId; | 335 _json["scriptId"] = scriptId; |
| 336 } | 336 } |
| 337 if (timeout != null) { | 337 if (timeout != null) { |
| 338 _json["timeout"] = timeout; | 338 _json["timeout"] = timeout; |
| 339 } | 339 } |
| 340 return _json; | 340 return _json; |
| 341 } | 341 } |
| 342 } | 342 } |
| 343 | 343 |
| 344 /** An object that provides the return value for the JoinAsync method. */ | 344 /** An object that provides the return value for the JoinAsync method. */ |
| 345 class JoinAsyncResponse { | 345 class JoinAsyncResponse { |
| 346 /** | 346 /** |
| 347 * The return values for each script function, in a map of operation resource | 347 * The return values for each script function, in a map of operation resource |
| 348 * names to the Operation containing the result of the process. The response | 348 * names to the Operation containing the result of the process. The response |
| 349 * will contain either an error or the result of the script function. | 349 * will contain either an error or the result of the script function. |
| 350 */ | 350 */ |
| 351 core.Map<core.String, Operation> results; | 351 core.Map<core.String, Operation> results; |
| 352 | 352 |
| 353 JoinAsyncResponse(); | 353 JoinAsyncResponse(); |
| 354 | 354 |
| 355 JoinAsyncResponse.fromJson(core.Map _json) { | 355 JoinAsyncResponse.fromJson(core.Map _json) { |
| 356 if (_json.containsKey("results")) { | 356 if (_json.containsKey("results")) { |
| 357 results = commons.mapMap(_json["results"], (item) => new Operation.fromJso
n(item)); | 357 results = commons.mapMap<core.Map<core.String, core.Object>, Operation>(_j
son["results"], (core.Map<core.String, core.Object> item) => new Operation.fromJ
son(item)); |
| 358 } | 358 } |
| 359 } | 359 } |
| 360 | 360 |
| 361 core.Map toJson() { | 361 core.Map<core.String, core.Object> toJson() { |
| 362 var _json = new core.Map(); | 362 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 363 if (results != null) { | 363 if (results != null) { |
| 364 _json["results"] = commons.mapMap(results, (item) => (item).toJson()); | 364 _json["results"] = commons.mapMap<Operation, core.Map<core.String, core.Ob
ject>>(results, (Operation item) => (item).toJson()); |
| 365 } | 365 } |
| 366 return _json; | 366 return _json; |
| 367 } | 367 } |
| 368 } | 368 } |
| 369 | 369 |
| 370 /** | 370 /** |
| 371 * The response will not arrive until the function finishes executing. The | 371 * The response will not arrive until the function finishes executing. The |
| 372 * maximum runtime is listed in the guide to [limitations in Apps | 372 * maximum runtime is listed in the guide to [limitations in Apps |
| 373 * Script](https://developers.google.com/apps-script/guides/services/quotas#curr
ent_limitations). | 373 * Script](https://developers.google.com/apps-script/guides/services/quotas#curr
ent_limitations). |
| 374 * <p>If the script function returns successfully, the `response` field will | 374 * <p>If the script function returns successfully, the `response` field will |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 427 metadata = _json["metadata"]; | 427 metadata = _json["metadata"]; |
| 428 } | 428 } |
| 429 if (_json.containsKey("name")) { | 429 if (_json.containsKey("name")) { |
| 430 name = _json["name"]; | 430 name = _json["name"]; |
| 431 } | 431 } |
| 432 if (_json.containsKey("response")) { | 432 if (_json.containsKey("response")) { |
| 433 response = _json["response"]; | 433 response = _json["response"]; |
| 434 } | 434 } |
| 435 } | 435 } |
| 436 | 436 |
| 437 core.Map toJson() { | 437 core.Map<core.String, core.Object> toJson() { |
| 438 var _json = new core.Map(); | 438 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 439 if (done != null) { | 439 if (done != null) { |
| 440 _json["done"] = done; | 440 _json["done"] = done; |
| 441 } | 441 } |
| 442 if (error != null) { | 442 if (error != null) { |
| 443 _json["error"] = (error).toJson(); | 443 _json["error"] = (error).toJson(); |
| 444 } | 444 } |
| 445 if (metadata != null) { | 445 if (metadata != null) { |
| 446 _json["metadata"] = metadata; | 446 _json["metadata"] = metadata; |
| 447 } | 447 } |
| 448 if (name != null) { | 448 if (name != null) { |
| (...skipping 17 matching lines...) Expand all Loading... |
| 466 | 466 |
| 467 ScriptStackTraceElement.fromJson(core.Map _json) { | 467 ScriptStackTraceElement.fromJson(core.Map _json) { |
| 468 if (_json.containsKey("function")) { | 468 if (_json.containsKey("function")) { |
| 469 function = _json["function"]; | 469 function = _json["function"]; |
| 470 } | 470 } |
| 471 if (_json.containsKey("lineNumber")) { | 471 if (_json.containsKey("lineNumber")) { |
| 472 lineNumber = _json["lineNumber"]; | 472 lineNumber = _json["lineNumber"]; |
| 473 } | 473 } |
| 474 } | 474 } |
| 475 | 475 |
| 476 core.Map toJson() { | 476 core.Map<core.String, core.Object> toJson() { |
| 477 var _json = new core.Map(); | 477 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 478 if (function != null) { | 478 if (function != null) { |
| 479 _json["function"] = function; | 479 _json["function"] = function; |
| 480 } | 480 } |
| 481 if (lineNumber != null) { | 481 if (lineNumber != null) { |
| 482 _json["lineNumber"] = lineNumber; | 482 _json["lineNumber"] = lineNumber; |
| 483 } | 483 } |
| 484 return _json; | 484 return _json; |
| 485 } | 485 } |
| 486 } | 486 } |
| 487 | 487 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 code = _json["code"]; | 519 code = _json["code"]; |
| 520 } | 520 } |
| 521 if (_json.containsKey("details")) { | 521 if (_json.containsKey("details")) { |
| 522 details = _json["details"]; | 522 details = _json["details"]; |
| 523 } | 523 } |
| 524 if (_json.containsKey("message")) { | 524 if (_json.containsKey("message")) { |
| 525 message = _json["message"]; | 525 message = _json["message"]; |
| 526 } | 526 } |
| 527 } | 527 } |
| 528 | 528 |
| 529 core.Map toJson() { | 529 core.Map<core.String, core.Object> toJson() { |
| 530 var _json = new core.Map(); | 530 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 531 if (code != null) { | 531 if (code != null) { |
| 532 _json["code"] = code; | 532 _json["code"] = code; |
| 533 } | 533 } |
| 534 if (details != null) { | 534 if (details != null) { |
| 535 _json["details"] = details; | 535 _json["details"] = details; |
| 536 } | 536 } |
| 537 if (message != null) { | 537 if (message != null) { |
| 538 _json["message"] = message; | 538 _json["message"] = message; |
| 539 } | 539 } |
| 540 return _json; | 540 return _json; |
| 541 } | 541 } |
| 542 } | 542 } |
| OLD | NEW |