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.datastore.v1; | 3 library googleapis.datastore.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 20 matching lines...) Expand all Loading... |
31 ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); | 31 ProjectsResourceApi get projects => new ProjectsResourceApi(_requester); |
32 | 32 |
33 DatastoreApi(http.Client client, {core.String rootUrl: "https://datastore.goog
leapis.com/", core.String servicePath: ""}) : | 33 DatastoreApi(http.Client client, {core.String rootUrl: "https://datastore.goog
leapis.com/", core.String servicePath: ""}) : |
34 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); | 34 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); |
35 } | 35 } |
36 | 36 |
37 | 37 |
38 class ProjectsResourceApi { | 38 class ProjectsResourceApi { |
39 final commons.ApiRequester _requester; | 39 final commons.ApiRequester _requester; |
40 | 40 |
| 41 ProjectsOperationsResourceApi get operations => new ProjectsOperationsResource
Api(_requester); |
| 42 |
41 ProjectsResourceApi(commons.ApiRequester client) : | 43 ProjectsResourceApi(commons.ApiRequester client) : |
42 _requester = client; | 44 _requester = client; |
43 | 45 |
44 /** | 46 /** |
45 * Allocates IDs for the given keys, which is useful for referencing an entity | 47 * Allocates IDs for the given keys, which is useful for referencing an entity |
46 * before it is inserted. | 48 * before it is inserted. |
47 * | 49 * |
48 * [request] - The metadata request object. | 50 * [request] - The metadata request object. |
49 * | 51 * |
50 * Request parameters: | 52 * Request parameters: |
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
303 queryParams: _queryParams, | 305 queryParams: _queryParams, |
304 uploadOptions: _uploadOptions, | 306 uploadOptions: _uploadOptions, |
305 uploadMedia: _uploadMedia, | 307 uploadMedia: _uploadMedia, |
306 downloadOptions: _downloadOptions); | 308 downloadOptions: _downloadOptions); |
307 return _response.then((data) => new RunQueryResponse.fromJson(data)); | 309 return _response.then((data) => new RunQueryResponse.fromJson(data)); |
308 } | 310 } |
309 | 311 |
310 } | 312 } |
311 | 313 |
312 | 314 |
| 315 class ProjectsOperationsResourceApi { |
| 316 final commons.ApiRequester _requester; |
| 317 |
| 318 ProjectsOperationsResourceApi(commons.ApiRequester client) : |
| 319 _requester = client; |
| 320 |
| 321 /** |
| 322 * Starts asynchronous cancellation on a long-running operation. The server |
| 323 * makes a best effort to cancel the operation, but success is not |
| 324 * guaranteed. If the server doesn't support this method, it returns |
| 325 * `google.rpc.Code.UNIMPLEMENTED`. Clients can use |
| 326 * Operations.GetOperation or |
| 327 * other methods to check whether the cancellation succeeded or whether the |
| 328 * operation completed despite cancellation. On successful cancellation, |
| 329 * the operation is not deleted; instead, it becomes an operation with |
| 330 * an Operation.error value with a google.rpc.Status.code of 1, |
| 331 * corresponding to `Code.CANCELLED`. |
| 332 * |
| 333 * Request parameters: |
| 334 * |
| 335 * [name] - The name of the operation resource to be cancelled. |
| 336 * Value must have pattern "^projects/[^/]+/operations/[^/]+$". |
| 337 * |
| 338 * Completes with a [Empty]. |
| 339 * |
| 340 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 341 * error. |
| 342 * |
| 343 * If the used [http.Client] completes with an error when making a REST call, |
| 344 * this method will complete with the same error. |
| 345 */ |
| 346 async.Future<Empty> cancel(core.String name) { |
| 347 var _url = null; |
| 348 var _queryParams = new core.Map(); |
| 349 var _uploadMedia = null; |
| 350 var _uploadOptions = null; |
| 351 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 352 var _body = null; |
| 353 |
| 354 if (name == null) { |
| 355 throw new core.ArgumentError("Parameter name is required."); |
| 356 } |
| 357 |
| 358 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name') + ':cancel'; |
| 359 |
| 360 var _response = _requester.request(_url, |
| 361 "POST", |
| 362 body: _body, |
| 363 queryParams: _queryParams, |
| 364 uploadOptions: _uploadOptions, |
| 365 uploadMedia: _uploadMedia, |
| 366 downloadOptions: _downloadOptions); |
| 367 return _response.then((data) => new Empty.fromJson(data)); |
| 368 } |
| 369 |
| 370 /** |
| 371 * Deletes a long-running operation. This method indicates that the client is |
| 372 * no longer interested in the operation result. It does not cancel the |
| 373 * operation. If the server doesn't support this method, it returns |
| 374 * `google.rpc.Code.UNIMPLEMENTED`. |
| 375 * |
| 376 * Request parameters: |
| 377 * |
| 378 * [name] - The name of the operation resource to be deleted. |
| 379 * Value must have pattern "^projects/[^/]+/operations/[^/]+$". |
| 380 * |
| 381 * Completes with a [Empty]. |
| 382 * |
| 383 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 384 * error. |
| 385 * |
| 386 * If the used [http.Client] completes with an error when making a REST call, |
| 387 * this method will complete with the same error. |
| 388 */ |
| 389 async.Future<Empty> delete(core.String name) { |
| 390 var _url = null; |
| 391 var _queryParams = new core.Map(); |
| 392 var _uploadMedia = null; |
| 393 var _uploadOptions = null; |
| 394 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 395 var _body = null; |
| 396 |
| 397 if (name == null) { |
| 398 throw new core.ArgumentError("Parameter name is required."); |
| 399 } |
| 400 |
| 401 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 402 |
| 403 var _response = _requester.request(_url, |
| 404 "DELETE", |
| 405 body: _body, |
| 406 queryParams: _queryParams, |
| 407 uploadOptions: _uploadOptions, |
| 408 uploadMedia: _uploadMedia, |
| 409 downloadOptions: _downloadOptions); |
| 410 return _response.then((data) => new Empty.fromJson(data)); |
| 411 } |
| 412 |
| 413 /** |
| 414 * Gets the latest state of a long-running operation. Clients can use this |
| 415 * method to poll the operation result at intervals as recommended by the API |
| 416 * service. |
| 417 * |
| 418 * Request parameters: |
| 419 * |
| 420 * [name] - The name of the operation resource. |
| 421 * Value must have pattern "^projects/[^/]+/operations/[^/]+$". |
| 422 * |
| 423 * Completes with a [GoogleLongrunningOperation]. |
| 424 * |
| 425 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 426 * error. |
| 427 * |
| 428 * If the used [http.Client] completes with an error when making a REST call, |
| 429 * this method will complete with the same error. |
| 430 */ |
| 431 async.Future<GoogleLongrunningOperation> get(core.String name) { |
| 432 var _url = null; |
| 433 var _queryParams = new core.Map(); |
| 434 var _uploadMedia = null; |
| 435 var _uploadOptions = null; |
| 436 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 437 var _body = null; |
| 438 |
| 439 if (name == null) { |
| 440 throw new core.ArgumentError("Parameter name is required."); |
| 441 } |
| 442 |
| 443 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name'); |
| 444 |
| 445 var _response = _requester.request(_url, |
| 446 "GET", |
| 447 body: _body, |
| 448 queryParams: _queryParams, |
| 449 uploadOptions: _uploadOptions, |
| 450 uploadMedia: _uploadMedia, |
| 451 downloadOptions: _downloadOptions); |
| 452 return _response.then((data) => new GoogleLongrunningOperation.fromJson(data
)); |
| 453 } |
| 454 |
| 455 /** |
| 456 * Lists operations that match the specified filter in the request. If the |
| 457 * server doesn't support this method, it returns `UNIMPLEMENTED`. |
| 458 * |
| 459 * NOTE: the `name` binding allows API services to override the binding |
| 460 * to use different resource name schemes, such as `users / * /operations`. To |
| 461 * override the binding, API services can add a binding such as |
| 462 * `"/v1/{name=users / * }/operations"` to their service configuration. |
| 463 * For backwards compatibility, the default name includes the operations |
| 464 * collection id, however overriding users must ensure the name binding |
| 465 * is the parent resource, without the operations collection id. |
| 466 * |
| 467 * Request parameters: |
| 468 * |
| 469 * [name] - The name of the operation's parent resource. |
| 470 * Value must have pattern "^projects/[^/]+$". |
| 471 * |
| 472 * [pageSize] - The standard list page size. |
| 473 * |
| 474 * [filter] - The standard list filter. |
| 475 * |
| 476 * [pageToken] - The standard list page token. |
| 477 * |
| 478 * Completes with a [GoogleLongrunningListOperationsResponse]. |
| 479 * |
| 480 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 481 * error. |
| 482 * |
| 483 * If the used [http.Client] completes with an error when making a REST call, |
| 484 * this method will complete with the same error. |
| 485 */ |
| 486 async.Future<GoogleLongrunningListOperationsResponse> list(core.String name, {
core.int pageSize, core.String filter, core.String pageToken}) { |
| 487 var _url = null; |
| 488 var _queryParams = new core.Map(); |
| 489 var _uploadMedia = null; |
| 490 var _uploadOptions = null; |
| 491 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 492 var _body = null; |
| 493 |
| 494 if (name == null) { |
| 495 throw new core.ArgumentError("Parameter name is required."); |
| 496 } |
| 497 if (pageSize != null) { |
| 498 _queryParams["pageSize"] = ["${pageSize}"]; |
| 499 } |
| 500 if (filter != null) { |
| 501 _queryParams["filter"] = [filter]; |
| 502 } |
| 503 if (pageToken != null) { |
| 504 _queryParams["pageToken"] = [pageToken]; |
| 505 } |
| 506 |
| 507 _url = 'v1/' + commons.Escaper.ecapeVariableReserved('$name') + '/operations
'; |
| 508 |
| 509 var _response = _requester.request(_url, |
| 510 "GET", |
| 511 body: _body, |
| 512 queryParams: _queryParams, |
| 513 uploadOptions: _uploadOptions, |
| 514 uploadMedia: _uploadMedia, |
| 515 downloadOptions: _downloadOptions); |
| 516 return _response.then((data) => new GoogleLongrunningListOperationsResponse.
fromJson(data)); |
| 517 } |
| 518 |
| 519 } |
| 520 |
| 521 |
313 | 522 |
314 /** The request for Datastore.AllocateIds. */ | 523 /** The request for Datastore.AllocateIds. */ |
315 class AllocateIdsRequest { | 524 class AllocateIdsRequest { |
316 /** | 525 /** |
317 * A list of keys with incomplete key paths for which to allocate IDs. | 526 * A list of keys with incomplete key paths for which to allocate IDs. |
318 * No key may be reserved/read-only. | 527 * No key may be reserved/read-only. |
319 */ | 528 */ |
320 core.List<Key> keys; | 529 core.List<Key> keys; |
321 | 530 |
322 AllocateIdsRequest(); | 531 AllocateIdsRequest(); |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
382 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 591 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
383 if (values != null) { | 592 if (values != null) { |
384 _json["values"] = values.map((value) => (value).toJson()).toList(); | 593 _json["values"] = values.map((value) => (value).toJson()).toList(); |
385 } | 594 } |
386 return _json; | 595 return _json; |
387 } | 596 } |
388 } | 597 } |
389 | 598 |
390 /** The request for Datastore.BeginTransaction. */ | 599 /** The request for Datastore.BeginTransaction. */ |
391 class BeginTransactionRequest { | 600 class BeginTransactionRequest { |
| 601 /** Options for a new transaction. */ |
| 602 TransactionOptions transactionOptions; |
392 | 603 |
393 BeginTransactionRequest(); | 604 BeginTransactionRequest(); |
394 | 605 |
395 BeginTransactionRequest.fromJson(core.Map _json) { | 606 BeginTransactionRequest.fromJson(core.Map _json) { |
| 607 if (_json.containsKey("transactionOptions")) { |
| 608 transactionOptions = new TransactionOptions.fromJson(_json["transactionOpt
ions"]); |
| 609 } |
396 } | 610 } |
397 | 611 |
398 core.Map<core.String, core.Object> toJson() { | 612 core.Map<core.String, core.Object> toJson() { |
399 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); | 613 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 614 if (transactionOptions != null) { |
| 615 _json["transactionOptions"] = (transactionOptions).toJson(); |
| 616 } |
400 return _json; | 617 return _json; |
401 } | 618 } |
402 } | 619 } |
403 | 620 |
404 /** The response for Datastore.BeginTransaction. */ | 621 /** The response for Datastore.BeginTransaction. */ |
405 class BeginTransactionResponse { | 622 class BeginTransactionResponse { |
406 /** The transaction identifier (always present). */ | 623 /** The transaction identifier (always present). */ |
407 core.String transaction; | 624 core.String transaction; |
408 core.List<core.int> get transactionAsBytes { | 625 core.List<core.int> get transactionAsBytes { |
409 return convert.BASE64.decode(transaction); | 626 return convert.BASE64.decode(transaction); |
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
571 _json["filters"] = filters.map((value) => (value).toJson()).toList(); | 788 _json["filters"] = filters.map((value) => (value).toJson()).toList(); |
572 } | 789 } |
573 if (op != null) { | 790 if (op != null) { |
574 _json["op"] = op; | 791 _json["op"] = op; |
575 } | 792 } |
576 return _json; | 793 return _json; |
577 } | 794 } |
578 } | 795 } |
579 | 796 |
580 /** | 797 /** |
| 798 * A generic empty message that you can re-use to avoid defining duplicated |
| 799 * empty messages in your APIs. A typical example is to use it as the request |
| 800 * or the response type of an API method. For instance: |
| 801 * |
| 802 * service Foo { |
| 803 * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 804 * } |
| 805 * |
| 806 * The JSON representation for `Empty` is empty JSON object `{}`. |
| 807 */ |
| 808 class Empty { |
| 809 |
| 810 Empty(); |
| 811 |
| 812 Empty.fromJson(core.Map _json) { |
| 813 } |
| 814 |
| 815 core.Map<core.String, core.Object> toJson() { |
| 816 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 817 return _json; |
| 818 } |
| 819 } |
| 820 |
| 821 /** |
581 * A Datastore data object. | 822 * A Datastore data object. |
582 * | 823 * |
583 * An entity is limited to 1 megabyte when stored. That _roughly_ | 824 * An entity is limited to 1 megabyte when stored. That _roughly_ |
584 * corresponds to a limit of 1 megabyte for the serialized form of this | 825 * corresponds to a limit of 1 megabyte for the serialized form of this |
585 * message. | 826 * message. |
586 */ | 827 */ |
587 class Entity { | 828 class Entity { |
588 /** | 829 /** |
589 * The entity's key. | 830 * The entity's key. |
590 * | 831 * |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
708 if (compositeFilter != null) { | 949 if (compositeFilter != null) { |
709 _json["compositeFilter"] = (compositeFilter).toJson(); | 950 _json["compositeFilter"] = (compositeFilter).toJson(); |
710 } | 951 } |
711 if (propertyFilter != null) { | 952 if (propertyFilter != null) { |
712 _json["propertyFilter"] = (propertyFilter).toJson(); | 953 _json["propertyFilter"] = (propertyFilter).toJson(); |
713 } | 954 } |
714 return _json; | 955 return _json; |
715 } | 956 } |
716 } | 957 } |
717 | 958 |
| 959 /** Metadata common to all Datastore Admin operations. */ |
| 960 class GoogleDatastoreAdminV1beta1CommonMetadata { |
| 961 /** The time the operation ended, either successfully or otherwise. */ |
| 962 core.String endTime; |
| 963 /** |
| 964 * The client-assigned labels which were provided when the operation was |
| 965 * created. May also include additional labels. |
| 966 */ |
| 967 core.Map<core.String, core.String> labels; |
| 968 /** |
| 969 * The type of the operation. Can be used as a filter in |
| 970 * ListOperationsRequest. |
| 971 * Possible string values are: |
| 972 * - "OPERATION_TYPE_UNSPECIFIED" : Unspecified. |
| 973 * - "EXPORT_ENTITIES" : ExportEntities. |
| 974 * - "IMPORT_ENTITIES" : ImportEntities. |
| 975 * - "BUILD_INDEX" : Build an index. |
| 976 * - "CLEAR_INDEX" : Clear an index. |
| 977 */ |
| 978 core.String operationType; |
| 979 /** The time that work began on the operation. */ |
| 980 core.String startTime; |
| 981 /** |
| 982 * The current state of the Operation. |
| 983 * Possible string values are: |
| 984 * - "STATE_UNSPECIFIED" : Unspecified. |
| 985 * - "INITIALIZING" : Request is being prepared for processing. |
| 986 * - "PROCESSING" : Request is actively being processed. |
| 987 * - "CANCELLING" : Request is in the process of being cancelled after user |
| 988 * called |
| 989 * longrunning.Operations.CancelOperation on the operation. |
| 990 * - "FINALIZING" : Request has been processed and is in its finalization |
| 991 * stage. |
| 992 * - "SUCCESSFUL" : Request has completed successfully. |
| 993 * - "FAILED" : Request has finished being processed, but encountered an |
| 994 * error. |
| 995 * - "CANCELLED" : Request has finished being cancelled after user called |
| 996 * longrunning.Operations.CancelOperation. |
| 997 */ |
| 998 core.String state; |
| 999 |
| 1000 GoogleDatastoreAdminV1beta1CommonMetadata(); |
| 1001 |
| 1002 GoogleDatastoreAdminV1beta1CommonMetadata.fromJson(core.Map _json) { |
| 1003 if (_json.containsKey("endTime")) { |
| 1004 endTime = _json["endTime"]; |
| 1005 } |
| 1006 if (_json.containsKey("labels")) { |
| 1007 labels = _json["labels"]; |
| 1008 } |
| 1009 if (_json.containsKey("operationType")) { |
| 1010 operationType = _json["operationType"]; |
| 1011 } |
| 1012 if (_json.containsKey("startTime")) { |
| 1013 startTime = _json["startTime"]; |
| 1014 } |
| 1015 if (_json.containsKey("state")) { |
| 1016 state = _json["state"]; |
| 1017 } |
| 1018 } |
| 1019 |
| 1020 core.Map<core.String, core.Object> toJson() { |
| 1021 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1022 if (endTime != null) { |
| 1023 _json["endTime"] = endTime; |
| 1024 } |
| 1025 if (labels != null) { |
| 1026 _json["labels"] = labels; |
| 1027 } |
| 1028 if (operationType != null) { |
| 1029 _json["operationType"] = operationType; |
| 1030 } |
| 1031 if (startTime != null) { |
| 1032 _json["startTime"] = startTime; |
| 1033 } |
| 1034 if (state != null) { |
| 1035 _json["state"] = state; |
| 1036 } |
| 1037 return _json; |
| 1038 } |
| 1039 } |
| 1040 |
| 1041 /** |
| 1042 * Identifies a subset of entities in a project. This is specified as |
| 1043 * combinations of kind + namespace (either or both of which may be all, as |
| 1044 * described in the following examples). |
| 1045 * Example usage: |
| 1046 * |
| 1047 * Entire project: |
| 1048 * kinds=[], namespace_ids=[] |
| 1049 * |
| 1050 * Kinds Foo and Bar in all namespaces: |
| 1051 * kinds=['Foo', 'Bar'], namespace_ids=[] |
| 1052 * |
| 1053 * Kinds Foo and Bar only in the default namespace: |
| 1054 * kinds=['Foo', 'Bar'], namespace_ids=[''] |
| 1055 * |
| 1056 * Kinds Foo and Bar in both the default and Baz namespaces: |
| 1057 * kinds=['Foo', 'Bar'], namespace_ids=['', 'Baz'] |
| 1058 * |
| 1059 * The entire Baz namespace: |
| 1060 * kinds=[], namespace_ids=['Baz'] |
| 1061 */ |
| 1062 class GoogleDatastoreAdminV1beta1EntityFilter { |
| 1063 /** If empty, then this represents all kinds. */ |
| 1064 core.List<core.String> kinds; |
| 1065 /** |
| 1066 * An empty list represents all namespaces. This is the preferred |
| 1067 * usage for projects that don't use namespaces. |
| 1068 * |
| 1069 * An empty string element represents the default namespace. This should be |
| 1070 * used if the project has data in non-default namespaces, but doesn't want to |
| 1071 * include them. |
| 1072 * Each namespace in this list must be unique. |
| 1073 */ |
| 1074 core.List<core.String> namespaceIds; |
| 1075 |
| 1076 GoogleDatastoreAdminV1beta1EntityFilter(); |
| 1077 |
| 1078 GoogleDatastoreAdminV1beta1EntityFilter.fromJson(core.Map _json) { |
| 1079 if (_json.containsKey("kinds")) { |
| 1080 kinds = _json["kinds"]; |
| 1081 } |
| 1082 if (_json.containsKey("namespaceIds")) { |
| 1083 namespaceIds = _json["namespaceIds"]; |
| 1084 } |
| 1085 } |
| 1086 |
| 1087 core.Map<core.String, core.Object> toJson() { |
| 1088 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1089 if (kinds != null) { |
| 1090 _json["kinds"] = kinds; |
| 1091 } |
| 1092 if (namespaceIds != null) { |
| 1093 _json["namespaceIds"] = namespaceIds; |
| 1094 } |
| 1095 return _json; |
| 1096 } |
| 1097 } |
| 1098 |
| 1099 /** Metadata for ExportEntities operations. */ |
| 1100 class GoogleDatastoreAdminV1beta1ExportEntitiesMetadata { |
| 1101 /** Metadata common to all Datastore Admin operations. */ |
| 1102 GoogleDatastoreAdminV1beta1CommonMetadata common; |
| 1103 /** Description of which entities are being exported. */ |
| 1104 GoogleDatastoreAdminV1beta1EntityFilter entityFilter; |
| 1105 /** |
| 1106 * Location for the export metadata and data files. This will be the same |
| 1107 * value as the |
| 1108 * google.datastore.admin.v1beta1.ExportEntitiesRequest.output_url_prefix |
| 1109 * field. The final output location is provided in |
| 1110 * google.datastore.admin.v1beta1.ExportEntitiesResponse.output_url. |
| 1111 */ |
| 1112 core.String outputUrlPrefix; |
| 1113 /** An estimate of the number of bytes processed. */ |
| 1114 GoogleDatastoreAdminV1beta1Progress progressBytes; |
| 1115 /** An estimate of the number of entities processed. */ |
| 1116 GoogleDatastoreAdminV1beta1Progress progressEntities; |
| 1117 |
| 1118 GoogleDatastoreAdminV1beta1ExportEntitiesMetadata(); |
| 1119 |
| 1120 GoogleDatastoreAdminV1beta1ExportEntitiesMetadata.fromJson(core.Map _json) { |
| 1121 if (_json.containsKey("common")) { |
| 1122 common = new GoogleDatastoreAdminV1beta1CommonMetadata.fromJson(_json["com
mon"]); |
| 1123 } |
| 1124 if (_json.containsKey("entityFilter")) { |
| 1125 entityFilter = new GoogleDatastoreAdminV1beta1EntityFilter.fromJson(_json[
"entityFilter"]); |
| 1126 } |
| 1127 if (_json.containsKey("outputUrlPrefix")) { |
| 1128 outputUrlPrefix = _json["outputUrlPrefix"]; |
| 1129 } |
| 1130 if (_json.containsKey("progressBytes")) { |
| 1131 progressBytes = new GoogleDatastoreAdminV1beta1Progress.fromJson(_json["pr
ogressBytes"]); |
| 1132 } |
| 1133 if (_json.containsKey("progressEntities")) { |
| 1134 progressEntities = new GoogleDatastoreAdminV1beta1Progress.fromJson(_json[
"progressEntities"]); |
| 1135 } |
| 1136 } |
| 1137 |
| 1138 core.Map<core.String, core.Object> toJson() { |
| 1139 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1140 if (common != null) { |
| 1141 _json["common"] = (common).toJson(); |
| 1142 } |
| 1143 if (entityFilter != null) { |
| 1144 _json["entityFilter"] = (entityFilter).toJson(); |
| 1145 } |
| 1146 if (outputUrlPrefix != null) { |
| 1147 _json["outputUrlPrefix"] = outputUrlPrefix; |
| 1148 } |
| 1149 if (progressBytes != null) { |
| 1150 _json["progressBytes"] = (progressBytes).toJson(); |
| 1151 } |
| 1152 if (progressEntities != null) { |
| 1153 _json["progressEntities"] = (progressEntities).toJson(); |
| 1154 } |
| 1155 return _json; |
| 1156 } |
| 1157 } |
| 1158 |
| 1159 /** |
| 1160 * The response for |
| 1161 * google.datastore.admin.v1beta1.DatastoreAdmin.ExportEntities. |
| 1162 */ |
| 1163 class GoogleDatastoreAdminV1beta1ExportEntitiesResponse { |
| 1164 /** |
| 1165 * Location of the output metadata file. This can be used to begin an import |
| 1166 * into Cloud Datastore (this project or another project). See |
| 1167 * google.datastore.admin.v1beta1.ImportEntitiesRequest.input_url. |
| 1168 * Only present if the operation completed successfully. |
| 1169 */ |
| 1170 core.String outputUrl; |
| 1171 |
| 1172 GoogleDatastoreAdminV1beta1ExportEntitiesResponse(); |
| 1173 |
| 1174 GoogleDatastoreAdminV1beta1ExportEntitiesResponse.fromJson(core.Map _json) { |
| 1175 if (_json.containsKey("outputUrl")) { |
| 1176 outputUrl = _json["outputUrl"]; |
| 1177 } |
| 1178 } |
| 1179 |
| 1180 core.Map<core.String, core.Object> toJson() { |
| 1181 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1182 if (outputUrl != null) { |
| 1183 _json["outputUrl"] = outputUrl; |
| 1184 } |
| 1185 return _json; |
| 1186 } |
| 1187 } |
| 1188 |
| 1189 /** Metadata for ImportEntities operations. */ |
| 1190 class GoogleDatastoreAdminV1beta1ImportEntitiesMetadata { |
| 1191 /** Metadata common to all Datastore Admin operations. */ |
| 1192 GoogleDatastoreAdminV1beta1CommonMetadata common; |
| 1193 /** Description of which entities are being imported. */ |
| 1194 GoogleDatastoreAdminV1beta1EntityFilter entityFilter; |
| 1195 /** |
| 1196 * The location of the import metadata file. This will be the same value as |
| 1197 * the google.datastore.admin.v1beta1.ExportEntitiesResponse.output_url |
| 1198 * field. |
| 1199 */ |
| 1200 core.String inputUrl; |
| 1201 /** An estimate of the number of bytes processed. */ |
| 1202 GoogleDatastoreAdminV1beta1Progress progressBytes; |
| 1203 /** An estimate of the number of entities processed. */ |
| 1204 GoogleDatastoreAdminV1beta1Progress progressEntities; |
| 1205 |
| 1206 GoogleDatastoreAdminV1beta1ImportEntitiesMetadata(); |
| 1207 |
| 1208 GoogleDatastoreAdminV1beta1ImportEntitiesMetadata.fromJson(core.Map _json) { |
| 1209 if (_json.containsKey("common")) { |
| 1210 common = new GoogleDatastoreAdminV1beta1CommonMetadata.fromJson(_json["com
mon"]); |
| 1211 } |
| 1212 if (_json.containsKey("entityFilter")) { |
| 1213 entityFilter = new GoogleDatastoreAdminV1beta1EntityFilter.fromJson(_json[
"entityFilter"]); |
| 1214 } |
| 1215 if (_json.containsKey("inputUrl")) { |
| 1216 inputUrl = _json["inputUrl"]; |
| 1217 } |
| 1218 if (_json.containsKey("progressBytes")) { |
| 1219 progressBytes = new GoogleDatastoreAdminV1beta1Progress.fromJson(_json["pr
ogressBytes"]); |
| 1220 } |
| 1221 if (_json.containsKey("progressEntities")) { |
| 1222 progressEntities = new GoogleDatastoreAdminV1beta1Progress.fromJson(_json[
"progressEntities"]); |
| 1223 } |
| 1224 } |
| 1225 |
| 1226 core.Map<core.String, core.Object> toJson() { |
| 1227 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1228 if (common != null) { |
| 1229 _json["common"] = (common).toJson(); |
| 1230 } |
| 1231 if (entityFilter != null) { |
| 1232 _json["entityFilter"] = (entityFilter).toJson(); |
| 1233 } |
| 1234 if (inputUrl != null) { |
| 1235 _json["inputUrl"] = inputUrl; |
| 1236 } |
| 1237 if (progressBytes != null) { |
| 1238 _json["progressBytes"] = (progressBytes).toJson(); |
| 1239 } |
| 1240 if (progressEntities != null) { |
| 1241 _json["progressEntities"] = (progressEntities).toJson(); |
| 1242 } |
| 1243 return _json; |
| 1244 } |
| 1245 } |
| 1246 |
| 1247 /** Measures the progress of a particular metric. */ |
| 1248 class GoogleDatastoreAdminV1beta1Progress { |
| 1249 /** Note that this may be greater than work_estimated. */ |
| 1250 core.String workCompleted; |
| 1251 /** |
| 1252 * An estimate of how much work needs to be performed. May be zero if the |
| 1253 * work estimate is unavailable. |
| 1254 */ |
| 1255 core.String workEstimated; |
| 1256 |
| 1257 GoogleDatastoreAdminV1beta1Progress(); |
| 1258 |
| 1259 GoogleDatastoreAdminV1beta1Progress.fromJson(core.Map _json) { |
| 1260 if (_json.containsKey("workCompleted")) { |
| 1261 workCompleted = _json["workCompleted"]; |
| 1262 } |
| 1263 if (_json.containsKey("workEstimated")) { |
| 1264 workEstimated = _json["workEstimated"]; |
| 1265 } |
| 1266 } |
| 1267 |
| 1268 core.Map<core.String, core.Object> toJson() { |
| 1269 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1270 if (workCompleted != null) { |
| 1271 _json["workCompleted"] = workCompleted; |
| 1272 } |
| 1273 if (workEstimated != null) { |
| 1274 _json["workEstimated"] = workEstimated; |
| 1275 } |
| 1276 return _json; |
| 1277 } |
| 1278 } |
| 1279 |
| 1280 /** The response message for Operations.ListOperations. */ |
| 1281 class GoogleLongrunningListOperationsResponse { |
| 1282 /** The standard List next-page token. */ |
| 1283 core.String nextPageToken; |
| 1284 /** A list of operations that matches the specified filter in the request. */ |
| 1285 core.List<GoogleLongrunningOperation> operations; |
| 1286 |
| 1287 GoogleLongrunningListOperationsResponse(); |
| 1288 |
| 1289 GoogleLongrunningListOperationsResponse.fromJson(core.Map _json) { |
| 1290 if (_json.containsKey("nextPageToken")) { |
| 1291 nextPageToken = _json["nextPageToken"]; |
| 1292 } |
| 1293 if (_json.containsKey("operations")) { |
| 1294 operations = _json["operations"].map((value) => new GoogleLongrunningOpera
tion.fromJson(value)).toList(); |
| 1295 } |
| 1296 } |
| 1297 |
| 1298 core.Map<core.String, core.Object> toJson() { |
| 1299 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1300 if (nextPageToken != null) { |
| 1301 _json["nextPageToken"] = nextPageToken; |
| 1302 } |
| 1303 if (operations != null) { |
| 1304 _json["operations"] = operations.map((value) => (value).toJson()).toList()
; |
| 1305 } |
| 1306 return _json; |
| 1307 } |
| 1308 } |
| 1309 |
| 1310 /** |
| 1311 * This resource represents a long-running operation that is the result of a |
| 1312 * network API call. |
| 1313 */ |
| 1314 class GoogleLongrunningOperation { |
| 1315 /** |
| 1316 * If the value is `false`, it means the operation is still in progress. |
| 1317 * If true, the operation is completed, and either `error` or `response` is |
| 1318 * available. |
| 1319 */ |
| 1320 core.bool done; |
| 1321 /** The error result of the operation in case of failure or cancellation. */ |
| 1322 Status error; |
| 1323 /** |
| 1324 * Service-specific metadata associated with the operation. It typically |
| 1325 * contains progress information and common metadata such as create time. |
| 1326 * Some services might not provide such metadata. Any method that returns a |
| 1327 * long-running operation should document the metadata type, if any. |
| 1328 * |
| 1329 * The values for Object must be JSON objects. It can consist of `num`, |
| 1330 * `String`, `bool` and `null` as well as `Map` and `List` values. |
| 1331 */ |
| 1332 core.Map<core.String, core.Object> metadata; |
| 1333 /** |
| 1334 * The server-assigned name, which is only unique within the same service that |
| 1335 * originally returns it. If you use the default HTTP mapping, the |
| 1336 * `name` should have the format of `operations/some/unique/name`. |
| 1337 */ |
| 1338 core.String name; |
| 1339 /** |
| 1340 * The normal response of the operation in case of success. If the original |
| 1341 * method returns no data on success, such as `Delete`, the response is |
| 1342 * `google.protobuf.Empty`. If the original method is standard |
| 1343 * `Get`/`Create`/`Update`, the response should be the resource. For other |
| 1344 * methods, the response should have the type `XxxResponse`, where `Xxx` |
| 1345 * is the original method name. For example, if the original method name |
| 1346 * is `TakeSnapshot()`, the inferred response type is |
| 1347 * `TakeSnapshotResponse`. |
| 1348 * |
| 1349 * The values for Object must be JSON objects. It can consist of `num`, |
| 1350 * `String`, `bool` and `null` as well as `Map` and `List` values. |
| 1351 */ |
| 1352 core.Map<core.String, core.Object> response; |
| 1353 |
| 1354 GoogleLongrunningOperation(); |
| 1355 |
| 1356 GoogleLongrunningOperation.fromJson(core.Map _json) { |
| 1357 if (_json.containsKey("done")) { |
| 1358 done = _json["done"]; |
| 1359 } |
| 1360 if (_json.containsKey("error")) { |
| 1361 error = new Status.fromJson(_json["error"]); |
| 1362 } |
| 1363 if (_json.containsKey("metadata")) { |
| 1364 metadata = _json["metadata"]; |
| 1365 } |
| 1366 if (_json.containsKey("name")) { |
| 1367 name = _json["name"]; |
| 1368 } |
| 1369 if (_json.containsKey("response")) { |
| 1370 response = _json["response"]; |
| 1371 } |
| 1372 } |
| 1373 |
| 1374 core.Map<core.String, core.Object> toJson() { |
| 1375 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 1376 if (done != null) { |
| 1377 _json["done"] = done; |
| 1378 } |
| 1379 if (error != null) { |
| 1380 _json["error"] = (error).toJson(); |
| 1381 } |
| 1382 if (metadata != null) { |
| 1383 _json["metadata"] = metadata; |
| 1384 } |
| 1385 if (name != null) { |
| 1386 _json["name"] = name; |
| 1387 } |
| 1388 if (response != null) { |
| 1389 _json["response"] = response; |
| 1390 } |
| 1391 return _json; |
| 1392 } |
| 1393 } |
| 1394 |
718 /** | 1395 /** |
719 * A [GQL | 1396 * A [GQL |
720 * query](https://cloud.google.com/datastore/docs/apis/gql/gql_reference). | 1397 * query](https://cloud.google.com/datastore/docs/apis/gql/gql_reference). |
721 */ | 1398 */ |
722 class GqlQuery { | 1399 class GqlQuery { |
723 /** | 1400 /** |
724 * When false, the query string must not contain any literals and instead must | 1401 * When false, the query string must not contain any literals and instead must |
725 * bind all values. For example, | 1402 * bind all values. For example, |
726 * `SELECT * FROM Kind WHERE a = 'string literal'` is not allowed, while | 1403 * `SELECT * FROM Kind WHERE a = 'string literal'` is not allowed, while |
727 * `SELECT * FROM Kind WHERE a = @value` is. | 1404 * `SELECT * FROM Kind WHERE a = @value` is. |
(...skipping 921 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1649 if (skippedResults != null) { | 2326 if (skippedResults != null) { |
1650 _json["skippedResults"] = skippedResults; | 2327 _json["skippedResults"] = skippedResults; |
1651 } | 2328 } |
1652 if (snapshotVersion != null) { | 2329 if (snapshotVersion != null) { |
1653 _json["snapshotVersion"] = snapshotVersion; | 2330 _json["snapshotVersion"] = snapshotVersion; |
1654 } | 2331 } |
1655 return _json; | 2332 return _json; |
1656 } | 2333 } |
1657 } | 2334 } |
1658 | 2335 |
| 2336 /** Options specific to read-only transactions. */ |
| 2337 class ReadOnly { |
| 2338 |
| 2339 ReadOnly(); |
| 2340 |
| 2341 ReadOnly.fromJson(core.Map _json) { |
| 2342 } |
| 2343 |
| 2344 core.Map<core.String, core.Object> toJson() { |
| 2345 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 2346 return _json; |
| 2347 } |
| 2348 } |
| 2349 |
1659 /** The options shared by read requests. */ | 2350 /** The options shared by read requests. */ |
1660 class ReadOptions { | 2351 class ReadOptions { |
1661 /** | 2352 /** |
1662 * The non-transactional read consistency to use. | 2353 * The non-transactional read consistency to use. |
1663 * Cannot be set to `STRONG` for global queries. | 2354 * Cannot be set to `STRONG` for global queries. |
1664 * Possible string values are: | 2355 * Possible string values are: |
1665 * - "READ_CONSISTENCY_UNSPECIFIED" : Unspecified. This value must not be | 2356 * - "READ_CONSISTENCY_UNSPECIFIED" : Unspecified. This value must not be |
1666 * used. | 2357 * used. |
1667 * - "STRONG" : Strong consistency. | 2358 * - "STRONG" : Strong consistency. |
1668 * - "EVENTUAL" : Eventual consistency. | 2359 * - "EVENTUAL" : Eventual consistency. |
(...skipping 29 matching lines...) Expand all Loading... |
1698 if (readConsistency != null) { | 2389 if (readConsistency != null) { |
1699 _json["readConsistency"] = readConsistency; | 2390 _json["readConsistency"] = readConsistency; |
1700 } | 2391 } |
1701 if (transaction != null) { | 2392 if (transaction != null) { |
1702 _json["transaction"] = transaction; | 2393 _json["transaction"] = transaction; |
1703 } | 2394 } |
1704 return _json; | 2395 return _json; |
1705 } | 2396 } |
1706 } | 2397 } |
1707 | 2398 |
| 2399 /** Options specific to read / write transactions. */ |
| 2400 class ReadWrite { |
| 2401 /** The transaction identifier of the transaction being retried. */ |
| 2402 core.String previousTransaction; |
| 2403 core.List<core.int> get previousTransactionAsBytes { |
| 2404 return convert.BASE64.decode(previousTransaction); |
| 2405 } |
| 2406 |
| 2407 void set previousTransactionAsBytes(core.List<core.int> _bytes) { |
| 2408 previousTransaction = convert.BASE64.encode(_bytes).replaceAll("/", "_").rep
laceAll("+", "-"); |
| 2409 } |
| 2410 |
| 2411 ReadWrite(); |
| 2412 |
| 2413 ReadWrite.fromJson(core.Map _json) { |
| 2414 if (_json.containsKey("previousTransaction")) { |
| 2415 previousTransaction = _json["previousTransaction"]; |
| 2416 } |
| 2417 } |
| 2418 |
| 2419 core.Map<core.String, core.Object> toJson() { |
| 2420 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 2421 if (previousTransaction != null) { |
| 2422 _json["previousTransaction"] = previousTransaction; |
| 2423 } |
| 2424 return _json; |
| 2425 } |
| 2426 } |
| 2427 |
1708 /** The request for Datastore.Rollback. */ | 2428 /** The request for Datastore.Rollback. */ |
1709 class RollbackRequest { | 2429 class RollbackRequest { |
1710 /** | 2430 /** |
1711 * The transaction identifier, returned by a call to | 2431 * The transaction identifier, returned by a call to |
1712 * Datastore.BeginTransaction. | 2432 * Datastore.BeginTransaction. |
1713 */ | 2433 */ |
1714 core.String transaction; | 2434 core.String transaction; |
1715 core.List<core.int> get transactionAsBytes { | 2435 core.List<core.int> get transactionAsBytes { |
1716 return convert.BASE64.decode(transaction); | 2436 return convert.BASE64.decode(transaction); |
1717 } | 2437 } |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1829 _json["batch"] = (batch).toJson(); | 2549 _json["batch"] = (batch).toJson(); |
1830 } | 2550 } |
1831 if (query != null) { | 2551 if (query != null) { |
1832 _json["query"] = (query).toJson(); | 2552 _json["query"] = (query).toJson(); |
1833 } | 2553 } |
1834 return _json; | 2554 return _json; |
1835 } | 2555 } |
1836 } | 2556 } |
1837 | 2557 |
1838 /** | 2558 /** |
| 2559 * The `Status` type defines a logical error model that is suitable for |
| 2560 * different |
| 2561 * programming environments, including REST APIs and RPC APIs. It is used by |
| 2562 * [gRPC](https://github.com/grpc). The error model is designed to be: |
| 2563 * |
| 2564 * - Simple to use and understand for most users |
| 2565 * - Flexible enough to meet unexpected needs |
| 2566 * |
| 2567 * # Overview |
| 2568 * |
| 2569 * The `Status` message contains three pieces of data: error code, error |
| 2570 * message, |
| 2571 * and error details. The error code should be an enum value of |
| 2572 * google.rpc.Code, but it may accept additional error codes if needed. The |
| 2573 * error message should be a developer-facing English message that helps |
| 2574 * developers *understand* and *resolve* the error. If a localized user-facing |
| 2575 * error message is needed, put the localized message in the error details or |
| 2576 * localize it in the client. The optional error details may contain arbitrary |
| 2577 * information about the error. There is a predefined set of error detail types |
| 2578 * in the package `google.rpc` that can be used for common error conditions. |
| 2579 * |
| 2580 * # Language mapping |
| 2581 * |
| 2582 * The `Status` message is the logical representation of the error model, but it |
| 2583 * is not necessarily the actual wire format. When the `Status` message is |
| 2584 * exposed in different client libraries and different wire protocols, it can be |
| 2585 * mapped differently. For example, it will likely be mapped to some exceptions |
| 2586 * in Java, but more likely mapped to some error codes in C. |
| 2587 * |
| 2588 * # Other uses |
| 2589 * |
| 2590 * The error model and the `Status` message can be used in a variety of |
| 2591 * environments, either with or without APIs, to provide a |
| 2592 * consistent developer experience across different environments. |
| 2593 * |
| 2594 * Example uses of this error model include: |
| 2595 * |
| 2596 * - Partial errors. If a service needs to return partial errors to the client, |
| 2597 * it may embed the `Status` in the normal response to indicate the partial |
| 2598 * errors. |
| 2599 * |
| 2600 * - Workflow errors. A typical workflow has multiple steps. Each step may |
| 2601 * have a `Status` message for error reporting. |
| 2602 * |
| 2603 * - Batch operations. If a client uses batch request and batch response, the |
| 2604 * `Status` message should be used directly inside batch response, one for |
| 2605 * each error sub-response. |
| 2606 * |
| 2607 * - Asynchronous operations. If an API call embeds asynchronous operation |
| 2608 * results in its response, the status of those operations should be |
| 2609 * represented directly using the `Status` message. |
| 2610 * |
| 2611 * - Logging. If some API errors are stored in logs, the message `Status` could |
| 2612 * be used directly after any stripping needed for security/privacy reasons. |
| 2613 */ |
| 2614 class Status { |
| 2615 /** The status code, which should be an enum value of google.rpc.Code. */ |
| 2616 core.int code; |
| 2617 /** |
| 2618 * A list of messages that carry the error details. There is a common set of |
| 2619 * message types for APIs to use. |
| 2620 * |
| 2621 * The values for Object must be JSON objects. It can consist of `num`, |
| 2622 * `String`, `bool` and `null` as well as `Map` and `List` values. |
| 2623 */ |
| 2624 core.List<core.Map<core.String, core.Object>> details; |
| 2625 /** |
| 2626 * A developer-facing error message, which should be in English. Any |
| 2627 * user-facing error message should be localized and sent in the |
| 2628 * google.rpc.Status.details field, or localized by the client. |
| 2629 */ |
| 2630 core.String message; |
| 2631 |
| 2632 Status(); |
| 2633 |
| 2634 Status.fromJson(core.Map _json) { |
| 2635 if (_json.containsKey("code")) { |
| 2636 code = _json["code"]; |
| 2637 } |
| 2638 if (_json.containsKey("details")) { |
| 2639 details = _json["details"]; |
| 2640 } |
| 2641 if (_json.containsKey("message")) { |
| 2642 message = _json["message"]; |
| 2643 } |
| 2644 } |
| 2645 |
| 2646 core.Map<core.String, core.Object> toJson() { |
| 2647 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 2648 if (code != null) { |
| 2649 _json["code"] = code; |
| 2650 } |
| 2651 if (details != null) { |
| 2652 _json["details"] = details; |
| 2653 } |
| 2654 if (message != null) { |
| 2655 _json["message"] = message; |
| 2656 } |
| 2657 return _json; |
| 2658 } |
| 2659 } |
| 2660 |
| 2661 /** |
| 2662 * Options for beginning a new transaction. |
| 2663 * |
| 2664 * Transactions can be created explicitly with calls to |
| 2665 * Datastore.BeginTransaction or implicitly by setting |
| 2666 * ReadOptions.new_transaction in read requests. |
| 2667 */ |
| 2668 class TransactionOptions { |
| 2669 /** The transaction should only allow reads. */ |
| 2670 ReadOnly readOnly; |
| 2671 /** The transaction should allow both reads and writes. */ |
| 2672 ReadWrite readWrite; |
| 2673 |
| 2674 TransactionOptions(); |
| 2675 |
| 2676 TransactionOptions.fromJson(core.Map _json) { |
| 2677 if (_json.containsKey("readOnly")) { |
| 2678 readOnly = new ReadOnly.fromJson(_json["readOnly"]); |
| 2679 } |
| 2680 if (_json.containsKey("readWrite")) { |
| 2681 readWrite = new ReadWrite.fromJson(_json["readWrite"]); |
| 2682 } |
| 2683 } |
| 2684 |
| 2685 core.Map<core.String, core.Object> toJson() { |
| 2686 final core.Map<core.String, core.Object> _json = new core.Map<core.String, c
ore.Object>(); |
| 2687 if (readOnly != null) { |
| 2688 _json["readOnly"] = (readOnly).toJson(); |
| 2689 } |
| 2690 if (readWrite != null) { |
| 2691 _json["readWrite"] = (readWrite).toJson(); |
| 2692 } |
| 2693 return _json; |
| 2694 } |
| 2695 } |
| 2696 |
| 2697 /** |
1839 * A message that can hold any of the supported value types and associated | 2698 * A message that can hold any of the supported value types and associated |
1840 * metadata. | 2699 * metadata. |
1841 */ | 2700 */ |
1842 class Value { | 2701 class Value { |
1843 /** | 2702 /** |
1844 * An array value. | 2703 * An array value. |
1845 * Cannot contain another array value. | 2704 * Cannot contain another array value. |
1846 * A `Value` instance that sets field `array_value` must not set fields | 2705 * A `Value` instance that sets field `array_value` must not set fields |
1847 * `meaning` or `exclude_from_indexes`. | 2706 * `meaning` or `exclude_from_indexes`. |
1848 */ | 2707 */ |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1989 } | 2848 } |
1990 if (stringValue != null) { | 2849 if (stringValue != null) { |
1991 _json["stringValue"] = stringValue; | 2850 _json["stringValue"] = stringValue; |
1992 } | 2851 } |
1993 if (timestampValue != null) { | 2852 if (timestampValue != null) { |
1994 _json["timestampValue"] = timestampValue; | 2853 _json["timestampValue"] = timestampValue; |
1995 } | 2854 } |
1996 return _json; | 2855 return _json; |
1997 } | 2856 } |
1998 } | 2857 } |
OLD | NEW |