From 0c841f9b8c03aaeceb2762492daeeda9f8efdd66 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Tue, 21 Jul 2020 14:45:14 -0700 Subject: [PATCH] chore: regenerate files from googleapis and synthtool templates (#300) * Integrate Python GAPIC Microgenerator in googleapis. This PR uses using documentai as an example. Depends on https://github.com/googleapis/gapic-generator-python/pull/402 PiperOrigin-RevId: 309824146 Source-Author: Google APIs Source-Date: Mon May 4 15:06:44 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: e0f9d9e1f9de890db765be46f45ca8490723e3eb Source-Link: https://github.com/googleapis/googleapis/commit/e0f9d9e1f9de890db765be46f45ca8490723e3eb * ci(java): switch to GitHub Actions * ci: switch to GitHub Actions * update based on comment Source-Author: Stephanie Wang Source-Date: Mon May 11 12:54:00 2020 -0400 Source-Repo: googleapis/synthtool Source-Sha: 55cdc844877d97139f25004229842624a6a86a02 Source-Link: https://github.com/googleapis/synthtool/commit/55cdc844877d97139f25004229842624a6a86a02 * chore: move ci.yaml to workflows dir Source-Author: Stephanie Wang Source-Date: Mon May 11 16:24:04 2020 -0400 Source-Repo: googleapis/synthtool Source-Sha: 98c50772ec23295c64cf0d2ddf199ea52961fd4c Source-Link: https://github.com/googleapis/synthtool/commit/98c50772ec23295c64cf0d2ddf199ea52961fd4c * docs: update CONTRIBUTING.md to include code formatting Co-authored-by: Jeff Ching Co-authored-by: Jeffrey Rennie Source-Author: Brian Chen Source-Date: Tue May 12 10:24:59 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: 5b48b0716a36ca069db3038da7e205c87a22ed19 Source-Link: https://github.com/googleapis/synthtool/commit/5b48b0716a36ca069db3038da7e205c87a22ed19 * fix: restore GAPIC v2 retry configs Restores GAPIC v2 retry config overrides that were mistakenly removed during migration. PiperOrigin-RevId: 312088359 Source-Author: Google APIs Source-Date: Mon May 18 08:57:12 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: 5a90d467aa65e7f038f87585e8fbb45d74475e7c Source-Link: https://github.com/googleapis/googleapis/commit/5a90d467aa65e7f038f87585e8fbb45d74475e7c * bazel: update protobuf, rules_go, gazelle, and gapic-generator-go versions - protobuf v3.12.1 - rules_go v0.23.0 - gazelle v0.21.0 - gapic-generator-go v0.14.1 PiperOrigin-RevId: 313460921 Source-Author: Google APIs Source-Date: Wed May 27 14:10:16 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: c4e37010d74071851ff24121f522e802231ac86e Source-Link: https://github.com/googleapis/googleapis/commit/c4e37010d74071851ff24121f522e802231ac86e * firestore: add BatchWrite PiperOrigin-RevId: 314471006 Source-Author: Google APIs Source-Date: Tue Jun 2 22:32:52 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: d5fe42c39cd35f95131a0267314ae108ab1bef8d Source-Link: https://github.com/googleapis/googleapis/commit/d5fe42c39cd35f95131a0267314ae108ab1bef8d * chore: turn on renovate-bot master issue for java repos Source-Author: Stephanie Wang Source-Date: Thu Jun 4 18:23:16 2020 -0400 Source-Repo: googleapis/synthtool Source-Sha: cac9eef310652bf138dd76b716e4986e757d62ac Source-Link: https://github.com/googleapis/synthtool/commit/cac9eef310652bf138dd76b716e4986e757d62ac * build(java): skip lint on samples directory Let the samples test decide how to enforce linting Source-Author: Jeff Ching Source-Date: Fri Jun 5 13:40:10 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: 987270824bd26f6a8c716d5e2022057b8ae7b26e Source-Link: https://github.com/googleapis/synthtool/commit/987270824bd26f6a8c716d5e2022057b8ae7b26e * chore: set Ruby namespace in proto options PiperOrigin-RevId: 316123861 Source-Author: Google APIs Source-Date: Fri Jun 12 10:03:16 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: 66f959b51c255dd6bef79ef221865e53a50df878 Source-Link: https://github.com/googleapis/googleapis/commit/66f959b51c255dd6bef79ef221865e53a50df878 * ci(java): switch to secret manager from keystore * ci(java): switch to secret manager from keystore, use java-docs-samples user for samples tests * fix: we don't need to supply a service account Source-Author: Jeff Ching Source-Date: Mon Jun 15 11:45:21 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: d1addcdf80aa9ddef8c932c89c919024bbad7af3 Source-Link: https://github.com/googleapis/synthtool/commit/d1addcdf80aa9ddef8c932c89c919024bbad7af3 * feat: retry CommitRequests that fail with UNAVAILABLE PiperOrigin-RevId: 316514901 Source-Author: Google APIs Source-Date: Mon Jun 15 12:00:19 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: 9b170a4f3beb16f7dab513520a07be48fcb88670 Source-Link: https://github.com/googleapis/googleapis/commit/9b170a4f3beb16f7dab513520a07be48fcb88670 * samples(java): fix bad character in samples.cfg from copy/paste Somehow an invisible character was copy/pasted into the file and Kokoro cannot parse the file. Source-Author: Jeff Ching Source-Date: Mon Jun 15 15:42:10 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: 6d3eed67a45fd58f9c7bfa173c32e4fd4fed058f Source-Link: https://github.com/googleapis/synthtool/commit/6d3eed67a45fd58f9c7bfa173c32e4fd4fed058f * ci(java): run dependency test on Java 8 and 11 Redo fix in #633 with proper jinja templating format Source-Author: Jeff Ching Source-Date: Fri Jun 19 16:52:15 2020 -0700 Source-Repo: googleapis/synthtool Source-Sha: 4f2c9f752a94042472fc03c5bd9e06e89817d2bd Source-Link: https://github.com/googleapis/synthtool/commit/4f2c9f752a94042472fc03c5bd9e06e89817d2bd * firestore: add BatchWrite to service config PiperOrigin-RevId: 318331819 Source-Author: Google APIs Source-Date: Thu Jun 25 13:02:29 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: 0a602be7b3835b51d59daf8f6f5dc2dc22f69d7e Source-Link: https://github.com/googleapis/googleapis/commit/0a602be7b3835b51d59daf8f6f5dc2dc22f69d7e * firestore: add BatchWrite to gapic yaml PiperOrigin-RevId: 319105199 Source-Author: Google APIs Source-Date: Tue Jun 30 14:56:36 2020 -0700 Source-Repo: googleapis/googleapis Source-Sha: cbd6f1d28bc0c461c234f9848bcbc1563126daf9 Source-Link: https://github.com/googleapis/googleapis/commit/cbd6f1d28bc0c461c234f9848bcbc1563126daf9 * chore: update integration and samples credentials Co-authored-by: BenWhitehead --- .github/workflows/ci.yaml | 5 +- .kokoro/build.sh | 6 +- .kokoro/dependencies.sh | 4 +- .kokoro/nightly/integration.cfg | 22 +- .kokoro/nightly/samples.cfg | 20 +- .kokoro/populate-secrets.sh | 43 + .kokoro/presubmit/integration.cfg | 12 +- .kokoro/presubmit/samples.cfg | 16 +- .kokoro/trampoline.sh | 2 + .../cloud/firestore/v1/FirestoreClient.java | 235 ++ .../cloud/firestore/v1/FirestoreSettings.java | 29 + .../v1/stub/FirestoreAdminStubSettings.java | 17 +- .../firestore/v1/stub/FirestoreStub.java | 18 + .../v1/stub/FirestoreStubSettings.java | 137 +- .../firestore/v1/stub/GrpcFirestoreStub.java | 76 + .../firestore/v1/FirestoreClientTest.java | 96 + .../cloud/firestore/v1/MockFirestoreImpl.java | 40 +- .../firestore/v1beta1/MockFirestoreImpl.java | 6 +- .../google/firestore/v1/FirestoreGrpc.java | 264 +- .../admin/v1/CreateIndexRequest.java | 5 + .../admin/v1/DeleteIndexRequest.java | 2 + .../admin/v1/ExportDocumentsMetadata.java | 19 + .../admin/v1/ExportDocumentsRequest.java | 4 + .../admin/v1/ExportDocumentsResponse.java | 2 + .../com/google/firestore/admin/v1/Field.java | 16 + .../admin/v1/FieldOperationMetadata.java | 36 + .../google/firestore/admin/v1/FieldProto.java | 5 +- .../admin/v1/FirestoreAdminProto.java | 14 +- .../firestore/admin/v1/GetFieldRequest.java | 2 + .../firestore/admin/v1/GetIndexRequest.java | 2 + .../admin/v1/ImportDocumentsMetadata.java | 19 + .../admin/v1/ImportDocumentsRequest.java | 4 + .../com/google/firestore/admin/v1/Index.java | 39 + .../admin/v1/IndexOperationMetadata.java | 19 + .../google/firestore/admin/v1/IndexProto.java | 7 +- .../firestore/admin/v1/ListFieldsRequest.java | 8 + .../admin/v1/ListFieldsResponse.java | 7 + .../admin/v1/ListIndexesRequest.java | 8 + .../admin/v1/ListIndexesResponse.java | 7 + .../firestore/admin/v1/LocationProto.java | 5 +- .../firestore/admin/v1/OperationProto.java | 5 +- .../firestore/admin/v1/OperationState.java | 4 + .../google/firestore/admin/v1/Progress.java | 4 + .../admin/v1/UpdateFieldRequest.java | 6 + .../google/firestore/admin/v1/field.proto | 1 + .../firestore/admin/v1/firestore_admin.proto | 1 + .../google/firestore/admin/v1/index.proto | 1 + .../google/firestore/admin/v1/location.proto | 1 + .../google/firestore/admin/v1/operation.proto | 1 + .../com/google/firestore/v1/ArrayValue.java | 5 + .../v1/BatchGetDocumentsRequest.java | 42 +- .../v1/BatchGetDocumentsRequestOrBuilder.java | 6 +- .../v1/BatchGetDocumentsResponse.java | 13 + .../firestore/v1/BatchWriteRequest.java | 1516 ++++++++ .../v1/BatchWriteRequestOrBuilder.java | 172 + .../firestore/v1/BatchWriteResponse.java | 1511 +++++++ .../v1/BatchWriteResponseOrBuilder.java | 148 + .../firestore/v1/BeginTransactionRequest.java | 5 + .../v1/BeginTransactionResponse.java | 2 + .../google/firestore/v1/CommitRequest.java | 9 + .../google/firestore/v1/CommitResponse.java | 8 + .../com/google/firestore/v1/CommonProto.java | 5 +- .../firestore/v1/CreateDocumentRequest.java | 12 + .../java/com/google/firestore/v1/Cursor.java | 7 + .../firestore/v1/DeleteDocumentRequest.java | 5 + .../com/google/firestore/v1/Document.java | 18 + .../google/firestore/v1/DocumentChange.java | 5 + .../google/firestore/v1/DocumentDelete.java | 6 + .../google/firestore/v1/DocumentProto.java | 5 +- .../google/firestore/v1/DocumentRemove.java | 6 + .../firestore/v1/DocumentTransform.java | 45 + .../google/firestore/v1/ExistenceFilter.java | 4 + .../google/firestore/v1/FirestoreProto.java | 334 +- .../firestore/v1/GetDocumentRequest.java | 36 +- .../v1/GetDocumentRequestOrBuilder.java | 6 +- .../v1/ListCollectionIdsRequest.java | 6 + .../v1/ListCollectionIdsResponse.java | 2 + .../firestore/v1/ListDocumentsRequest.java | 46 +- .../v1/ListDocumentsRequestOrBuilder.java | 6 +- .../firestore/v1/ListDocumentsResponse.java | 7 + .../google/firestore/v1/ListenRequest.java | 19 + .../google/firestore/v1/ListenResponse.java | 30 + .../com/google/firestore/v1/MapValue.java | 10 + .../firestore/v1/PartitionQueryRequest.java | 1524 ++++++++ .../v1/PartitionQueryRequestOrBuilder.java | 179 + .../firestore/v1/PartitionQueryResponse.java | 1391 +++++++ .../v1/PartitionQueryResponseOrBuilder.java | 160 + .../com/google/firestore/v1/Precondition.java | 7 + .../com/google/firestore/v1/QueryProto.java | 53 +- .../google/firestore/v1/RollbackRequest.java | 4 + .../google/firestore/v1/RunQueryRequest.java | 45 +- .../v1/RunQueryRequestOrBuilder.java | 6 +- .../google/firestore/v1/RunQueryResponse.java | 10 + .../google/firestore/v1/StructuredQuery.java | 3454 +++++++++-------- .../java/com/google/firestore/v1/Target.java | 31 + .../com/google/firestore/v1/TargetChange.java | 18 + .../firestore/v1/TransactionOptions.java | 20 + .../firestore/v1/UpdateDocumentRequest.java | 12 + .../java/com/google/firestore/v1/Value.java | 34 + .../java/com/google/firestore/v1/Write.java | 25 + .../com/google/firestore/v1/WriteProto.java | 5 +- .../com/google/firestore/v1/WriteRequest.java | 21 + .../google/firestore/v1/WriteResponse.java | 12 + .../com/google/firestore/v1/WriteResult.java | 8 + .../proto/google/firestore/v1/common.proto | 1 + .../proto/google/firestore/v1/document.proto | 1 + .../proto/google/firestore/v1/firestore.proto | 146 +- .../proto/google/firestore/v1/query.proto | 69 +- .../proto/google/firestore/v1/write.proto | 1 + .../google/firestore/v1beta1/ArrayValue.java | 5 + .../v1beta1/BatchGetDocumentsRequest.java | 18 + .../v1beta1/BatchGetDocumentsResponse.java | 13 + .../v1beta1/BeginTransactionRequest.java | 5 + .../v1beta1/BeginTransactionResponse.java | 2 + .../firestore/v1beta1/CommitRequest.java | 9 + .../firestore/v1beta1/CommitResponse.java | 8 + .../google/firestore/v1beta1/CommonProto.java | 5 +- .../v1beta1/CreateDocumentRequest.java | 12 + .../com/google/firestore/v1beta1/Cursor.java | 7 + .../v1beta1/DeleteDocumentRequest.java | 5 + .../google/firestore/v1beta1/Document.java | 18 + .../firestore/v1beta1/DocumentChange.java | 5 + .../firestore/v1beta1/DocumentDelete.java | 6 + .../firestore/v1beta1/DocumentProto.java | 5 +- .../firestore/v1beta1/DocumentRemove.java | 6 + .../firestore/v1beta1/DocumentTransform.java | 45 + .../firestore/v1beta1/ExistenceFilter.java | 4 + .../firestore/v1beta1/FirestoreProto.java | 5 +- .../firestore/v1beta1/GetDocumentRequest.java | 12 + .../v1beta1/ListCollectionIdsRequest.java | 6 + .../v1beta1/ListCollectionIdsResponse.java | 2 + .../v1beta1/ListDocumentsRequest.java | 22 + .../v1beta1/ListDocumentsResponse.java | 7 + .../firestore/v1beta1/ListenRequest.java | 19 + .../firestore/v1beta1/ListenResponse.java | 30 + .../google/firestore/v1beta1/MapValue.java | 10 + .../firestore/v1beta1/Precondition.java | 7 + .../google/firestore/v1beta1/QueryProto.java | 5 +- .../firestore/v1beta1/RollbackRequest.java | 4 + .../firestore/v1beta1/RunQueryRequest.java | 21 + .../firestore/v1beta1/RunQueryResponse.java | 10 + .../firestore/v1beta1/StructuredQuery.java | 112 + .../com/google/firestore/v1beta1/Target.java | 31 + .../firestore/v1beta1/TargetChange.java | 18 + .../firestore/v1beta1/TransactionOptions.java | 20 + .../v1beta1/UpdateDocumentRequest.java | 12 + .../com/google/firestore/v1beta1/Value.java | 34 + .../com/google/firestore/v1beta1/Write.java | 20 + .../google/firestore/v1beta1/WriteProto.java | 5 +- .../firestore/v1beta1/WriteRequest.java | 21 + .../firestore/v1beta1/WriteResponse.java | 12 + .../google/firestore/v1beta1/WriteResult.java | 8 + .../google/firestore/v1beta1/common.proto | 1 + .../google/firestore/v1beta1/document.proto | 1 + .../google/firestore/v1beta1/firestore.proto | 1 + .../google/firestore/v1beta1/query.proto | 1 + .../google/firestore/v1beta1/write.proto | 1 + renovate.json | 3 +- synth.metadata | 10 +- synth.py | 4 +- 160 files changed, 11248 insertions(+), 2001 deletions(-) create mode 100755 .kokoro/populate-secrets.sh create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequest.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequestOrBuilder.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponse.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponseOrBuilder.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequest.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequestOrBuilder.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponse.java create mode 100644 proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponseOrBuilder.java diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 445b4bf82..683022075 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -36,11 +36,14 @@ jobs: JOB_TYPE: test dependencies: runs-on: ubuntu-latest + strategy: + matrix: + java: [8, 11] steps: - uses: actions/checkout@v2 - uses: actions/setup-java@v1 with: - java-version: 8 + java-version: ${{matrix.java}} - run: java -version - run: .kokoro/dependencies.sh linkage-monitor: diff --git a/.kokoro/build.sh b/.kokoro/build.sh index c06d73cce..451821cd1 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -39,7 +39,7 @@ retry_with_backoff 3 10 \ # if GOOGLE_APPLICATION_CREDIENTIALS is specified as a relative path prepend Kokoro root directory onto it if [[ ! -z "${GOOGLE_APPLICATION_CREDENTIALS}" && "${GOOGLE_APPLICATION_CREDENTIALS}" != /* ]]; then - export GOOGLE_APPLICATION_CREDENTIALS=$(realpath ${KOKORO_ROOT}/src/${GOOGLE_APPLICATION_CREDENTIALS}) + export GOOGLE_APPLICATION_CREDENTIALS=$(realpath ${KOKORO_GFILE_DIR}/${GOOGLE_APPLICATION_CREDENTIALS}) fi RETURN_CODE=0 @@ -51,9 +51,7 @@ test) RETURN_CODE=$? ;; lint) - mvn \ - -Penable-samples \ - com.coveo:fmt-maven-plugin:check + mvn com.coveo:fmt-maven-plugin:check RETURN_CODE=$? ;; javadoc) diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index cf3bb4347..cee4f11e7 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -41,8 +41,10 @@ echo "****************** DEPENDENCY LIST COMPLETENESS CHECK *******************" ## Run dependency list completeness check function completenessCheck() { # Output dep list with compile scope generated using the original pom + # Running mvn dependency:list on Java versions that support modules will also include the module of the dependency. + # This is stripped from the output as it is not present in the flattened pom. msg "Generating dependency list using original pom..." - mvn dependency:list -f pom.xml -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | grep -v ':test$' >.org-list.txt + mvn dependency:list -f pom.xml -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e s/\\s--\\smodule.*// | grep -v ':test$' >.org-list.txt # Output dep list generated using the flattened pom (test scope deps are ommitted) msg "Generating dependency list using flattened pom..." diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg index ba0924a97..f60aebf4b 100644 --- a/.kokoro/nightly/integration.cfg +++ b/.kokoro/nightly/integration.cfg @@ -13,29 +13,25 @@ env_vars: { # TODO: remove this after we've migrated all tests and scripts env_vars: { key: "GCLOUD_PROJECT" - value: "gcloud-devel" + value: "java-review" } env_vars: { key: "GOOGLE_CLOUD_PROJECT" - value: "gcloud-devel" + value: "java-review" } env_vars: { - key: "ENABLE_BUILD_COP" - value: "true" + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "secret_manager/java-review_firestore-java-it" } env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + key: "SECRET_MANAGER_KEYS" + value: "java-review_firestore-java-it" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_firestore_it_service_account" - } - } +env_vars: { + key: "ENABLE_BUILD_COP" + value: "true" } diff --git a/.kokoro/nightly/samples.cfg b/.kokoro/nightly/samples.cfg index 20aabd55d..42117b501 100644 --- a/.kokoro/nightly/samples.cfg +++ b/.kokoro/nightly/samples.cfg @@ -14,29 +14,25 @@ env_vars: { # TODO: remove this after we've migrated all tests and scripts env_vars: { key: "GCLOUD_PROJECT" - value: "java-docs-samples-testing" + value: "java-review" } env_vars: { key: "GOOGLE_CLOUD_PROJECT" - value: "java-docs-samples-testing" + value: "java-review" } env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-firestore-samples-secrets" } env_vars: { - key: "ENABLE_BUILD_COP" - value: "true" + key: "SECRET_MANAGER_KEYS" + value: "java-firestore-samples-secrets" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } +env_vars: { + key: "ENABLE_BUILD_COP" + value: "true" } diff --git a/.kokoro/populate-secrets.sh b/.kokoro/populate-secrets.sh new file mode 100755 index 000000000..f52514257 --- /dev/null +++ b/.kokoro/populate-secrets.sh @@ -0,0 +1,43 @@ +#!/bin/bash +# Copyright 2020 Google LLC. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set -eo pipefail + +function now { date +"%Y-%m-%d %H:%M:%S" | tr -d '\n' ;} +function msg { println "$*" >&2 ;} +function println { printf '%s\n' "$(now) $*" ;} + + +# Populates requested secrets set in SECRET_MANAGER_KEYS from service account: +# kokoro-trampoline@cloud-devrel-kokoro-resources.iam.gserviceaccount.com +SECRET_LOCATION="${KOKORO_GFILE_DIR}/secret_manager" +msg "Creating folder on disk for secrets: ${SECRET_LOCATION}" +mkdir -p ${SECRET_LOCATION} +for key in $(echo ${SECRET_MANAGER_KEYS} | sed "s/,/ /g") +do + msg "Retrieving secret ${key}" + docker run --entrypoint=gcloud \ + --volume=${KOKORO_GFILE_DIR}:${KOKORO_GFILE_DIR} \ + gcr.io/google.com/cloudsdktool/cloud-sdk \ + secrets versions access latest \ + --project cloud-devrel-kokoro-resources \ + --secret ${key} > \ + "${SECRET_LOCATION}/${key}" + if [[ $? == 0 ]]; then + msg "Secret written to ${SECRET_LOCATION}/${key}" + else + msg "Error retrieving secret ${key}" + fi +done diff --git a/.kokoro/presubmit/integration.cfg b/.kokoro/presubmit/integration.cfg index b9a89b654..40ef5968d 100644 --- a/.kokoro/presubmit/integration.cfg +++ b/.kokoro/presubmit/integration.cfg @@ -18,14 +18,10 @@ env_vars: { env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_firestore_it_service_account" + value: "secret_manager/java-review_firestore-java-it" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_firestore_it_service_account" - } - } +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-review_firestore-java-it" } diff --git a/.kokoro/presubmit/samples.cfg b/.kokoro/presubmit/samples.cfg index 1171aead0..93d5eadc6 100644 --- a/.kokoro/presubmit/samples.cfg +++ b/.kokoro/presubmit/samples.cfg @@ -14,24 +14,20 @@ env_vars: { # TODO: remove this after we've migrated all tests and scripts env_vars: { key: "GCLOUD_PROJECT" - value: "java-docs-samples-testing" + value: "java-docs-samples-firestore" } env_vars: { key: "GOOGLE_CLOUD_PROJECT" - value: "java-docs-samples-testing" + value: "java-docs-samples-firestore" } env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-firestore-samples-secrets" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-firestore-samples-secrets" } diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh index ba17ce014..9da0f8398 100644 --- a/.kokoro/trampoline.sh +++ b/.kokoro/trampoline.sh @@ -21,4 +21,6 @@ function cleanup() { echo "cleanup"; } trap cleanup EXIT + +$(dirname $0)/populate-secrets.sh # Secret Manager secrets. python3 "${KOKORO_GFILE_DIR}/trampoline_v1.py" diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreClient.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreClient.java index 705c9d537..81925e3a4 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreClient.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreClient.java @@ -32,11 +32,14 @@ import com.google.common.util.concurrent.MoreExecutors; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; import com.google.firestore.v1.CommitResponse; import com.google.firestore.v1.CreateDocumentRequest; +import com.google.firestore.v1.Cursor; import com.google.firestore.v1.DeleteDocumentRequest; import com.google.firestore.v1.Document; import com.google.firestore.v1.DocumentMask; @@ -47,6 +50,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -539,6 +544,67 @@ public final UnaryCallable deleteDocumentCallable( return stub.batchGetDocumentsCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Applies a batch of write operations. + * + *

The BatchWrite method does not apply the write operations atomically and can apply them out + * of order. Method does not allow more than one write per document. Each write succeeds or fails + * independently. See the [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the + * success status of each write. + * + *

If you require an atomically applied set of writes, use + * [Commit][google.firestore.v1.Firestore.Commit] instead. + * + *

Sample code: + * + *


+   * try (FirestoreClient firestoreClient = FirestoreClient.create()) {
+   *   String database = "";
+   *   BatchWriteRequest request = BatchWriteRequest.newBuilder()
+   *     .setDatabase(database)
+   *     .build();
+   *   BatchWriteResponse response = firestoreClient.batchWrite(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final BatchWriteResponse batchWrite(BatchWriteRequest request) { + return batchWriteCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Applies a batch of write operations. + * + *

The BatchWrite method does not apply the write operations atomically and can apply them out + * of order. Method does not allow more than one write per document. Each write succeeds or fails + * independently. See the [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the + * success status of each write. + * + *

If you require an atomically applied set of writes, use + * [Commit][google.firestore.v1.Firestore.Commit] instead. + * + *

Sample code: + * + *


+   * try (FirestoreClient firestoreClient = FirestoreClient.create()) {
+   *   String database = "";
+   *   BatchWriteRequest request = BatchWriteRequest.newBuilder()
+   *     .setDatabase(database)
+   *     .build();
+   *   ApiFuture<BatchWriteResponse> future = firestoreClient.batchWriteCallable().futureCall(request);
+   *   // Do something
+   *   BatchWriteResponse response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable batchWriteCallable() { + return stub.batchWriteCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD /** * Starts a new transaction. @@ -937,6 +1003,94 @@ public final ListCollectionIdsPagedResponse listCollectionIds(ListCollectionIdsR return stub.listCollectionIdsCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Partitions a query by returning partition cursors that can be used to run the query in + * parallel. The returned partition cursors are split points that can be used by RunQuery as + * starting/end points for the query results. + * + *

Sample code: + * + *


+   * try (FirestoreClient firestoreClient = FirestoreClient.create()) {
+   *   String parent = "";
+   *   PartitionQueryRequest request = PartitionQueryRequest.newBuilder()
+   *     .setParent(parent)
+   *     .build();
+   *   for (Cursor element : firestoreClient.partitionQuery(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final PartitionQueryPagedResponse partitionQuery(PartitionQueryRequest request) { + return partitionQueryPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Partitions a query by returning partition cursors that can be used to run the query in + * parallel. The returned partition cursors are split points that can be used by RunQuery as + * starting/end points for the query results. + * + *

Sample code: + * + *


+   * try (FirestoreClient firestoreClient = FirestoreClient.create()) {
+   *   String parent = "";
+   *   PartitionQueryRequest request = PartitionQueryRequest.newBuilder()
+   *     .setParent(parent)
+   *     .build();
+   *   ApiFuture<PartitionQueryPagedResponse> future = firestoreClient.partitionQueryPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (Cursor element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + partitionQueryPagedCallable() { + return stub.partitionQueryPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Partitions a query by returning partition cursors that can be used to run the query in + * parallel. The returned partition cursors are split points that can be used by RunQuery as + * starting/end points for the query results. + * + *

Sample code: + * + *


+   * try (FirestoreClient firestoreClient = FirestoreClient.create()) {
+   *   String parent = "";
+   *   PartitionQueryRequest request = PartitionQueryRequest.newBuilder()
+   *     .setParent(parent)
+   *     .build();
+   *   while (true) {
+   *     PartitionQueryResponse response = firestoreClient.partitionQueryCallable().call(request);
+   *     for (Cursor element : response.getPartitionsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + partitionQueryCallable() { + return stub.partitionQueryCallable(); + } + @Override public final void close() { stub.close(); @@ -1129,4 +1283,85 @@ protected ListCollectionIdsFixedSizeCollection createCollection( return new ListCollectionIdsFixedSizeCollection(pages, collectionSize); } } + + public static class PartitionQueryPagedResponse + extends AbstractPagedListResponse< + PartitionQueryRequest, + PartitionQueryResponse, + Cursor, + PartitionQueryPage, + PartitionQueryFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + PartitionQueryPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public PartitionQueryPagedResponse apply(PartitionQueryPage input) { + return new PartitionQueryPagedResponse(input); + } + }, + MoreExecutors.directExecutor()); + } + + private PartitionQueryPagedResponse(PartitionQueryPage page) { + super(page, PartitionQueryFixedSizeCollection.createEmptyCollection()); + } + } + + public static class PartitionQueryPage + extends AbstractPage< + PartitionQueryRequest, PartitionQueryResponse, Cursor, PartitionQueryPage> { + + private PartitionQueryPage( + PageContext context, + PartitionQueryResponse response) { + super(context, response); + } + + private static PartitionQueryPage createEmptyPage() { + return new PartitionQueryPage(null, null); + } + + @Override + protected PartitionQueryPage createPage( + PageContext context, + PartitionQueryResponse response) { + return new PartitionQueryPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class PartitionQueryFixedSizeCollection + extends AbstractFixedSizeCollection< + PartitionQueryRequest, + PartitionQueryResponse, + Cursor, + PartitionQueryPage, + PartitionQueryFixedSizeCollection> { + + private PartitionQueryFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static PartitionQueryFixedSizeCollection createEmptyCollection() { + return new PartitionQueryFixedSizeCollection(null, 0); + } + + @Override + protected PartitionQueryFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new PartitionQueryFixedSizeCollection(pages, collectionSize); + } + } } diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreSettings.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreSettings.java index fc4d44bb2..a6e012bc4 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreSettings.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/FirestoreSettings.java @@ -17,6 +17,7 @@ import static com.google.cloud.firestore.v1.FirestoreClient.ListCollectionIdsPagedResponse; import static com.google.cloud.firestore.v1.FirestoreClient.ListDocumentsPagedResponse; +import static com.google.cloud.firestore.v1.FirestoreClient.PartitionQueryPagedResponse; import com.google.api.core.ApiFunction; import com.google.api.core.BetaApi; @@ -34,6 +35,8 @@ import com.google.cloud.firestore.v1.stub.FirestoreStubSettings; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; @@ -48,6 +51,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -124,6 +129,11 @@ public UnaryCallSettings deleteDocumentSettings() return ((FirestoreStubSettings) getStubSettings()).batchGetDocumentsSettings(); } + /** Returns the object with the settings used for calls to batchWrite. */ + public UnaryCallSettings batchWriteSettings() { + return ((FirestoreStubSettings) getStubSettings()).batchWriteSettings(); + } + /** Returns the object with the settings used for calls to beginTransaction. */ public UnaryCallSettings beginTransactionSettings() { @@ -162,6 +172,13 @@ public StreamingCallSettings listenSettings() { return ((FirestoreStubSettings) getStubSettings()).listCollectionIdsSettings(); } + /** Returns the object with the settings used for calls to partitionQuery. */ + public PagedCallSettings< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings() { + return ((FirestoreStubSettings) getStubSettings()).partitionQuerySettings(); + } + public static final FirestoreSettings create(FirestoreStubSettings stub) throws IOException { return new FirestoreSettings.Builder(stub.toBuilder()).build(); } @@ -291,6 +308,11 @@ public UnaryCallSettings.Builder deleteDocumentSet return getStubSettingsBuilder().batchGetDocumentsSettings(); } + /** Returns the builder for the settings used for calls to batchWrite. */ + public UnaryCallSettings.Builder batchWriteSettings() { + return getStubSettingsBuilder().batchWriteSettings(); + } + /** Returns the builder for the settings used for calls to beginTransaction. */ public UnaryCallSettings.Builder beginTransactionSettings() { @@ -330,6 +352,13 @@ public StreamingCallSettings.Builder listenSettin return getStubSettingsBuilder().listCollectionIdsSettings(); } + /** Returns the builder for the settings used for calls to partitionQuery. */ + public PagedCallSettings.Builder< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings() { + return getStubSettingsBuilder().partitionQuerySettings(); + } + @Override public FirestoreSettings build() throws IOException { return new FirestoreSettings(this); diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreAdminStubSettings.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreAdminStubSettings.java index a249a4256..e681e64fb 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreAdminStubSettings.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreAdminStubSettings.java @@ -441,8 +441,15 @@ public static class Builder extends StubSettings.BuildernewArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); + StatusCode.Code.DEADLINE_EXCEEDED, + StatusCode.Code.INTERNAL, + StatusCode.Code.UNAVAILABLE))); definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); + definitions.put( + "idempotent2", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); RETRYABLE_CODE_DEFINITIONS = definitions.build(); } @@ -541,22 +548,22 @@ private static Builder initDefaults(Builder builder) { builder .listIndexesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder .getIndexSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder .getFieldSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder .listFieldsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStub.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStub.java index 50456e9ef..83f0613fb 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStub.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStub.java @@ -17,6 +17,7 @@ import static com.google.cloud.firestore.v1.FirestoreClient.ListCollectionIdsPagedResponse; import static com.google.cloud.firestore.v1.FirestoreClient.ListDocumentsPagedResponse; +import static com.google.cloud.firestore.v1.FirestoreClient.PartitionQueryPagedResponse; import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; @@ -25,6 +26,8 @@ import com.google.api.gax.rpc.UnaryCallable; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; @@ -39,6 +42,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -88,6 +93,10 @@ public UnaryCallable deleteDocumentCallable() { throw new UnsupportedOperationException("Not implemented: batchGetDocumentsCallable()"); } + public UnaryCallable batchWriteCallable() { + throw new UnsupportedOperationException("Not implemented: batchWriteCallable()"); + } + public UnaryCallable beginTransactionCallable() { throw new UnsupportedOperationException("Not implemented: beginTransactionCallable()"); @@ -123,6 +132,15 @@ public BidiStreamingCallable listenCallable() { throw new UnsupportedOperationException("Not implemented: listCollectionIdsCallable()"); } + public UnaryCallable + partitionQueryPagedCallable() { + throw new UnsupportedOperationException("Not implemented: partitionQueryPagedCallable()"); + } + + public UnaryCallable partitionQueryCallable() { + throw new UnsupportedOperationException("Not implemented: partitionQueryCallable()"); + } + @Override public abstract void close(); } diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStubSettings.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStubSettings.java index 22f861ec8..394df8ca8 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStubSettings.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/FirestoreStubSettings.java @@ -17,6 +17,7 @@ import static com.google.cloud.firestore.v1.FirestoreClient.ListCollectionIdsPagedResponse; import static com.google.cloud.firestore.v1.FirestoreClient.ListDocumentsPagedResponse; +import static com.google.cloud.firestore.v1.FirestoreClient.PartitionQueryPagedResponse; import com.google.api.core.ApiFunction; import com.google.api.core.ApiFuture; @@ -48,11 +49,14 @@ import com.google.common.collect.Lists; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; import com.google.firestore.v1.CommitResponse; import com.google.firestore.v1.CreateDocumentRequest; +import com.google.firestore.v1.Cursor; import com.google.firestore.v1.DeleteDocumentRequest; import com.google.firestore.v1.Document; import com.google.firestore.v1.GetDocumentRequest; @@ -62,6 +66,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -123,6 +129,7 @@ public class FirestoreStubSettings extends StubSettings { private final UnaryCallSettings deleteDocumentSettings; private final ServerStreamingCallSettings batchGetDocumentsSettings; + private final UnaryCallSettings batchWriteSettings; private final UnaryCallSettings beginTransactionSettings; private final UnaryCallSettings commitSettings; @@ -133,6 +140,9 @@ public class FirestoreStubSettings extends StubSettings { private final PagedCallSettings< ListCollectionIdsRequest, ListCollectionIdsResponse, ListCollectionIdsPagedResponse> listCollectionIdsSettings; + private final PagedCallSettings< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings; /** Returns the object with the settings used for calls to getDocument. */ public UnaryCallSettings getDocumentSettings() { @@ -166,6 +176,11 @@ public UnaryCallSettings deleteDocumentSettings() return batchGetDocumentsSettings; } + /** Returns the object with the settings used for calls to batchWrite. */ + public UnaryCallSettings batchWriteSettings() { + return batchWriteSettings; + } + /** Returns the object with the settings used for calls to beginTransaction. */ public UnaryCallSettings beginTransactionSettings() { @@ -204,6 +219,13 @@ public StreamingCallSettings listenSettings() { return listCollectionIdsSettings; } + /** Returns the object with the settings used for calls to partitionQuery. */ + public PagedCallSettings< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings() { + return partitionQuerySettings; + } + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public FirestoreStub createStub() throws IOException { if (getTransportChannelProvider() @@ -278,6 +300,7 @@ protected FirestoreStubSettings(Builder settingsBuilder) throws IOException { updateDocumentSettings = settingsBuilder.updateDocumentSettings().build(); deleteDocumentSettings = settingsBuilder.deleteDocumentSettings().build(); batchGetDocumentsSettings = settingsBuilder.batchGetDocumentsSettings().build(); + batchWriteSettings = settingsBuilder.batchWriteSettings().build(); beginTransactionSettings = settingsBuilder.beginTransactionSettings().build(); commitSettings = settingsBuilder.commitSettings().build(); rollbackSettings = settingsBuilder.rollbackSettings().build(); @@ -285,6 +308,7 @@ protected FirestoreStubSettings(Builder settingsBuilder) throws IOException { writeSettings = settingsBuilder.writeSettings().build(); listenSettings = settingsBuilder.listenSettings().build(); listCollectionIdsSettings = settingsBuilder.listCollectionIdsSettings().build(); + partitionQuerySettings = settingsBuilder.partitionQuerySettings().build(); } private static final PagedListDescriptor @@ -362,6 +386,43 @@ public Iterable extractResources(ListCollectionIdsResponse payload) { } }; + private static final PagedListDescriptor + PARTITION_QUERY_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public PartitionQueryRequest injectToken(PartitionQueryRequest payload, String token) { + return PartitionQueryRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public PartitionQueryRequest injectPageSize( + PartitionQueryRequest payload, int pageSize) { + return PartitionQueryRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(PartitionQueryRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(PartitionQueryResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(PartitionQueryResponse payload) { + return payload.getPartitionsList() != null + ? payload.getPartitionsList() + : ImmutableList.of(); + } + }; + private static final PagedListResponseFactory< ListDocumentsRequest, ListDocumentsResponse, ListDocumentsPagedResponse> LIST_DOCUMENTS_PAGE_STR_FACT = @@ -398,6 +459,23 @@ public ApiFuture getFuturePagedResponse( } }; + private static final PagedListResponseFactory< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + PARTITION_QUERY_PAGE_STR_FACT = + new PagedListResponseFactory< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + PartitionQueryRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, PARTITION_QUERY_PAGE_STR_DESC, request, context); + return PartitionQueryPagedResponse.createAsync(pageContext, futureResponse); + } + }; + /** Builder for FirestoreStubSettings. */ public static class Builder extends StubSettings.Builder { private final ImmutableList> unaryMethodSettingsBuilders; @@ -412,6 +490,8 @@ public static class Builder extends StubSettings.Builder batchGetDocumentsSettings; + private final UnaryCallSettings.Builder + batchWriteSettings; private final UnaryCallSettings.Builder beginTransactionSettings; private final UnaryCallSettings.Builder commitSettings; @@ -423,6 +503,9 @@ public static class Builder extends StubSettings.Builder listCollectionIdsSettings; + private final PagedCallSettings.Builder< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings; private static final ImmutableMap> RETRYABLE_CODE_DEFINITIONS; @@ -434,8 +517,20 @@ public static class Builder extends StubSettings.BuildernewArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); + StatusCode.Code.DEADLINE_EXCEEDED, + StatusCode.Code.INTERNAL, + StatusCode.Code.UNAVAILABLE))); + definitions.put( + "aborted_unavailable", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.ABORTED, StatusCode.Code.UNAVAILABLE))); definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); + definitions.put( + "idempotent2", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); RETRYABLE_CODE_DEFINITIONS = definitions.build(); } @@ -488,6 +583,8 @@ protected Builder(ClientContext clientContext) { batchGetDocumentsSettings = ServerStreamingCallSettings.newBuilder(); + batchWriteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + beginTransactionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); commitSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -502,6 +599,8 @@ protected Builder(ClientContext clientContext) { listCollectionIdsSettings = PagedCallSettings.newBuilder(LIST_COLLECTION_IDS_PAGE_STR_FACT); + partitionQuerySettings = PagedCallSettings.newBuilder(PARTITION_QUERY_PAGE_STR_FACT); + unaryMethodSettingsBuilders = ImmutableList.>of( getDocumentSettings, @@ -509,10 +608,12 @@ protected Builder(ClientContext clientContext) { createDocumentSettings, updateDocumentSettings, deleteDocumentSettings, + batchWriteSettings, beginTransactionSettings, commitSettings, rollbackSettings, - listCollectionIdsSettings); + listCollectionIdsSettings, + partitionQuerySettings); initDefaults(this); } @@ -530,12 +631,12 @@ private static Builder initDefaults(Builder builder) { builder .getDocumentSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder .listDocumentsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent2")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); builder @@ -558,6 +659,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("streaming")); + builder + .batchWriteSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("aborted_unavailable")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + builder .beginTransactionSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) @@ -580,6 +686,11 @@ private static Builder initDefaults(Builder builder) { builder .listCollectionIdsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .partitionQuerySettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); @@ -595,6 +706,7 @@ protected Builder(FirestoreStubSettings settings) { updateDocumentSettings = settings.updateDocumentSettings.toBuilder(); deleteDocumentSettings = settings.deleteDocumentSettings.toBuilder(); batchGetDocumentsSettings = settings.batchGetDocumentsSettings.toBuilder(); + batchWriteSettings = settings.batchWriteSettings.toBuilder(); beginTransactionSettings = settings.beginTransactionSettings.toBuilder(); commitSettings = settings.commitSettings.toBuilder(); rollbackSettings = settings.rollbackSettings.toBuilder(); @@ -602,6 +714,7 @@ protected Builder(FirestoreStubSettings settings) { writeSettings = settings.writeSettings.toBuilder(); listenSettings = settings.listenSettings.toBuilder(); listCollectionIdsSettings = settings.listCollectionIdsSettings.toBuilder(); + partitionQuerySettings = settings.partitionQuerySettings.toBuilder(); unaryMethodSettingsBuilders = ImmutableList.>of( @@ -610,10 +723,12 @@ protected Builder(FirestoreStubSettings settings) { createDocumentSettings, updateDocumentSettings, deleteDocumentSettings, + batchWriteSettings, beginTransactionSettings, commitSettings, rollbackSettings, - listCollectionIdsSettings); + listCollectionIdsSettings, + partitionQuerySettings); } // NEXT_MAJOR_VER: remove 'throws Exception' @@ -665,6 +780,11 @@ public UnaryCallSettings.Builder deleteDocumentSet return batchGetDocumentsSettings; } + /** Returns the builder for the settings used for calls to batchWrite. */ + public UnaryCallSettings.Builder batchWriteSettings() { + return batchWriteSettings; + } + /** Returns the builder for the settings used for calls to beginTransaction. */ public UnaryCallSettings.Builder beginTransactionSettings() { @@ -704,6 +824,13 @@ public StreamingCallSettings.Builder listenSettin return listCollectionIdsSettings; } + /** Returns the builder for the settings used for calls to partitionQuery. */ + public PagedCallSettings.Builder< + PartitionQueryRequest, PartitionQueryResponse, PartitionQueryPagedResponse> + partitionQuerySettings() { + return partitionQuerySettings; + } + @Override public FirestoreStubSettings build() throws IOException { return new FirestoreStubSettings(this); diff --git a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/GrpcFirestoreStub.java b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/GrpcFirestoreStub.java index 6d525bcd3..14b902f69 100644 --- a/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/GrpcFirestoreStub.java +++ b/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1/stub/GrpcFirestoreStub.java @@ -17,6 +17,7 @@ import static com.google.cloud.firestore.v1.FirestoreClient.ListCollectionIdsPagedResponse; import static com.google.cloud.firestore.v1.FirestoreClient.ListDocumentsPagedResponse; +import static com.google.cloud.firestore.v1.FirestoreClient.PartitionQueryPagedResponse; import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; @@ -31,6 +32,8 @@ import com.google.common.collect.ImmutableMap; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; @@ -45,6 +48,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -123,6 +128,14 @@ public class GrpcFirestoreStub extends FirestoreStub { .setResponseMarshaller( ProtoUtils.marshaller(BatchGetDocumentsResponse.getDefaultInstance())) .build(); + private static final MethodDescriptor + batchWriteMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.firestore.v1.Firestore/BatchWrite") + .setRequestMarshaller(ProtoUtils.marshaller(BatchWriteRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(BatchWriteResponse.getDefaultInstance())) + .build(); private static final MethodDescriptor beginTransactionMethodDescriptor = MethodDescriptor.newBuilder() @@ -179,6 +192,16 @@ public class GrpcFirestoreStub extends FirestoreStub { .setResponseMarshaller( ProtoUtils.marshaller(ListCollectionIdsResponse.getDefaultInstance())) .build(); + private static final MethodDescriptor + partitionQueryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.firestore.v1.Firestore/PartitionQuery") + .setRequestMarshaller( + ProtoUtils.marshaller(PartitionQueryRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(PartitionQueryResponse.getDefaultInstance())) + .build(); private final BackgroundResource backgroundResources; @@ -191,6 +214,7 @@ public class GrpcFirestoreStub extends FirestoreStub { private final UnaryCallable deleteDocumentCallable; private final ServerStreamingCallable batchGetDocumentsCallable; + private final UnaryCallable batchWriteCallable; private final UnaryCallable beginTransactionCallable; private final UnaryCallable commitCallable; @@ -202,6 +226,9 @@ public class GrpcFirestoreStub extends FirestoreStub { listCollectionIdsCallable; private final UnaryCallable listCollectionIdsPagedCallable; + private final UnaryCallable partitionQueryCallable; + private final UnaryCallable + partitionQueryPagedCallable; private final GrpcStubCallableFactory callableFactory; @@ -302,6 +329,19 @@ public Map extract(BatchGetDocumentsRequest request) { } }) .build(); + GrpcCallSettings batchWriteTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(batchWriteMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(BatchWriteRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("database", String.valueOf(request.getDatabase())); + return params.build(); + } + }) + .build(); GrpcCallSettings beginTransactionTransportSettings = GrpcCallSettings.newBuilder() @@ -377,6 +417,20 @@ public Map extract(ListCollectionIdsRequest request) { } }) .build(); + GrpcCallSettings + partitionQueryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(partitionQueryMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(PartitionQueryRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); this.getDocumentCallable = callableFactory.createUnaryCallable( @@ -401,6 +455,9 @@ public Map extract(ListCollectionIdsRequest request) { batchGetDocumentsTransportSettings, settings.batchGetDocumentsSettings(), clientContext); + this.batchWriteCallable = + callableFactory.createUnaryCallable( + batchWriteTransportSettings, settings.batchWriteSettings(), clientContext); this.beginTransactionCallable = callableFactory.createUnaryCallable( beginTransactionTransportSettings, settings.beginTransactionSettings(), clientContext); @@ -429,6 +486,12 @@ public Map extract(ListCollectionIdsRequest request) { listCollectionIdsTransportSettings, settings.listCollectionIdsSettings(), clientContext); + this.partitionQueryCallable = + callableFactory.createUnaryCallable( + partitionQueryTransportSettings, settings.partitionQuerySettings(), clientContext); + this.partitionQueryPagedCallable = + callableFactory.createPagedCallable( + partitionQueryTransportSettings, settings.partitionQuerySettings(), clientContext); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } @@ -463,6 +526,10 @@ public UnaryCallable deleteDocumentCallable() { return batchGetDocumentsCallable; } + public UnaryCallable batchWriteCallable() { + return batchWriteCallable; + } + public UnaryCallable beginTransactionCallable() { return beginTransactionCallable; @@ -498,6 +565,15 @@ public BidiStreamingCallable listenCallable() { return listCollectionIdsCallable; } + public UnaryCallable + partitionQueryPagedCallable() { + return partitionQueryPagedCallable; + } + + public UnaryCallable partitionQueryCallable() { + return partitionQueryCallable; + } + @Override public final void close() { shutdown(); diff --git a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/FirestoreClientTest.java b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/FirestoreClientTest.java index 8600dd0ae..2d55b7d61 100644 --- a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/FirestoreClientTest.java +++ b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/FirestoreClientTest.java @@ -17,6 +17,7 @@ import static com.google.cloud.firestore.v1.FirestoreClient.ListCollectionIdsPagedResponse; import static com.google.cloud.firestore.v1.FirestoreClient.ListDocumentsPagedResponse; +import static com.google.cloud.firestore.v1.FirestoreClient.PartitionQueryPagedResponse; import com.google.api.gax.core.NoCredentialsProvider; import com.google.api.gax.grpc.GaxGrpcProperties; @@ -33,11 +34,14 @@ import com.google.common.collect.Lists; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; import com.google.firestore.v1.CommitResponse; import com.google.firestore.v1.CreateDocumentRequest; +import com.google.firestore.v1.Cursor; import com.google.firestore.v1.DeleteDocumentRequest; import com.google.firestore.v1.Document; import com.google.firestore.v1.DocumentMask; @@ -48,6 +52,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -394,6 +400,46 @@ public void batchGetDocumentsExceptionTest() throws Exception { } } + @Test + @SuppressWarnings("all") + public void batchWriteTest() { + BatchWriteResponse expectedResponse = BatchWriteResponse.newBuilder().build(); + mockFirestore.addResponse(expectedResponse); + + String database = "database1789464955"; + BatchWriteRequest request = BatchWriteRequest.newBuilder().setDatabase(database).build(); + + BatchWriteResponse actualResponse = client.batchWrite(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockFirestore.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + BatchWriteRequest actualRequest = (BatchWriteRequest) actualRequests.get(0); + + Assert.assertEquals(database, actualRequest.getDatabase()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void batchWriteExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockFirestore.addException(exception); + + try { + String database = "database1789464955"; + BatchWriteRequest request = BatchWriteRequest.newBuilder().setDatabase(database).build(); + + client.batchWrite(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + @Test @SuppressWarnings("all") public void beginTransactionTest() { @@ -704,4 +750,54 @@ public void listCollectionIdsExceptionTest() throws Exception { // Expected exception } } + + @Test + @SuppressWarnings("all") + public void partitionQueryTest() { + String nextPageToken = ""; + Cursor partitionsElement = Cursor.newBuilder().build(); + List partitions = Arrays.asList(partitionsElement); + PartitionQueryResponse expectedResponse = + PartitionQueryResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllPartitions(partitions) + .build(); + mockFirestore.addResponse(expectedResponse); + + String parent = "parent-995424086"; + PartitionQueryRequest request = PartitionQueryRequest.newBuilder().setParent(parent).build(); + + PartitionQueryPagedResponse pagedListResponse = client.partitionQuery(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getPartitionsList().get(0), resources.get(0)); + + List actualRequests = mockFirestore.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + PartitionQueryRequest actualRequest = (PartitionQueryRequest) actualRequests.get(0); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void partitionQueryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockFirestore.addException(exception); + + try { + String parent = "parent-995424086"; + PartitionQueryRequest request = PartitionQueryRequest.newBuilder().setParent(parent).build(); + + client.partitionQuery(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } } diff --git a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/MockFirestoreImpl.java b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/MockFirestoreImpl.java index 274978ef3..f095f896f 100644 --- a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/MockFirestoreImpl.java +++ b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1/MockFirestoreImpl.java @@ -18,6 +18,8 @@ import com.google.api.core.BetaApi; import com.google.firestore.v1.BatchGetDocumentsRequest; import com.google.firestore.v1.BatchGetDocumentsResponse; +import com.google.firestore.v1.BatchWriteRequest; +import com.google.firestore.v1.BatchWriteResponse; import com.google.firestore.v1.BeginTransactionRequest; import com.google.firestore.v1.BeginTransactionResponse; import com.google.firestore.v1.CommitRequest; @@ -33,6 +35,8 @@ import com.google.firestore.v1.ListDocumentsResponse; import com.google.firestore.v1.ListenRequest; import com.google.firestore.v1.ListenResponse; +import com.google.firestore.v1.PartitionQueryRequest; +import com.google.firestore.v1.PartitionQueryResponse; import com.google.firestore.v1.RollbackRequest; import com.google.firestore.v1.RunQueryRequest; import com.google.firestore.v1.RunQueryResponse; @@ -211,13 +215,29 @@ public void runQuery(RunQueryRequest request, StreamObserver r } } + @Override + public void partitionQuery( + PartitionQueryRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof PartitionQueryResponse) { + requests.add(request); + responseObserver.onNext((PartitionQueryResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + @Override public StreamObserver write(final StreamObserver responseObserver) { - final Object response = responses.remove(); StreamObserver requestObserver = new StreamObserver() { @Override public void onNext(WriteRequest value) { + requests.add(value); + final Object response = responses.remove(); if (response instanceof WriteResponse) { responseObserver.onNext((WriteResponse) response); } else if (response instanceof Exception) { @@ -243,11 +263,12 @@ public void onCompleted() { @Override public StreamObserver listen( final StreamObserver responseObserver) { - final Object response = responses.remove(); StreamObserver requestObserver = new StreamObserver() { @Override public void onNext(ListenRequest value) { + requests.add(value); + final Object response = responses.remove(); if (response instanceof ListenResponse) { responseObserver.onNext((ListenResponse) response); } else if (response instanceof Exception) { @@ -286,6 +307,21 @@ public void listCollectionIds( } } + @Override + public void batchWrite( + BatchWriteRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof BatchWriteResponse) { + requests.add(request); + responseObserver.onNext((BatchWriteResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + @Override public void createDocument( CreateDocumentRequest request, StreamObserver responseObserver) { diff --git a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1beta1/MockFirestoreImpl.java b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1beta1/MockFirestoreImpl.java index c4e8e65a3..1d5f83aa6 100644 --- a/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1beta1/MockFirestoreImpl.java +++ b/google-cloud-firestore/src/test/java/com/google/cloud/firestore/v1beta1/MockFirestoreImpl.java @@ -228,11 +228,12 @@ public void runQuery(RunQueryRequest request, StreamObserver r @Override public StreamObserver write(final StreamObserver responseObserver) { - final Object response = responses.remove(); StreamObserver requestObserver = new StreamObserver() { @Override public void onNext(WriteRequest value) { + requests.add(value); + final Object response = responses.remove(); if (response instanceof WriteResponse) { responseObserver.onNext((WriteResponse) response); } else if (response instanceof Exception) { @@ -258,11 +259,12 @@ public void onCompleted() { @Override public StreamObserver listen( final StreamObserver responseObserver) { - final Object response = responses.remove(); StreamObserver requestObserver = new StreamObserver() { @Override public void onNext(ListenRequest value) { + requests.add(value); + final Object response = responses.remove(); if (response instanceof ListenResponse) { responseObserver.onNext((ListenResponse) response); } else if (response instanceof Exception) { diff --git a/grpc-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreGrpc.java b/grpc-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreGrpc.java index 3f2b038e3..bf49895d2 100644 --- a/grpc-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreGrpc.java +++ b/grpc-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreGrpc.java @@ -431,6 +431,50 @@ private FirestoreGrpc() {} return getRunQueryMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.firestore.v1.PartitionQueryRequest, + com.google.firestore.v1.PartitionQueryResponse> + getPartitionQueryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "PartitionQuery", + requestType = com.google.firestore.v1.PartitionQueryRequest.class, + responseType = com.google.firestore.v1.PartitionQueryResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.firestore.v1.PartitionQueryRequest, + com.google.firestore.v1.PartitionQueryResponse> + getPartitionQueryMethod() { + io.grpc.MethodDescriptor< + com.google.firestore.v1.PartitionQueryRequest, + com.google.firestore.v1.PartitionQueryResponse> + getPartitionQueryMethod; + if ((getPartitionQueryMethod = FirestoreGrpc.getPartitionQueryMethod) == null) { + synchronized (FirestoreGrpc.class) { + if ((getPartitionQueryMethod = FirestoreGrpc.getPartitionQueryMethod) == null) { + FirestoreGrpc.getPartitionQueryMethod = + getPartitionQueryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "PartitionQuery")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.firestore.v1.PartitionQueryRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.firestore.v1.PartitionQueryResponse.getDefaultInstance())) + .setSchemaDescriptor(new FirestoreMethodDescriptorSupplier("PartitionQuery")) + .build(); + } + } + } + return getPartitionQueryMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.firestore.v1.WriteRequest, com.google.firestore.v1.WriteResponse> getWriteMethod; @@ -559,6 +603,47 @@ private FirestoreGrpc() {} return getListCollectionIdsMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.firestore.v1.BatchWriteRequest, com.google.firestore.v1.BatchWriteResponse> + getBatchWriteMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "BatchWrite", + requestType = com.google.firestore.v1.BatchWriteRequest.class, + responseType = com.google.firestore.v1.BatchWriteResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.firestore.v1.BatchWriteRequest, com.google.firestore.v1.BatchWriteResponse> + getBatchWriteMethod() { + io.grpc.MethodDescriptor< + com.google.firestore.v1.BatchWriteRequest, com.google.firestore.v1.BatchWriteResponse> + getBatchWriteMethod; + if ((getBatchWriteMethod = FirestoreGrpc.getBatchWriteMethod) == null) { + synchronized (FirestoreGrpc.class) { + if ((getBatchWriteMethod = FirestoreGrpc.getBatchWriteMethod) == null) { + FirestoreGrpc.getBatchWriteMethod = + getBatchWriteMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "BatchWrite")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.firestore.v1.BatchWriteRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.firestore.v1.BatchWriteResponse.getDefaultInstance())) + .setSchemaDescriptor(new FirestoreMethodDescriptorSupplier("BatchWrite")) + .build(); + } + } + } + return getBatchWriteMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.firestore.v1.CreateDocumentRequest, com.google.firestore.v1.Document> getCreateDocumentMethod; @@ -777,6 +862,22 @@ public void runQuery( asyncUnimplementedUnaryCall(getRunQueryMethod(), responseObserver); } + /** + * + * + *
+     * Partitions a query by returning partition cursors that can be used to run
+     * the query in parallel. The returned partition cursors are split points that
+     * can be used by RunQuery as starting/end points for the query results.
+     * 
+ */ + public void partitionQuery( + com.google.firestore.v1.PartitionQueryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getPartitionQueryMethod(), responseObserver); + } + /** * * @@ -815,6 +916,25 @@ public void listCollectionIds( asyncUnimplementedUnaryCall(getListCollectionIdsMethod(), responseObserver); } + /** + * + * + *
+     * Applies a batch of write operations.
+     * The BatchWrite method does not apply the write operations atomically
+     * and can apply them out of order. Method does not allow more than one write
+     * per document. Each write succeeds or fails independently. See the
+     * [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the success status of each write.
+     * If you require an atomically applied set of writes, use
+     * [Commit][google.firestore.v1.Firestore.Commit] instead.
+     * 
+ */ + public void batchWrite( + com.google.firestore.v1.BatchWriteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getBatchWriteMethod(), responseObserver); + } + /** * * @@ -888,6 +1008,13 @@ public final io.grpc.ServerServiceDefinition bindService() { new MethodHandlers< com.google.firestore.v1.RunQueryRequest, com.google.firestore.v1.RunQueryResponse>(this, METHODID_RUN_QUERY))) + .addMethod( + getPartitionQueryMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.firestore.v1.PartitionQueryRequest, + com.google.firestore.v1.PartitionQueryResponse>( + this, METHODID_PARTITION_QUERY))) .addMethod( getWriteMethod(), asyncBidiStreamingCall( @@ -907,6 +1034,12 @@ public final io.grpc.ServerServiceDefinition bindService() { com.google.firestore.v1.ListCollectionIdsRequest, com.google.firestore.v1.ListCollectionIdsResponse>( this, METHODID_LIST_COLLECTION_IDS))) + .addMethod( + getBatchWriteMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.firestore.v1.BatchWriteRequest, + com.google.firestore.v1.BatchWriteResponse>(this, METHODID_BATCH_WRITE))) .addMethod( getCreateDocumentMethod(), asyncUnaryCall( @@ -1083,6 +1216,25 @@ public void runQuery( getChannel().newCall(getRunQueryMethod(), getCallOptions()), request, responseObserver); } + /** + * + * + *
+     * Partitions a query by returning partition cursors that can be used to run
+     * the query in parallel. The returned partition cursors are split points that
+     * can be used by RunQuery as starting/end points for the query results.
+     * 
+ */ + public void partitionQuery( + com.google.firestore.v1.PartitionQueryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getPartitionQueryMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -1126,6 +1278,26 @@ public void listCollectionIds( responseObserver); } + /** + * + * + *
+     * Applies a batch of write operations.
+     * The BatchWrite method does not apply the write operations atomically
+     * and can apply them out of order. Method does not allow more than one write
+     * per document. Each write succeeds or fails independently. See the
+     * [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the success status of each write.
+     * If you require an atomically applied set of writes, use
+     * [Commit][google.firestore.v1.Firestore.Commit] instead.
+     * 
+ */ + public void batchWrite( + com.google.firestore.v1.BatchWriteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnaryCall( + getChannel().newCall(getBatchWriteMethod(), getCallOptions()), request, responseObserver); + } + /** * * @@ -1280,6 +1452,20 @@ public java.util.Iterator runQuery( getChannel(), getRunQueryMethod(), getCallOptions(), request); } + /** + * + * + *
+     * Partitions a query by returning partition cursors that can be used to run
+     * the query in parallel. The returned partition cursors are split points that
+     * can be used by RunQuery as starting/end points for the query results.
+     * 
+ */ + public com.google.firestore.v1.PartitionQueryResponse partitionQuery( + com.google.firestore.v1.PartitionQueryRequest request) { + return blockingUnaryCall(getChannel(), getPartitionQueryMethod(), getCallOptions(), request); + } + /** * * @@ -1293,6 +1479,24 @@ public com.google.firestore.v1.ListCollectionIdsResponse listCollectionIds( getChannel(), getListCollectionIdsMethod(), getCallOptions(), request); } + /** + * + * + *
+     * Applies a batch of write operations.
+     * The BatchWrite method does not apply the write operations atomically
+     * and can apply them out of order. Method does not allow more than one write
+     * per document. Each write succeeds or fails independently. See the
+     * [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the success status of each write.
+     * If you require an atomically applied set of writes, use
+     * [Commit][google.firestore.v1.Firestore.Commit] instead.
+     * 
+ */ + public com.google.firestore.v1.BatchWriteResponse batchWrite( + com.google.firestore.v1.BatchWriteRequest request) { + return blockingUnaryCall(getChannel(), getBatchWriteMethod(), getCallOptions(), request); + } + /** * * @@ -1422,6 +1626,22 @@ public com.google.common.util.concurrent.ListenableFuture + * Partitions a query by returning partition cursors that can be used to run + * the query in parallel. The returned partition cursors are split points that + * can be used by RunQuery as starting/end points for the query results. + * + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.firestore.v1.PartitionQueryResponse> + partitionQuery(com.google.firestore.v1.PartitionQueryRequest request) { + return futureUnaryCall( + getChannel().newCall(getPartitionQueryMethod(), getCallOptions()), request); + } + /** * * @@ -1436,6 +1656,26 @@ public com.google.common.util.concurrent.ListenableFuture + * Applies a batch of write operations. + * The BatchWrite method does not apply the write operations atomically + * and can apply them out of order. Method does not allow more than one write + * per document. Each write succeeds or fails independently. See the + * [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the success status of each write. + * If you require an atomically applied set of writes, use + * [Commit][google.firestore.v1.Firestore.Commit] instead. + * + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.firestore.v1.BatchWriteResponse> + batchWrite(com.google.firestore.v1.BatchWriteRequest request) { + return futureUnaryCall( + getChannel().newCall(getBatchWriteMethod(), getCallOptions()), request); + } + /** * * @@ -1459,10 +1699,12 @@ public com.google.common.util.concurrent.ListenableFuture implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -1531,12 +1773,24 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_PARTITION_QUERY: + serviceImpl.partitionQuery( + (com.google.firestore.v1.PartitionQueryRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; case METHODID_LIST_COLLECTION_IDS: serviceImpl.listCollectionIds( (com.google.firestore.v1.ListCollectionIdsRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_BATCH_WRITE: + serviceImpl.batchWrite( + (com.google.firestore.v1.BatchWriteRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; case METHODID_CREATE_DOCUMENT: serviceImpl.createDocument( (com.google.firestore.v1.CreateDocumentRequest) request, @@ -1625,9 +1879,11 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getCommitMethod()) .addMethod(getRollbackMethod()) .addMethod(getRunQueryMethod()) + .addMethod(getPartitionQueryMethod()) .addMethod(getWriteMethod()) .addMethod(getListenMethod()) .addMethod(getListCollectionIdsMethod()) + .addMethod(getBatchWriteMethod()) .addMethod(getCreateDocumentMethod()) .build(); } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/CreateIndexRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/CreateIndexRequest.java index 25f857841..982b0530a 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/CreateIndexRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/CreateIndexRequest.java @@ -143,6 +143,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -168,6 +169,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -194,6 +196,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return Whether the index field is set. */ + @java.lang.Override public boolean hasIndex() { return index_ != null; } @@ -209,6 +212,7 @@ public boolean hasIndex() { * * @return The index. */ + @java.lang.Override public com.google.firestore.admin.v1.Index getIndex() { return index_ == null ? com.google.firestore.admin.v1.Index.getDefaultInstance() : index_; } @@ -222,6 +226,7 @@ public com.google.firestore.admin.v1.Index getIndex() { * .google.firestore.admin.v1.Index index = 2 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.admin.v1.IndexOrBuilder getIndexOrBuilder() { return getIndex(); } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/DeleteIndexRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/DeleteIndexRequest.java index 8f6e54a5b..352a712e4 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/DeleteIndexRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/DeleteIndexRequest.java @@ -127,6 +127,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -152,6 +153,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsMetadata.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsMetadata.java index 71ecbe137..845d21bac 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsMetadata.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsMetadata.java @@ -210,6 +210,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the startTime field is set. */ + @java.lang.Override public boolean hasStartTime() { return startTime_ != null; } @@ -224,6 +225,7 @@ public boolean hasStartTime() { * * @return The startTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getStartTime() { return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; } @@ -236,6 +238,7 @@ public com.google.protobuf.Timestamp getStartTime() { * * .google.protobuf.Timestamp start_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { return getStartTime(); } @@ -254,6 +257,7 @@ public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { * * @return Whether the endTime field is set. */ + @java.lang.Override public boolean hasEndTime() { return endTime_ != null; } @@ -269,6 +273,7 @@ public boolean hasEndTime() { * * @return The endTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getEndTime() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } @@ -282,6 +287,7 @@ public com.google.protobuf.Timestamp getEndTime() { * * .google.protobuf.Timestamp end_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return getEndTime(); } @@ -299,6 +305,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The enum numeric value on the wire for operationState. */ + @java.lang.Override public int getOperationStateValue() { return operationState_; } @@ -313,6 +320,7 @@ public int getOperationStateValue() { * * @return The operationState. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getOperationState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = @@ -333,6 +341,7 @@ public com.google.firestore.admin.v1.OperationState getOperationState() { * * @return Whether the progressDocuments field is set. */ + @java.lang.Override public boolean hasProgressDocuments() { return progressDocuments_ != null; } @@ -347,6 +356,7 @@ public boolean hasProgressDocuments() { * * @return The progressDocuments. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressDocuments() { return progressDocuments_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -361,6 +371,7 @@ public com.google.firestore.admin.v1.Progress getProgressDocuments() { * * .google.firestore.admin.v1.Progress progress_documents = 4; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBuilder() { return getProgressDocuments(); } @@ -378,6 +389,7 @@ public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBui * * @return Whether the progressBytes field is set. */ + @java.lang.Override public boolean hasProgressBytes() { return progressBytes_ != null; } @@ -392,6 +404,7 @@ public boolean hasProgressBytes() { * * @return The progressBytes. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressBytes() { return progressBytes_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -406,6 +419,7 @@ public com.google.firestore.admin.v1.Progress getProgressBytes() { * * .google.firestore.admin.v1.Progress progress_bytes = 5; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressBytesOrBuilder() { return getProgressBytes(); } @@ -484,6 +498,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The outputUriPrefix. */ + @java.lang.Override public java.lang.String getOutputUriPrefix() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { @@ -506,6 +521,7 @@ public java.lang.String getOutputUriPrefix() { * * @return The bytes for outputUriPrefix. */ + @java.lang.Override public com.google.protobuf.ByteString getOutputUriPrefixBytes() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { @@ -1382,6 +1398,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The enum numeric value on the wire for operationState. */ + @java.lang.Override public int getOperationStateValue() { return operationState_; } @@ -1398,6 +1415,7 @@ public int getOperationStateValue() { * @return This builder for chaining. */ public Builder setOperationStateValue(int value) { + operationState_ = value; onChanged(); return this; @@ -1413,6 +1431,7 @@ public Builder setOperationStateValue(int value) { * * @return The operationState. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getOperationState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsRequest.java index 4d6e5f16a..3cd1b155e 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsRequest.java @@ -150,6 +150,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -175,6 +176,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -268,6 +270,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The outputUriPrefix. */ + @java.lang.Override public java.lang.String getOutputUriPrefix() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { @@ -297,6 +300,7 @@ public java.lang.String getOutputUriPrefix() { * * @return The bytes for outputUriPrefix. */ + @java.lang.Override public com.google.protobuf.ByteString getOutputUriPrefixBytes() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsResponse.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsResponse.java index c70c184a6..8fd633b7e 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsResponse.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ExportDocumentsResponse.java @@ -126,6 +126,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The outputUriPrefix. */ + @java.lang.Override public java.lang.String getOutputUriPrefix() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { @@ -150,6 +151,7 @@ public java.lang.String getOutputUriPrefix() { * * @return The bytes for outputUriPrefix. */ + @java.lang.Override public com.google.protobuf.ByteString getOutputUriPrefixBytes() { java.lang.Object ref = outputUriPrefix_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Field.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Field.java index 0cb8194e8..5632b37cb 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Field.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Field.java @@ -379,6 +379,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public java.util.List getIndexesList() { return indexes_; } @@ -391,6 +392,7 @@ public java.util.List getIndexesList() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public java.util.List getIndexesOrBuilderList() { return indexes_; @@ -404,6 +406,7 @@ public java.util.List getIndexesList() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public int getIndexesCount() { return indexes_.size(); } @@ -416,6 +419,7 @@ public int getIndexesCount() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.Index getIndexes(int index) { return indexes_.get(index); } @@ -428,6 +432,7 @@ public com.google.firestore.admin.v1.Index getIndexes(int index) { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.IndexOrBuilder getIndexesOrBuilder(int index) { return indexes_.get(index); } @@ -447,6 +452,7 @@ public com.google.firestore.admin.v1.IndexOrBuilder getIndexesOrBuilder(int inde * * @return The usesAncestorConfig. */ + @java.lang.Override public boolean getUsesAncestorConfig() { return usesAncestorConfig_; } @@ -467,6 +473,7 @@ public boolean getUsesAncestorConfig() { * * @return The ancestorField. */ + @java.lang.Override public java.lang.String getAncestorField() { java.lang.Object ref = ancestorField_; if (ref instanceof java.lang.String) { @@ -492,6 +499,7 @@ public java.lang.String getAncestorField() { * * @return The bytes for ancestorField. */ + @java.lang.Override public com.google.protobuf.ByteString getAncestorFieldBytes() { java.lang.Object ref = ancestorField_; if (ref instanceof java.lang.String) { @@ -521,6 +529,7 @@ public com.google.protobuf.ByteString getAncestorFieldBytes() { * * @return The reverting. */ + @java.lang.Override public boolean getReverting() { return reverting_; } @@ -1297,6 +1306,7 @@ public java.util.List getIndexesBui * * @return The usesAncestorConfig. */ + @java.lang.Override public boolean getUsesAncestorConfig() { return usesAncestorConfig_; } @@ -1477,6 +1487,7 @@ public Builder setAncestorFieldBytes(com.google.protobuf.ByteString value) { * * @return The reverting. */ + @java.lang.Override public boolean getReverting() { return reverting_; } @@ -1610,6 +1621,7 @@ public com.google.firestore.admin.v1.Field.IndexConfig getDefaultInstanceForType * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -1653,6 +1665,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -1681,6 +1694,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * @return Whether the indexConfig field is set. */ + @java.lang.Override public boolean hasIndexConfig() { return indexConfig_ != null; } @@ -1698,6 +1712,7 @@ public boolean hasIndexConfig() { * * @return The indexConfig. */ + @java.lang.Override public com.google.firestore.admin.v1.Field.IndexConfig getIndexConfig() { return indexConfig_ == null ? com.google.firestore.admin.v1.Field.IndexConfig.getDefaultInstance() @@ -1715,6 +1730,7 @@ public com.google.firestore.admin.v1.Field.IndexConfig getIndexConfig() { * * .google.firestore.admin.v1.Field.IndexConfig index_config = 2; */ + @java.lang.Override public com.google.firestore.admin.v1.Field.IndexConfigOrBuilder getIndexConfigOrBuilder() { return getIndexConfig(); } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldOperationMetadata.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldOperationMetadata.java index 4a179544a..a5c390bbb 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldOperationMetadata.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldOperationMetadata.java @@ -503,6 +503,10 @@ public ChangeType findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -552,6 +556,7 @@ private ChangeType(int value) { * * @return The enum numeric value on the wire for changeType. */ + @java.lang.Override public int getChangeTypeValue() { return changeType_; } @@ -568,6 +573,7 @@ public int getChangeTypeValue() { * * @return The changeType. */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta.ChangeType getChangeType() { @SuppressWarnings("deprecation") @@ -593,6 +599,7 @@ public int getChangeTypeValue() { * * @return Whether the index field is set. */ + @java.lang.Override public boolean hasIndex() { return index_ != null; } @@ -607,6 +614,7 @@ public boolean hasIndex() { * * @return The index. */ + @java.lang.Override public com.google.firestore.admin.v1.Index getIndex() { return index_ == null ? com.google.firestore.admin.v1.Index.getDefaultInstance() : index_; } @@ -619,6 +627,7 @@ public com.google.firestore.admin.v1.Index getIndex() { * * .google.firestore.admin.v1.Index index = 2; */ + @java.lang.Override public com.google.firestore.admin.v1.IndexOrBuilder getIndexOrBuilder() { return getIndex(); } @@ -1004,6 +1013,7 @@ public Builder mergeFrom( * * @return The enum numeric value on the wire for changeType. */ + @java.lang.Override public int getChangeTypeValue() { return changeType_; } @@ -1022,6 +1032,7 @@ public int getChangeTypeValue() { * @return This builder for chaining. */ public Builder setChangeTypeValue(int value) { + changeType_ = value; onChanged(); return this; @@ -1039,6 +1050,7 @@ public Builder setChangeTypeValue(int value) { * * @return The changeType. */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta.ChangeType getChangeType() { @SuppressWarnings("deprecation") @@ -1344,6 +1356,7 @@ public com.google.protobuf.Parser getParserForType() { * * @return Whether the startTime field is set. */ + @java.lang.Override public boolean hasStartTime() { return startTime_ != null; } @@ -1358,6 +1371,7 @@ public boolean hasStartTime() { * * @return The startTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getStartTime() { return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; } @@ -1370,6 +1384,7 @@ public com.google.protobuf.Timestamp getStartTime() { * * .google.protobuf.Timestamp start_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { return getStartTime(); } @@ -1388,6 +1403,7 @@ public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { * * @return Whether the endTime field is set. */ + @java.lang.Override public boolean hasEndTime() { return endTime_ != null; } @@ -1403,6 +1419,7 @@ public boolean hasEndTime() { * * @return The endTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getEndTime() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } @@ -1416,6 +1433,7 @@ public com.google.protobuf.Timestamp getEndTime() { * * .google.protobuf.Timestamp end_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return getEndTime(); } @@ -1434,6 +1452,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The field. */ + @java.lang.Override public java.lang.String getField() { java.lang.Object ref = field_; if (ref instanceof java.lang.String) { @@ -1457,6 +1476,7 @@ public java.lang.String getField() { * * @return The bytes for field. */ + @java.lang.Override public com.google.protobuf.ByteString getFieldBytes() { java.lang.Object ref = field_; if (ref instanceof java.lang.String) { @@ -1484,6 +1504,7 @@ public com.google.protobuf.ByteString getFieldBytes() { * repeated .google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta index_config_deltas = 4; * */ + @java.lang.Override public java.util.List getIndexConfigDeltasList() { return indexConfigDeltas_; @@ -1500,6 +1521,7 @@ public com.google.protobuf.ByteString getFieldBytes() { * repeated .google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta index_config_deltas = 4; * */ + @java.lang.Override public java.util.List< ? extends com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDeltaOrBuilder> getIndexConfigDeltasOrBuilderList() { @@ -1517,6 +1539,7 @@ public com.google.protobuf.ByteString getFieldBytes() { * repeated .google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta index_config_deltas = 4; * */ + @java.lang.Override public int getIndexConfigDeltasCount() { return indexConfigDeltas_.size(); } @@ -1532,6 +1555,7 @@ public int getIndexConfigDeltasCount() { * repeated .google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta index_config_deltas = 4; * */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta getIndexConfigDeltas( int index) { return indexConfigDeltas_.get(index); @@ -1548,6 +1572,7 @@ public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta get * repeated .google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta index_config_deltas = 4; * */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDeltaOrBuilder getIndexConfigDeltasOrBuilder(int index) { return indexConfigDeltas_.get(index); @@ -1566,6 +1591,7 @@ public com.google.firestore.admin.v1.FieldOperationMetadata.IndexConfigDelta get * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -1580,6 +1606,7 @@ public int getStateValue() { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = @@ -1600,6 +1627,7 @@ public com.google.firestore.admin.v1.OperationState getState() { * * @return Whether the progressDocuments field is set. */ + @java.lang.Override public boolean hasProgressDocuments() { return progressDocuments_ != null; } @@ -1614,6 +1642,7 @@ public boolean hasProgressDocuments() { * * @return The progressDocuments. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressDocuments() { return progressDocuments_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -1628,6 +1657,7 @@ public com.google.firestore.admin.v1.Progress getProgressDocuments() { * * .google.firestore.admin.v1.Progress progress_documents = 6; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBuilder() { return getProgressDocuments(); } @@ -1645,6 +1675,7 @@ public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBui * * @return Whether the progressBytes field is set. */ + @java.lang.Override public boolean hasProgressBytes() { return progressBytes_ != null; } @@ -1659,6 +1690,7 @@ public boolean hasProgressBytes() { * * @return The progressBytes. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressBytes() { return progressBytes_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -1673,6 +1705,7 @@ public com.google.firestore.admin.v1.Progress getProgressBytes() { * * .google.firestore.admin.v1.Progress progress_bytes = 7; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressBytesOrBuilder() { return getProgressBytes(); } @@ -3108,6 +3141,7 @@ public Builder removeIndexConfigDeltas(int index) { * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -3124,6 +3158,7 @@ public int getStateValue() { * @return This builder for chaining. */ public Builder setStateValue(int value) { + state_ = value; onChanged(); return this; @@ -3139,6 +3174,7 @@ public Builder setStateValue(int value) { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldProto.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldProto.java index 58a1e43bc..ec689537b 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldProto.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FieldProto.java @@ -56,12 +56,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "tor_field\030\003 \001(\t\022\021\n\treverting\030\004 \001(\010:y\352Av\n" + "\036firestore.googleapis.com/Field\022Tproject" + "s/{project}/databases/{database}/collect" - + "ionGroups/{collection}/fields/{field}B\270\001" + + "ionGroups/{collection}/fields/{field}B\336\001" + "\n\035com.google.firestore.admin.v1B\nFieldPr" + "otoP\001Z>google.golang.org/genproto/google" + "apis/firestore/admin/v1;admin\242\002\004GCFS\252\002\037G" + "oogle.Cloud.Firestore.Admin.V1\312\002\037Google\\" - + "Cloud\\Firestore\\Admin\\V1b\006proto3" + + "Cloud\\Firestore\\Admin\\V1\352\002#Google::Cloud" + + "::Firestore::Admin::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FirestoreAdminProto.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FirestoreAdminProto.java index b0fd30148..5045f16ad 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FirestoreAdminProto.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/FirestoreAdminProto.java @@ -168,17 +168,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ata\032v\312A\030firestore.googleapis.com\322AXhttps" + "://www.googleapis.com/auth/cloud-platfor" + "m,https://www.googleapis.com/auth/datast" - + "oreB\204\003\n\035com.google.firestore.admin.v1B\023F" + + "oreB\252\003\n\035com.google.firestore.admin.v1B\023F" + "irestoreAdminProtoP\001Z>google.golang.org/" + "genproto/googleapis/firestore/admin/v1;a" + "dmin\242\002\004GCFS\252\002\037Google.Cloud.Firestore.Adm" + "in.V1\312\002\037Google\\Cloud\\Firestore\\Admin\\V1\352" - + "AL\n!firestore.googleapis.com/Database\022\'p" - + "rojects/{project}/databases/{database}\352A" - + "q\n(firestore.googleapis.com/CollectionGr" - + "oup\022Eprojects/{project}/databases/{datab" - + "ase}/collectionGroups/{collection}b\006prot" - + "o3" + + "\002#Google::Cloud::Firestore::Admin::V1\352AL" + + "\n!firestore.googleapis.com/Database\022\'pro" + + "jects/{project}/databases/{database}\352Aq\n" + + "(firestore.googleapis.com/CollectionGrou" + + "p\022Eprojects/{project}/databases/{databas" + + "e}/collectionGroups/{collection}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetFieldRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetFieldRequest.java index 606776fad..95b8a23f3 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetFieldRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetFieldRequest.java @@ -127,6 +127,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -152,6 +153,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetIndexRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetIndexRequest.java index 2c09e7639..2fcb9802e 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetIndexRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/GetIndexRequest.java @@ -127,6 +127,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -152,6 +153,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsMetadata.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsMetadata.java index c7877695a..f693fb462 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsMetadata.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsMetadata.java @@ -210,6 +210,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the startTime field is set. */ + @java.lang.Override public boolean hasStartTime() { return startTime_ != null; } @@ -224,6 +225,7 @@ public boolean hasStartTime() { * * @return The startTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getStartTime() { return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; } @@ -236,6 +238,7 @@ public com.google.protobuf.Timestamp getStartTime() { * * .google.protobuf.Timestamp start_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { return getStartTime(); } @@ -254,6 +257,7 @@ public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { * * @return Whether the endTime field is set. */ + @java.lang.Override public boolean hasEndTime() { return endTime_ != null; } @@ -269,6 +273,7 @@ public boolean hasEndTime() { * * @return The endTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getEndTime() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } @@ -282,6 +287,7 @@ public com.google.protobuf.Timestamp getEndTime() { * * .google.protobuf.Timestamp end_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return getEndTime(); } @@ -299,6 +305,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The enum numeric value on the wire for operationState. */ + @java.lang.Override public int getOperationStateValue() { return operationState_; } @@ -313,6 +320,7 @@ public int getOperationStateValue() { * * @return The operationState. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getOperationState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = @@ -333,6 +341,7 @@ public com.google.firestore.admin.v1.OperationState getOperationState() { * * @return Whether the progressDocuments field is set. */ + @java.lang.Override public boolean hasProgressDocuments() { return progressDocuments_ != null; } @@ -347,6 +356,7 @@ public boolean hasProgressDocuments() { * * @return The progressDocuments. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressDocuments() { return progressDocuments_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -361,6 +371,7 @@ public com.google.firestore.admin.v1.Progress getProgressDocuments() { * * .google.firestore.admin.v1.Progress progress_documents = 4; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBuilder() { return getProgressDocuments(); } @@ -378,6 +389,7 @@ public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBui * * @return Whether the progressBytes field is set. */ + @java.lang.Override public boolean hasProgressBytes() { return progressBytes_ != null; } @@ -392,6 +404,7 @@ public boolean hasProgressBytes() { * * @return The progressBytes. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressBytes() { return progressBytes_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -406,6 +419,7 @@ public com.google.firestore.admin.v1.Progress getProgressBytes() { * * .google.firestore.admin.v1.Progress progress_bytes = 5; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressBytesOrBuilder() { return getProgressBytes(); } @@ -484,6 +498,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The inputUriPrefix. */ + @java.lang.Override public java.lang.String getInputUriPrefix() { java.lang.Object ref = inputUriPrefix_; if (ref instanceof java.lang.String) { @@ -506,6 +521,7 @@ public java.lang.String getInputUriPrefix() { * * @return The bytes for inputUriPrefix. */ + @java.lang.Override public com.google.protobuf.ByteString getInputUriPrefixBytes() { java.lang.Object ref = inputUriPrefix_; if (ref instanceof java.lang.String) { @@ -1382,6 +1398,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The enum numeric value on the wire for operationState. */ + @java.lang.Override public int getOperationStateValue() { return operationState_; } @@ -1398,6 +1415,7 @@ public int getOperationStateValue() { * @return This builder for chaining. */ public Builder setOperationStateValue(int value) { + operationState_ = value; onChanged(); return this; @@ -1413,6 +1431,7 @@ public Builder setOperationStateValue(int value) { * * @return The operationState. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getOperationState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsRequest.java index 74d86152b..dee99b6b4 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ImportDocumentsRequest.java @@ -150,6 +150,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -175,6 +176,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -269,6 +271,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The inputUriPrefix. */ + @java.lang.Override public java.lang.String getInputUriPrefix() { java.lang.Object ref = inputUriPrefix_; if (ref instanceof java.lang.String) { @@ -295,6 +298,7 @@ public java.lang.String getInputUriPrefix() { * * @return The bytes for inputUriPrefix. */ + @java.lang.Override public com.google.protobuf.ByteString getInputUriPrefixBytes() { java.lang.Object ref = inputUriPrefix_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Index.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Index.java index 951ad4da8..52c959b16 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Index.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Index.java @@ -274,6 +274,10 @@ public QueryScope findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -476,6 +480,10 @@ public State findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -826,6 +834,10 @@ public Order findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -957,6 +969,10 @@ public ArrayConfig findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -1051,6 +1067,7 @@ public ValueModeCase getValueModeCase() { * * @return The fieldPath. */ + @java.lang.Override public java.lang.String getFieldPath() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -1075,6 +1092,7 @@ public java.lang.String getFieldPath() { * * @return The bytes for fieldPath. */ + @java.lang.Override public com.google.protobuf.ByteString getFieldPathBytes() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -1702,6 +1720,7 @@ public Builder setFieldPathBytes(com.google.protobuf.ByteString value) { * * @return The enum numeric value on the wire for order. */ + @java.lang.Override public int getOrderValue() { if (valueModeCase_ == 2) { return ((java.lang.Integer) valueMode_).intValue(); @@ -1739,6 +1758,7 @@ public Builder setOrderValue(int value) { * * @return The order. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.IndexField.Order getOrder() { if (valueModeCase_ == 2) { @SuppressWarnings("deprecation") @@ -1805,6 +1825,7 @@ public Builder clearOrder() { * * @return The enum numeric value on the wire for arrayConfig. */ + @java.lang.Override public int getArrayConfigValue() { if (valueModeCase_ == 3) { return ((java.lang.Integer) valueMode_).intValue(); @@ -1840,6 +1861,7 @@ public Builder setArrayConfigValue(int value) { * * @return The arrayConfig. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.IndexField.ArrayConfig getArrayConfig() { if (valueModeCase_ == 3) { @SuppressWarnings("deprecation") @@ -1962,6 +1984,7 @@ public com.google.firestore.admin.v1.Index.IndexField getDefaultInstanceForType( * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -1987,6 +2010,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -2017,6 +2041,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * @return The enum numeric value on the wire for queryScope. */ + @java.lang.Override public int getQueryScopeValue() { return queryScope_; } @@ -2036,6 +2061,7 @@ public int getQueryScopeValue() { * * @return The queryScope. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.QueryScope getQueryScope() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.Index.QueryScope result = @@ -2062,6 +2088,7 @@ public com.google.firestore.admin.v1.Index.QueryScope getQueryScope() { * * repeated .google.firestore.admin.v1.Index.IndexField fields = 3; */ + @java.lang.Override public java.util.List getFieldsList() { return fields_; } @@ -2082,6 +2109,7 @@ public java.util.List getFieldsL * * repeated .google.firestore.admin.v1.Index.IndexField fields = 3; */ + @java.lang.Override public java.util.List getFieldsOrBuilderList() { return fields_; @@ -2103,6 +2131,7 @@ public java.util.List getFieldsL * * repeated .google.firestore.admin.v1.Index.IndexField fields = 3; */ + @java.lang.Override public int getFieldsCount() { return fields_.size(); } @@ -2123,6 +2152,7 @@ public int getFieldsCount() { * * repeated .google.firestore.admin.v1.Index.IndexField fields = 3; */ + @java.lang.Override public com.google.firestore.admin.v1.Index.IndexField getFields(int index) { return fields_.get(index); } @@ -2143,6 +2173,7 @@ public com.google.firestore.admin.v1.Index.IndexField getFields(int index) { * * repeated .google.firestore.admin.v1.Index.IndexField fields = 3; */ + @java.lang.Override public com.google.firestore.admin.v1.Index.IndexFieldOrBuilder getFieldsOrBuilder(int index) { return fields_.get(index); } @@ -2160,6 +2191,7 @@ public com.google.firestore.admin.v1.Index.IndexFieldOrBuilder getFieldsOrBuilde * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -2174,6 +2206,7 @@ public int getStateValue() { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.State getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.Index.State result = @@ -2723,6 +2756,7 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * @return The enum numeric value on the wire for queryScope. */ + @java.lang.Override public int getQueryScopeValue() { return queryScope_; } @@ -2744,6 +2778,7 @@ public int getQueryScopeValue() { * @return This builder for chaining. */ public Builder setQueryScopeValue(int value) { + queryScope_ = value; onChanged(); return this; @@ -2764,6 +2799,7 @@ public Builder setQueryScopeValue(int value) { * * @return The queryScope. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.QueryScope getQueryScope() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.Index.QueryScope result = @@ -3325,6 +3361,7 @@ public com.google.firestore.admin.v1.Index.IndexField.Builder addFieldsBuilder(i * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -3341,6 +3378,7 @@ public int getStateValue() { * @return This builder for chaining. */ public Builder setStateValue(int value) { + state_ = value; onChanged(); return this; @@ -3356,6 +3394,7 @@ public Builder setStateValue(int value) { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.Index.State getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.Index.State result = diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexOperationMetadata.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexOperationMetadata.java index 7ede5d302..6e10525f0 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexOperationMetadata.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexOperationMetadata.java @@ -195,6 +195,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the startTime field is set. */ + @java.lang.Override public boolean hasStartTime() { return startTime_ != null; } @@ -209,6 +210,7 @@ public boolean hasStartTime() { * * @return The startTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getStartTime() { return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; } @@ -221,6 +223,7 @@ public com.google.protobuf.Timestamp getStartTime() { * * .google.protobuf.Timestamp start_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { return getStartTime(); } @@ -239,6 +242,7 @@ public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { * * @return Whether the endTime field is set. */ + @java.lang.Override public boolean hasEndTime() { return endTime_ != null; } @@ -254,6 +258,7 @@ public boolean hasEndTime() { * * @return The endTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getEndTime() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } @@ -267,6 +272,7 @@ public com.google.protobuf.Timestamp getEndTime() { * * .google.protobuf.Timestamp end_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return getEndTime(); } @@ -285,6 +291,7 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { * * @return The index. */ + @java.lang.Override public java.lang.String getIndex() { java.lang.Object ref = index_; if (ref instanceof java.lang.String) { @@ -308,6 +315,7 @@ public java.lang.String getIndex() { * * @return The bytes for index. */ + @java.lang.Override public com.google.protobuf.ByteString getIndexBytes() { java.lang.Object ref = index_; if (ref instanceof java.lang.String) { @@ -333,6 +341,7 @@ public com.google.protobuf.ByteString getIndexBytes() { * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -347,6 +356,7 @@ public int getStateValue() { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = @@ -367,6 +377,7 @@ public com.google.firestore.admin.v1.OperationState getState() { * * @return Whether the progressDocuments field is set. */ + @java.lang.Override public boolean hasProgressDocuments() { return progressDocuments_ != null; } @@ -381,6 +392,7 @@ public boolean hasProgressDocuments() { * * @return The progressDocuments. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressDocuments() { return progressDocuments_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -395,6 +407,7 @@ public com.google.firestore.admin.v1.Progress getProgressDocuments() { * * .google.firestore.admin.v1.Progress progress_documents = 5; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBuilder() { return getProgressDocuments(); } @@ -412,6 +425,7 @@ public com.google.firestore.admin.v1.ProgressOrBuilder getProgressDocumentsOrBui * * @return Whether the progressBytes field is set. */ + @java.lang.Override public boolean hasProgressBytes() { return progressBytes_ != null; } @@ -426,6 +440,7 @@ public boolean hasProgressBytes() { * * @return The progressBytes. */ + @java.lang.Override public com.google.firestore.admin.v1.Progress getProgressBytes() { return progressBytes_ == null ? com.google.firestore.admin.v1.Progress.getDefaultInstance() @@ -440,6 +455,7 @@ public com.google.firestore.admin.v1.Progress getProgressBytes() { * * .google.firestore.admin.v1.Progress progress_bytes = 6; */ + @java.lang.Override public com.google.firestore.admin.v1.ProgressOrBuilder getProgressBytesOrBuilder() { return getProgressBytes(); } @@ -1382,6 +1398,7 @@ public Builder setIndexBytes(com.google.protobuf.ByteString value) { * * @return The enum numeric value on the wire for state. */ + @java.lang.Override public int getStateValue() { return state_; } @@ -1398,6 +1415,7 @@ public int getStateValue() { * @return This builder for chaining. */ public Builder setStateValue(int value) { + state_ = value; onChanged(); return this; @@ -1413,6 +1431,7 @@ public Builder setStateValue(int value) { * * @return The state. */ + @java.lang.Override public com.google.firestore.admin.v1.OperationState getState() { @SuppressWarnings("deprecation") com.google.firestore.admin.v1.OperationState result = diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexProto.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexProto.java index 5f1911eb6..15ed8be5f 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexProto.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/IndexProto.java @@ -67,12 +67,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "AIR\020\003:z\352Aw\n\036firestore.googleapis.com/Ind" + "ex\022Uprojects/{project}/databases/{databa" + "se}/collectionGroups/{collection}/indexe" - + "s/{index}B\270\001\n\035com.google.firestore.admin" + + "s/{index}B\336\001\n\035com.google.firestore.admin" + ".v1B\nIndexProtoP\001Z>google.golang.org/gen" + "proto/googleapis/firestore/admin/v1;admi" + "n\242\002\004GCFS\252\002\037Google.Cloud.Firestore.Admin." - + "V1\312\002\037Google\\Cloud\\Firestore\\Admin\\V1b\006pr" - + "oto3" + + "V1\312\002\037Google\\Cloud\\Firestore\\Admin\\V1\352\002#G" + + "oogle::Cloud::Firestore::Admin::V1b\006prot" + + "o3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsRequest.java index 4767253fa..3f879e29c 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsRequest.java @@ -148,6 +148,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -173,6 +174,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -202,6 +204,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The filter. */ + @java.lang.Override public java.lang.String getFilter() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { @@ -228,6 +231,7 @@ public java.lang.String getFilter() { * * @return The bytes for filter. */ + @java.lang.Override public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { @@ -253,6 +257,7 @@ public com.google.protobuf.ByteString getFilterBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -272,6 +277,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -296,6 +302,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -931,6 +938,7 @@ public Builder setFilterBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsResponse.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsResponse.java index e03d5bd39..837940a2b 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsResponse.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListFieldsResponse.java @@ -138,6 +138,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.admin.v1.Field fields = 1; */ + @java.lang.Override public java.util.List getFieldsList() { return fields_; } @@ -150,6 +151,7 @@ public java.util.List getFieldsList() { * * repeated .google.firestore.admin.v1.Field fields = 1; */ + @java.lang.Override public java.util.List getFieldsOrBuilderList() { return fields_; @@ -163,6 +165,7 @@ public java.util.List getFieldsList() { * * repeated .google.firestore.admin.v1.Field fields = 1; */ + @java.lang.Override public int getFieldsCount() { return fields_.size(); } @@ -175,6 +178,7 @@ public int getFieldsCount() { * * repeated .google.firestore.admin.v1.Field fields = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.Field getFields(int index) { return fields_.get(index); } @@ -187,6 +191,7 @@ public com.google.firestore.admin.v1.Field getFields(int index) { * * repeated .google.firestore.admin.v1.Field fields = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOrBuilder getFieldsOrBuilder(int index) { return fields_.get(index); } @@ -205,6 +210,7 @@ public com.google.firestore.admin.v1.FieldOrBuilder getFieldsOrBuilder(int index * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -228,6 +234,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesRequest.java index bce74beaf..0f6d1471a 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesRequest.java @@ -148,6 +148,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -173,6 +174,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -198,6 +200,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The filter. */ + @java.lang.Override public java.lang.String getFilter() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { @@ -220,6 +223,7 @@ public java.lang.String getFilter() { * * @return The bytes for filter. */ + @java.lang.Override public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { @@ -245,6 +249,7 @@ public com.google.protobuf.ByteString getFilterBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -264,6 +269,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -288,6 +294,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -903,6 +910,7 @@ public Builder setFilterBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesResponse.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesResponse.java index c5e808697..0e53b8338 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesResponse.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/ListIndexesResponse.java @@ -138,6 +138,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public java.util.List getIndexesList() { return indexes_; } @@ -150,6 +151,7 @@ public java.util.List getIndexesList() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public java.util.List getIndexesOrBuilderList() { return indexes_; @@ -163,6 +165,7 @@ public java.util.List getIndexesList() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public int getIndexesCount() { return indexes_.size(); } @@ -175,6 +178,7 @@ public int getIndexesCount() { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.Index getIndexes(int index) { return indexes_.get(index); } @@ -187,6 +191,7 @@ public com.google.firestore.admin.v1.Index getIndexes(int index) { * * repeated .google.firestore.admin.v1.Index indexes = 1; */ + @java.lang.Override public com.google.firestore.admin.v1.IndexOrBuilder getIndexesOrBuilder(int index) { return indexes_.get(index); } @@ -205,6 +210,7 @@ public com.google.firestore.admin.v1.IndexOrBuilder getIndexesOrBuilder(int inde * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -228,6 +234,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/LocationProto.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/LocationProto.java index 94d28faca..2acc168cc 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/LocationProto.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/LocationProto.java @@ -43,12 +43,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "\n(google/firestore/admin/v1/location.pro" + "to\022\031google.firestore.admin.v1\032\030google/ty" + "pe/latlng.proto\032\034google/api/annotations." - + "proto\"\022\n\020LocationMetadataB\273\001\n\035com.google" + + "proto\"\022\n\020LocationMetadataB\341\001\n\035com.google" + ".firestore.admin.v1B\rLocationProtoP\001Z>go" + "ogle.golang.org/genproto/googleapis/fire" + "store/admin/v1;admin\242\002\004GCFS\252\002\037Google.Clo" + "ud.Firestore.Admin.V1\312\002\037Google\\Cloud\\Fir" - + "estore\\Admin\\V1b\006proto3" + + "estore\\Admin\\V1\352\002#Google::Cloud::Firesto" + + "re::Admin::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationProto.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationProto.java index 4d4c94b32..7dcd16407 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationProto.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationProto.java @@ -117,12 +117,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "tionState\022\037\n\033OPERATION_STATE_UNSPECIFIED" + "\020\000\022\020\n\014INITIALIZING\020\001\022\016\n\nPROCESSING\020\002\022\016\n\n" + "CANCELLING\020\003\022\016\n\nFINALIZING\020\004\022\016\n\nSUCCESSF" - + "UL\020\005\022\n\n\006FAILED\020\006\022\r\n\tCANCELLED\020\007B\274\001\n\035com." + + "UL\020\005\022\n\n\006FAILED\020\006\022\r\n\tCANCELLED\020\007B\342\001\n\035com." + "google.firestore.admin.v1B\016OperationProt" + "oP\001Z>google.golang.org/genproto/googleap" + "is/firestore/admin/v1;admin\242\002\004GCFS\252\002\037Goo" + "gle.Cloud.Firestore.Admin.V1\312\002\037Google\\Cl" - + "oud\\Firestore\\Admin\\V1b\006proto3" + + "oud\\Firestore\\Admin\\V1\352\002#Google::Cloud::" + + "Firestore::Admin::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationState.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationState.java index 7054eec3e..50180d98c 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationState.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/OperationState.java @@ -253,6 +253,10 @@ public OperationState findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Progress.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Progress.java index ffb7c657c..e7bb7791a 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Progress.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/Progress.java @@ -127,6 +127,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The estimatedWork. */ + @java.lang.Override public long getEstimatedWork() { return estimatedWork_; } @@ -144,6 +145,7 @@ public long getEstimatedWork() { * * @return The completedWork. */ + @java.lang.Override public long getCompletedWork() { return completedWork_; } @@ -491,6 +493,7 @@ public Builder mergeFrom( * * @return The estimatedWork. */ + @java.lang.Override public long getEstimatedWork() { return estimatedWork_; } @@ -542,6 +545,7 @@ public Builder clearEstimatedWork() { * * @return The completedWork. */ + @java.lang.Override public long getCompletedWork() { return completedWork_; } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/UpdateFieldRequest.java b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/UpdateFieldRequest.java index 69ab8ca6d..2820094c2 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/UpdateFieldRequest.java +++ b/proto-google-cloud-firestore-admin-v1/src/main/java/com/google/firestore/admin/v1/UpdateFieldRequest.java @@ -147,6 +147,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return field_ != null; } @@ -162,6 +163,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.admin.v1.Field getField() { return field_ == null ? com.google.firestore.admin.v1.Field.getDefaultInstance() : field_; } @@ -175,6 +177,7 @@ public com.google.firestore.admin.v1.Field getField() { * .google.firestore.admin.v1.Field field = 1 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.admin.v1.FieldOrBuilder getFieldOrBuilder() { return getField(); } @@ -193,6 +196,7 @@ public com.google.firestore.admin.v1.FieldOrBuilder getFieldOrBuilder() { * * @return Whether the updateMask field is set. */ + @java.lang.Override public boolean hasUpdateMask() { return updateMask_ != null; } @@ -208,6 +212,7 @@ public boolean hasUpdateMask() { * * @return The updateMask. */ + @java.lang.Override public com.google.protobuf.FieldMask getUpdateMask() { return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; } @@ -221,6 +226,7 @@ public com.google.protobuf.FieldMask getUpdateMask() { * * .google.protobuf.FieldMask update_mask = 2; */ + @java.lang.Override public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { return getUpdateMask(); } diff --git a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/field.proto b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/field.proto index 48430d87c..1b9b99cf3 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/field.proto +++ b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/field.proto @@ -28,6 +28,7 @@ option java_outer_classname = "FieldProto"; option java_package = "com.google.firestore.admin.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\Admin\\V1"; +option ruby_package = "Google::Cloud::Firestore::Admin::V1"; // Represents a single field in the database. // diff --git a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/firestore_admin.proto b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/firestore_admin.proto index 75dd2d311..c3eb58f9c 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/firestore_admin.proto +++ b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/firestore_admin.proto @@ -34,6 +34,7 @@ option java_outer_classname = "FirestoreAdminProto"; option java_package = "com.google.firestore.admin.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\Admin\\V1"; +option ruby_package = "Google::Cloud::Firestore::Admin::V1"; option (google.api.resource_definition) = { type: "firestore.googleapis.com/Database" pattern: "projects/{project}/databases/{database}" diff --git a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/index.proto b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/index.proto index 4b9c6e35b..e27686be4 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/index.proto +++ b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/index.proto @@ -27,6 +27,7 @@ option java_outer_classname = "IndexProto"; option java_package = "com.google.firestore.admin.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\Admin\\V1"; +option ruby_package = "Google::Cloud::Firestore::Admin::V1"; // Cloud Firestore indexes enable simple and complex queries against // documents in a database. diff --git a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/location.proto b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/location.proto index d9dc6f9b9..e435c6f0d 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/location.proto +++ b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/location.proto @@ -27,6 +27,7 @@ option java_outer_classname = "LocationProto"; option java_package = "com.google.firestore.admin.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\Admin\\V1"; +option ruby_package = "Google::Cloud::Firestore::Admin::V1"; // The metadata message for [google.cloud.location.Location.metadata][google.cloud.location.Location.metadata]. message LocationMetadata { diff --git a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/operation.proto b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/operation.proto index 08194fe09..dcdc6ee65 100644 --- a/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/operation.proto +++ b/proto-google-cloud-firestore-admin-v1/src/main/proto/google/firestore/admin/v1/operation.proto @@ -28,6 +28,7 @@ option java_outer_classname = "OperationProto"; option java_package = "com.google.firestore.admin.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\Admin\\V1"; +option ruby_package = "Google::Cloud::Firestore::Admin::V1"; // Metadata for [google.longrunning.Operation][google.longrunning.Operation] results from // [FirestoreAdmin.CreateIndex][google.firestore.admin.v1.FirestoreAdmin.CreateIndex]. diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ArrayValue.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ArrayValue.java index f3bf61fb7..1c6715086 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ArrayValue.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ArrayValue.java @@ -129,6 +129,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesList() { return values_; } @@ -141,6 +142,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesOrBuilderList() { return values_; } @@ -153,6 +155,7 @@ public java.util.List getValue * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public int getValuesCount() { return values_.size(); } @@ -165,6 +168,7 @@ public int getValuesCount() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getValues(int index) { return values_.get(index); } @@ -177,6 +181,7 @@ public com.google.firestore.v1.Value getValues(int index) { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getValuesOrBuilder(int index) { return values_.get(index); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequest.java index 8c77ed312..4ec3371db 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequest.java @@ -245,6 +245,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -268,6 +269,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -368,6 +370,7 @@ public com.google.protobuf.ByteString getDocumentsBytes(int index) { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -384,6 +387,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() : mask_; } @@ -398,6 +402,7 @@ public com.google.firestore.v1.DocumentMask getMask() { * * .google.firestore.v1.DocumentMask mask = 3; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -414,6 +419,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 4) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -436,6 +442,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 5; } @@ -453,6 +460,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions getNewTransaction() { if (consistencySelectorCase_ == 5) { return (com.google.firestore.v1.TransactionOptions) consistencySelector_; @@ -471,6 +479,7 @@ public com.google.firestore.v1.TransactionOptions getNewTransaction() { * * .google.firestore.v1.TransactionOptions new_transaction = 5; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if (consistencySelectorCase_ == 5) { return (com.google.firestore.v1.TransactionOptions) consistencySelector_; @@ -484,13 +493,14 @@ public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBu * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -499,13 +509,14 @@ public boolean hasReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -517,11 +528,12 @@ public com.google.protobuf.Timestamp getReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1601,6 +1613,7 @@ public Builder clearTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 5; } @@ -1618,6 +1631,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions getNewTransaction() { if (newTransactionBuilder_ == null) { if (consistencySelectorCase_ == 5) { @@ -1769,6 +1783,7 @@ public com.google.firestore.v1.TransactionOptions.Builder getNewTransactionBuild * * .google.firestore.v1.TransactionOptions new_transaction = 5; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if ((consistencySelectorCase_ == 5) && (newTransactionBuilder_ != null)) { return newTransactionBuilder_.getMessageOrBuilder(); @@ -1826,13 +1841,14 @@ public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBu * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -1841,13 +1857,14 @@ public boolean hasReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 7) { @@ -1866,7 +1883,7 @@ public com.google.protobuf.Timestamp getReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1889,7 +1906,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1909,7 +1926,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp.Builder builderForValue * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1941,7 +1958,7 @@ public Builder mergeReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1967,7 +1984,7 @@ public Builder clearReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1980,11 +1997,12 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 7) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -2000,7 +2018,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequestOrBuilder.java index c80c27882..8257d80c6 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequestOrBuilder.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsRequestOrBuilder.java @@ -216,7 +216,7 @@ public interface BatchGetDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; @@ -229,7 +229,7 @@ public interface BatchGetDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; @@ -242,7 +242,7 @@ public interface BatchGetDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsResponse.java index 8d304e24e..d6cbff668 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchGetDocumentsResponse.java @@ -205,6 +205,7 @@ public ResultCase getResultCase() { * * @return Whether the found field is set. */ + @java.lang.Override public boolean hasFound() { return resultCase_ == 1; } @@ -219,6 +220,7 @@ public boolean hasFound() { * * @return The found. */ + @java.lang.Override public com.google.firestore.v1.Document getFound() { if (resultCase_ == 1) { return (com.google.firestore.v1.Document) result_; @@ -234,6 +236,7 @@ public com.google.firestore.v1.Document getFound() { * * .google.firestore.v1.Document found = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getFoundOrBuilder() { if (resultCase_ == 1) { return (com.google.firestore.v1.Document) result_; @@ -314,6 +317,7 @@ public com.google.protobuf.ByteString getMissingBytes() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -334,6 +338,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -351,6 +356,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -366,6 +372,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -813,6 +820,7 @@ public Builder clearResult() { * * @return Whether the found field is set. */ + @java.lang.Override public boolean hasFound() { return resultCase_ == 1; } @@ -827,6 +835,7 @@ public boolean hasFound() { * * @return The found. */ + @java.lang.Override public com.google.firestore.v1.Document getFound() { if (foundBuilder_ == null) { if (resultCase_ == 1) { @@ -957,6 +966,7 @@ public com.google.firestore.v1.Document.Builder getFoundBuilder() { * * .google.firestore.v1.Document found = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getFoundOrBuilder() { if ((resultCase_ == 1) && (foundBuilder_ != null)) { return foundBuilder_.getMessageOrBuilder(); @@ -1011,6 +1021,7 @@ public com.google.firestore.v1.DocumentOrBuilder getFoundOrBuilder() { * * @return The missing. */ + @java.lang.Override public java.lang.String getMissing() { java.lang.Object ref = ""; if (resultCase_ == 2) { @@ -1039,6 +1050,7 @@ public java.lang.String getMissing() { * * @return The bytes for missing. */ + @java.lang.Override public com.google.protobuf.ByteString getMissingBytes() { java.lang.Object ref = ""; if (resultCase_ == 2) { @@ -1135,6 +1147,7 @@ public Builder setMissingBytes(com.google.protobuf.ByteString value) { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequest.java new file mode 100644 index 000000000..29fac66fb --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequest.java @@ -0,0 +1,1516 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +/** + * + * + *
+ * The request for [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite].
+ * 
+ * + * Protobuf type {@code google.firestore.v1.BatchWriteRequest} + */ +public final class BatchWriteRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.firestore.v1.BatchWriteRequest) + BatchWriteRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use BatchWriteRequest.newBuilder() to construct. + private BatchWriteRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private BatchWriteRequest() { + database_ = ""; + writes_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new BatchWriteRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private BatchWriteRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + database_ = s; + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + writes_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + writes_.add( + input.readMessage(com.google.firestore.v1.Write.parser(), extensionRegistry)); + break; + } + case 26: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + labels_ = + com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000002; + } + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); + labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + writes_ = java.util.Collections.unmodifiableList(writes_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 3: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.BatchWriteRequest.class, + com.google.firestore.v1.BatchWriteRequest.Builder.class); + } + + public static final int DATABASE_FIELD_NUMBER = 1; + private volatile java.lang.Object database_; + /** + * + * + *
+   * Required. The database name. In the format:
+   * `projects/{project_id}/databases/{database_id}`.
+   * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The database. + */ + @java.lang.Override + public java.lang.String getDatabase() { + java.lang.Object ref = database_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + database_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The database name. In the format:
+   * `projects/{project_id}/databases/{database_id}`.
+   * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for database. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDatabaseBytes() { + java.lang.Object ref = database_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + database_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int WRITES_FIELD_NUMBER = 2; + private java.util.List writes_; + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + @java.lang.Override + public java.util.List getWritesList() { + return writes_; + } + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + @java.lang.Override + public java.util.List getWritesOrBuilderList() { + return writes_; + } + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + @java.lang.Override + public int getWritesCount() { + return writes_.size(); + } + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + @java.lang.Override + public com.google.firestore.v1.Write getWrites(int index) { + return writes_.get(index); + } + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + @java.lang.Override + public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { + return writes_.get(index); + } + + public static final int LABELS_FIELD_NUMBER = 3; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getDatabaseBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, database_); + } + for (int i = 0; i < writes_.size(); i++) { + output.writeMessage(2, writes_.get(i)); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 3); + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getDatabaseBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, database_); + } + for (int i = 0; i < writes_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, writes_.get(i)); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, labels__); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.firestore.v1.BatchWriteRequest)) { + return super.equals(obj); + } + com.google.firestore.v1.BatchWriteRequest other = + (com.google.firestore.v1.BatchWriteRequest) obj; + + if (!getDatabase().equals(other.getDatabase())) return false; + if (!getWritesList().equals(other.getWritesList())) return false; + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DATABASE_FIELD_NUMBER; + hash = (53 * hash) + getDatabase().hashCode(); + if (getWritesCount() > 0) { + hash = (37 * hash) + WRITES_FIELD_NUMBER; + hash = (53 * hash) + getWritesList().hashCode(); + } + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.firestore.v1.BatchWriteRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request for [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite].
+   * 
+ * + * Protobuf type {@code google.firestore.v1.BatchWriteRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.firestore.v1.BatchWriteRequest) + com.google.firestore.v1.BatchWriteRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 3: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 3: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.BatchWriteRequest.class, + com.google.firestore.v1.BatchWriteRequest.Builder.class); + } + + // Construct using com.google.firestore.v1.BatchWriteRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getWritesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + database_ = ""; + + if (writesBuilder_ == null) { + writes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + writesBuilder_.clear(); + } + internalGetMutableLabels().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteRequest_descriptor; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteRequest getDefaultInstanceForType() { + return com.google.firestore.v1.BatchWriteRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteRequest build() { + com.google.firestore.v1.BatchWriteRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteRequest buildPartial() { + com.google.firestore.v1.BatchWriteRequest result = + new com.google.firestore.v1.BatchWriteRequest(this); + int from_bitField0_ = bitField0_; + result.database_ = database_; + if (writesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + writes_ = java.util.Collections.unmodifiableList(writes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.writes_ = writes_; + } else { + result.writes_ = writesBuilder_.build(); + } + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.firestore.v1.BatchWriteRequest) { + return mergeFrom((com.google.firestore.v1.BatchWriteRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.firestore.v1.BatchWriteRequest other) { + if (other == com.google.firestore.v1.BatchWriteRequest.getDefaultInstance()) return this; + if (!other.getDatabase().isEmpty()) { + database_ = other.database_; + onChanged(); + } + if (writesBuilder_ == null) { + if (!other.writes_.isEmpty()) { + if (writes_.isEmpty()) { + writes_ = other.writes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureWritesIsMutable(); + writes_.addAll(other.writes_); + } + onChanged(); + } + } else { + if (!other.writes_.isEmpty()) { + if (writesBuilder_.isEmpty()) { + writesBuilder_.dispose(); + writesBuilder_ = null; + writes_ = other.writes_; + bitField0_ = (bitField0_ & ~0x00000001); + writesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getWritesFieldBuilder() + : null; + } else { + writesBuilder_.addAllMessages(other.writes_); + } + } + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.firestore.v1.BatchWriteRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.firestore.v1.BatchWriteRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object database_ = ""; + /** + * + * + *
+     * Required. The database name. In the format:
+     * `projects/{project_id}/databases/{database_id}`.
+     * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The database. + */ + public java.lang.String getDatabase() { + java.lang.Object ref = database_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + database_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The database name. In the format:
+     * `projects/{project_id}/databases/{database_id}`.
+     * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for database. + */ + public com.google.protobuf.ByteString getDatabaseBytes() { + java.lang.Object ref = database_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + database_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The database name. In the format:
+     * `projects/{project_id}/databases/{database_id}`.
+     * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The database to set. + * @return This builder for chaining. + */ + public Builder setDatabase(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + database_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The database name. In the format:
+     * `projects/{project_id}/databases/{database_id}`.
+     * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDatabase() { + + database_ = getDefaultInstance().getDatabase(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The database name. In the format:
+     * `projects/{project_id}/databases/{database_id}`.
+     * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for database to set. + * @return This builder for chaining. + */ + public Builder setDatabaseBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + database_ = value; + onChanged(); + return this; + } + + private java.util.List writes_ = + java.util.Collections.emptyList(); + + private void ensureWritesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + writes_ = new java.util.ArrayList(writes_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Write, + com.google.firestore.v1.Write.Builder, + com.google.firestore.v1.WriteOrBuilder> + writesBuilder_; + + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public java.util.List getWritesList() { + if (writesBuilder_ == null) { + return java.util.Collections.unmodifiableList(writes_); + } else { + return writesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public int getWritesCount() { + if (writesBuilder_ == null) { + return writes_.size(); + } else { + return writesBuilder_.getCount(); + } + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public com.google.firestore.v1.Write getWrites(int index) { + if (writesBuilder_ == null) { + return writes_.get(index); + } else { + return writesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder setWrites(int index, com.google.firestore.v1.Write value) { + if (writesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWritesIsMutable(); + writes_.set(index, value); + onChanged(); + } else { + writesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder setWrites(int index, com.google.firestore.v1.Write.Builder builderForValue) { + if (writesBuilder_ == null) { + ensureWritesIsMutable(); + writes_.set(index, builderForValue.build()); + onChanged(); + } else { + writesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder addWrites(com.google.firestore.v1.Write value) { + if (writesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWritesIsMutable(); + writes_.add(value); + onChanged(); + } else { + writesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder addWrites(int index, com.google.firestore.v1.Write value) { + if (writesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWritesIsMutable(); + writes_.add(index, value); + onChanged(); + } else { + writesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder addWrites(com.google.firestore.v1.Write.Builder builderForValue) { + if (writesBuilder_ == null) { + ensureWritesIsMutable(); + writes_.add(builderForValue.build()); + onChanged(); + } else { + writesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder addWrites(int index, com.google.firestore.v1.Write.Builder builderForValue) { + if (writesBuilder_ == null) { + ensureWritesIsMutable(); + writes_.add(index, builderForValue.build()); + onChanged(); + } else { + writesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder addAllWrites( + java.lang.Iterable values) { + if (writesBuilder_ == null) { + ensureWritesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, writes_); + onChanged(); + } else { + writesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder clearWrites() { + if (writesBuilder_ == null) { + writes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + writesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public Builder removeWrites(int index) { + if (writesBuilder_ == null) { + ensureWritesIsMutable(); + writes_.remove(index); + onChanged(); + } else { + writesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public com.google.firestore.v1.Write.Builder getWritesBuilder(int index) { + return getWritesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { + if (writesBuilder_ == null) { + return writes_.get(index); + } else { + return writesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public java.util.List + getWritesOrBuilderList() { + if (writesBuilder_ != null) { + return writesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(writes_); + } + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public com.google.firestore.v1.Write.Builder addWritesBuilder() { + return getWritesFieldBuilder().addBuilder(com.google.firestore.v1.Write.getDefaultInstance()); + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public com.google.firestore.v1.Write.Builder addWritesBuilder(int index) { + return getWritesFieldBuilder() + .addBuilder(index, com.google.firestore.v1.Write.getDefaultInstance()); + } + /** + * + * + *
+     * The writes to apply.
+     * Method does not apply writes atomically and does not guarantee ordering.
+     * Each write succeeds or fails independently. You cannot write to the same
+     * document more than once per request.
+     * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + public java.util.List getWritesBuilderList() { + return getWritesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Write, + com.google.firestore.v1.Write.Builder, + com.google.firestore.v1.WriteOrBuilder> + getWritesFieldBuilder() { + if (writesBuilder_ == null) { + writesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Write, + com.google.firestore.v1.Write.Builder, + com.google.firestore.v1.WriteOrBuilder>( + writes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + writes_ = null; + } + return writesBuilder_; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + onChanged(); + ; + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + return internalGetMutableLabels().getMutableMap(); + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + if (value == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+     * Labels associated with this batch write.
+     * 
+ * + * map<string, string> labels = 3; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.firestore.v1.BatchWriteRequest) + } + + // @@protoc_insertion_point(class_scope:google.firestore.v1.BatchWriteRequest) + private static final com.google.firestore.v1.BatchWriteRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.firestore.v1.BatchWriteRequest(); + } + + public static com.google.firestore.v1.BatchWriteRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BatchWriteRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BatchWriteRequest(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequestOrBuilder.java new file mode 100644 index 000000000..21b8e2156 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteRequestOrBuilder.java @@ -0,0 +1,172 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +public interface BatchWriteRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.firestore.v1.BatchWriteRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The database name. In the format:
+   * `projects/{project_id}/databases/{database_id}`.
+   * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The database. + */ + java.lang.String getDatabase(); + /** + * + * + *
+   * Required. The database name. In the format:
+   * `projects/{project_id}/databases/{database_id}`.
+   * 
+ * + * string database = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for database. + */ + com.google.protobuf.ByteString getDatabaseBytes(); + + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + java.util.List getWritesList(); + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + com.google.firestore.v1.Write getWrites(int index); + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + int getWritesCount(); + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + java.util.List getWritesOrBuilderList(); + /** + * + * + *
+   * The writes to apply.
+   * Method does not apply writes atomically and does not guarantee ordering.
+   * Each write succeeds or fails independently. You cannot write to the same
+   * document more than once per request.
+   * 
+ * + * repeated .google.firestore.v1.Write writes = 2; + */ + com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index); + + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + int getLabelsCount(); + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + java.util.Map getLabelsMap(); + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); + /** + * + * + *
+   * Labels associated with this batch write.
+   * 
+ * + * map<string, string> labels = 3; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponse.java new file mode 100644 index 000000000..f8d804152 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponse.java @@ -0,0 +1,1511 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +/** + * + * + *
+ * The response from [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite].
+ * 
+ * + * Protobuf type {@code google.firestore.v1.BatchWriteResponse} + */ +public final class BatchWriteResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.firestore.v1.BatchWriteResponse) + BatchWriteResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use BatchWriteResponse.newBuilder() to construct. + private BatchWriteResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private BatchWriteResponse() { + writeResults_ = java.util.Collections.emptyList(); + status_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new BatchWriteResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private BatchWriteResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + writeResults_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + writeResults_.add( + input.readMessage( + com.google.firestore.v1.WriteResult.parser(), extensionRegistry)); + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + status_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + status_.add(input.readMessage(com.google.rpc.Status.parser(), extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + writeResults_ = java.util.Collections.unmodifiableList(writeResults_); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + status_ = java.util.Collections.unmodifiableList(status_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.BatchWriteResponse.class, + com.google.firestore.v1.BatchWriteResponse.Builder.class); + } + + public static final int WRITE_RESULTS_FIELD_NUMBER = 1; + private java.util.List writeResults_; + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + @java.lang.Override + public java.util.List getWriteResultsList() { + return writeResults_; + } + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + @java.lang.Override + public java.util.List + getWriteResultsOrBuilderList() { + return writeResults_; + } + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + @java.lang.Override + public int getWriteResultsCount() { + return writeResults_.size(); + } + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + @java.lang.Override + public com.google.firestore.v1.WriteResult getWriteResults(int index) { + return writeResults_.get(index); + } + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + @java.lang.Override + public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { + return writeResults_.get(index); + } + + public static final int STATUS_FIELD_NUMBER = 2; + private java.util.List status_; + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + @java.lang.Override + public java.util.List getStatusList() { + return status_; + } + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + @java.lang.Override + public java.util.List getStatusOrBuilderList() { + return status_; + } + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + @java.lang.Override + public int getStatusCount() { + return status_.size(); + } + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + @java.lang.Override + public com.google.rpc.Status getStatus(int index) { + return status_.get(index); + } + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + @java.lang.Override + public com.google.rpc.StatusOrBuilder getStatusOrBuilder(int index) { + return status_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < writeResults_.size(); i++) { + output.writeMessage(1, writeResults_.get(i)); + } + for (int i = 0; i < status_.size(); i++) { + output.writeMessage(2, status_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < writeResults_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, writeResults_.get(i)); + } + for (int i = 0; i < status_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, status_.get(i)); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.firestore.v1.BatchWriteResponse)) { + return super.equals(obj); + } + com.google.firestore.v1.BatchWriteResponse other = + (com.google.firestore.v1.BatchWriteResponse) obj; + + if (!getWriteResultsList().equals(other.getWriteResultsList())) return false; + if (!getStatusList().equals(other.getStatusList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getWriteResultsCount() > 0) { + hash = (37 * hash) + WRITE_RESULTS_FIELD_NUMBER; + hash = (53 * hash) + getWriteResultsList().hashCode(); + } + if (getStatusCount() > 0) { + hash = (37 * hash) + STATUS_FIELD_NUMBER; + hash = (53 * hash) + getStatusList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.BatchWriteResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.firestore.v1.BatchWriteResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response from [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite].
+   * 
+ * + * Protobuf type {@code google.firestore.v1.BatchWriteResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.firestore.v1.BatchWriteResponse) + com.google.firestore.v1.BatchWriteResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.BatchWriteResponse.class, + com.google.firestore.v1.BatchWriteResponse.Builder.class); + } + + // Construct using com.google.firestore.v1.BatchWriteResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getWriteResultsFieldBuilder(); + getStatusFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (writeResultsBuilder_ == null) { + writeResults_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + writeResultsBuilder_.clear(); + } + if (statusBuilder_ == null) { + status_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + statusBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_BatchWriteResponse_descriptor; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteResponse getDefaultInstanceForType() { + return com.google.firestore.v1.BatchWriteResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteResponse build() { + com.google.firestore.v1.BatchWriteResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteResponse buildPartial() { + com.google.firestore.v1.BatchWriteResponse result = + new com.google.firestore.v1.BatchWriteResponse(this); + int from_bitField0_ = bitField0_; + if (writeResultsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + writeResults_ = java.util.Collections.unmodifiableList(writeResults_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.writeResults_ = writeResults_; + } else { + result.writeResults_ = writeResultsBuilder_.build(); + } + if (statusBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + status_ = java.util.Collections.unmodifiableList(status_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.status_ = status_; + } else { + result.status_ = statusBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.firestore.v1.BatchWriteResponse) { + return mergeFrom((com.google.firestore.v1.BatchWriteResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.firestore.v1.BatchWriteResponse other) { + if (other == com.google.firestore.v1.BatchWriteResponse.getDefaultInstance()) return this; + if (writeResultsBuilder_ == null) { + if (!other.writeResults_.isEmpty()) { + if (writeResults_.isEmpty()) { + writeResults_ = other.writeResults_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureWriteResultsIsMutable(); + writeResults_.addAll(other.writeResults_); + } + onChanged(); + } + } else { + if (!other.writeResults_.isEmpty()) { + if (writeResultsBuilder_.isEmpty()) { + writeResultsBuilder_.dispose(); + writeResultsBuilder_ = null; + writeResults_ = other.writeResults_; + bitField0_ = (bitField0_ & ~0x00000001); + writeResultsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getWriteResultsFieldBuilder() + : null; + } else { + writeResultsBuilder_.addAllMessages(other.writeResults_); + } + } + } + if (statusBuilder_ == null) { + if (!other.status_.isEmpty()) { + if (status_.isEmpty()) { + status_ = other.status_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureStatusIsMutable(); + status_.addAll(other.status_); + } + onChanged(); + } + } else { + if (!other.status_.isEmpty()) { + if (statusBuilder_.isEmpty()) { + statusBuilder_.dispose(); + statusBuilder_ = null; + status_ = other.status_; + bitField0_ = (bitField0_ & ~0x00000002); + statusBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getStatusFieldBuilder() + : null; + } else { + statusBuilder_.addAllMessages(other.status_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.firestore.v1.BatchWriteResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.firestore.v1.BatchWriteResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List writeResults_ = + java.util.Collections.emptyList(); + + private void ensureWriteResultsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + writeResults_ = new java.util.ArrayList(writeResults_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.WriteResult, + com.google.firestore.v1.WriteResult.Builder, + com.google.firestore.v1.WriteResultOrBuilder> + writeResultsBuilder_; + + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public java.util.List getWriteResultsList() { + if (writeResultsBuilder_ == null) { + return java.util.Collections.unmodifiableList(writeResults_); + } else { + return writeResultsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public int getWriteResultsCount() { + if (writeResultsBuilder_ == null) { + return writeResults_.size(); + } else { + return writeResultsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public com.google.firestore.v1.WriteResult getWriteResults(int index) { + if (writeResultsBuilder_ == null) { + return writeResults_.get(index); + } else { + return writeResultsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder setWriteResults(int index, com.google.firestore.v1.WriteResult value) { + if (writeResultsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWriteResultsIsMutable(); + writeResults_.set(index, value); + onChanged(); + } else { + writeResultsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder setWriteResults( + int index, com.google.firestore.v1.WriteResult.Builder builderForValue) { + if (writeResultsBuilder_ == null) { + ensureWriteResultsIsMutable(); + writeResults_.set(index, builderForValue.build()); + onChanged(); + } else { + writeResultsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder addWriteResults(com.google.firestore.v1.WriteResult value) { + if (writeResultsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWriteResultsIsMutable(); + writeResults_.add(value); + onChanged(); + } else { + writeResultsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder addWriteResults(int index, com.google.firestore.v1.WriteResult value) { + if (writeResultsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureWriteResultsIsMutable(); + writeResults_.add(index, value); + onChanged(); + } else { + writeResultsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder addWriteResults(com.google.firestore.v1.WriteResult.Builder builderForValue) { + if (writeResultsBuilder_ == null) { + ensureWriteResultsIsMutable(); + writeResults_.add(builderForValue.build()); + onChanged(); + } else { + writeResultsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder addWriteResults( + int index, com.google.firestore.v1.WriteResult.Builder builderForValue) { + if (writeResultsBuilder_ == null) { + ensureWriteResultsIsMutable(); + writeResults_.add(index, builderForValue.build()); + onChanged(); + } else { + writeResultsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder addAllWriteResults( + java.lang.Iterable values) { + if (writeResultsBuilder_ == null) { + ensureWriteResultsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, writeResults_); + onChanged(); + } else { + writeResultsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder clearWriteResults() { + if (writeResultsBuilder_ == null) { + writeResults_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + writeResultsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public Builder removeWriteResults(int index) { + if (writeResultsBuilder_ == null) { + ensureWriteResultsIsMutable(); + writeResults_.remove(index); + onChanged(); + } else { + writeResultsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public com.google.firestore.v1.WriteResult.Builder getWriteResultsBuilder(int index) { + return getWriteResultsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { + if (writeResultsBuilder_ == null) { + return writeResults_.get(index); + } else { + return writeResultsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public java.util.List + getWriteResultsOrBuilderList() { + if (writeResultsBuilder_ != null) { + return writeResultsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(writeResults_); + } + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public com.google.firestore.v1.WriteResult.Builder addWriteResultsBuilder() { + return getWriteResultsFieldBuilder() + .addBuilder(com.google.firestore.v1.WriteResult.getDefaultInstance()); + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public com.google.firestore.v1.WriteResult.Builder addWriteResultsBuilder(int index) { + return getWriteResultsFieldBuilder() + .addBuilder(index, com.google.firestore.v1.WriteResult.getDefaultInstance()); + } + /** + * + * + *
+     * The result of applying the writes.
+     * This i-th write result corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + public java.util.List + getWriteResultsBuilderList() { + return getWriteResultsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.WriteResult, + com.google.firestore.v1.WriteResult.Builder, + com.google.firestore.v1.WriteResultOrBuilder> + getWriteResultsFieldBuilder() { + if (writeResultsBuilder_ == null) { + writeResultsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.WriteResult, + com.google.firestore.v1.WriteResult.Builder, + com.google.firestore.v1.WriteResultOrBuilder>( + writeResults_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + writeResults_ = null; + } + return writeResultsBuilder_; + } + + private java.util.List status_ = java.util.Collections.emptyList(); + + private void ensureStatusIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + status_ = new java.util.ArrayList(status_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + statusBuilder_; + + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public java.util.List getStatusList() { + if (statusBuilder_ == null) { + return java.util.Collections.unmodifiableList(status_); + } else { + return statusBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public int getStatusCount() { + if (statusBuilder_ == null) { + return status_.size(); + } else { + return statusBuilder_.getCount(); + } + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public com.google.rpc.Status getStatus(int index) { + if (statusBuilder_ == null) { + return status_.get(index); + } else { + return statusBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder setStatus(int index, com.google.rpc.Status value) { + if (statusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStatusIsMutable(); + status_.set(index, value); + onChanged(); + } else { + statusBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder setStatus(int index, com.google.rpc.Status.Builder builderForValue) { + if (statusBuilder_ == null) { + ensureStatusIsMutable(); + status_.set(index, builderForValue.build()); + onChanged(); + } else { + statusBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder addStatus(com.google.rpc.Status value) { + if (statusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStatusIsMutable(); + status_.add(value); + onChanged(); + } else { + statusBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder addStatus(int index, com.google.rpc.Status value) { + if (statusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureStatusIsMutable(); + status_.add(index, value); + onChanged(); + } else { + statusBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder addStatus(com.google.rpc.Status.Builder builderForValue) { + if (statusBuilder_ == null) { + ensureStatusIsMutable(); + status_.add(builderForValue.build()); + onChanged(); + } else { + statusBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder addStatus(int index, com.google.rpc.Status.Builder builderForValue) { + if (statusBuilder_ == null) { + ensureStatusIsMutable(); + status_.add(index, builderForValue.build()); + onChanged(); + } else { + statusBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder addAllStatus(java.lang.Iterable values) { + if (statusBuilder_ == null) { + ensureStatusIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, status_); + onChanged(); + } else { + statusBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder clearStatus() { + if (statusBuilder_ == null) { + status_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + statusBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public Builder removeStatus(int index) { + if (statusBuilder_ == null) { + ensureStatusIsMutable(); + status_.remove(index); + onChanged(); + } else { + statusBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public com.google.rpc.Status.Builder getStatusBuilder(int index) { + return getStatusFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public com.google.rpc.StatusOrBuilder getStatusOrBuilder(int index) { + if (statusBuilder_ == null) { + return status_.get(index); + } else { + return statusBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public java.util.List getStatusOrBuilderList() { + if (statusBuilder_ != null) { + return statusBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(status_); + } + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public com.google.rpc.Status.Builder addStatusBuilder() { + return getStatusFieldBuilder().addBuilder(com.google.rpc.Status.getDefaultInstance()); + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public com.google.rpc.Status.Builder addStatusBuilder(int index) { + return getStatusFieldBuilder().addBuilder(index, com.google.rpc.Status.getDefaultInstance()); + } + /** + * + * + *
+     * The status of applying the writes.
+     * This i-th write status corresponds to the i-th write in the
+     * request.
+     * 
+ * + * repeated .google.rpc.Status status = 2; + */ + public java.util.List getStatusBuilderList() { + return getStatusFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + getStatusFieldBuilder() { + if (statusBuilder_ == null) { + statusBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, + com.google.rpc.Status.Builder, + com.google.rpc.StatusOrBuilder>( + status_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + status_ = null; + } + return statusBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.firestore.v1.BatchWriteResponse) + } + + // @@protoc_insertion_point(class_scope:google.firestore.v1.BatchWriteResponse) + private static final com.google.firestore.v1.BatchWriteResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.firestore.v1.BatchWriteResponse(); + } + + public static com.google.firestore.v1.BatchWriteResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BatchWriteResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BatchWriteResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.firestore.v1.BatchWriteResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponseOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponseOrBuilder.java new file mode 100644 index 000000000..605838ae1 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BatchWriteResponseOrBuilder.java @@ -0,0 +1,148 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +public interface BatchWriteResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.firestore.v1.BatchWriteResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + java.util.List getWriteResultsList(); + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + com.google.firestore.v1.WriteResult getWriteResults(int index); + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + int getWriteResultsCount(); + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + java.util.List + getWriteResultsOrBuilderList(); + /** + * + * + *
+   * The result of applying the writes.
+   * This i-th write result corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.firestore.v1.WriteResult write_results = 1; + */ + com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int index); + + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + java.util.List getStatusList(); + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + com.google.rpc.Status getStatus(int index); + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + int getStatusCount(); + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + java.util.List getStatusOrBuilderList(); + /** + * + * + *
+   * The status of applying the writes.
+   * This i-th write status corresponds to the i-th write in the
+   * request.
+   * 
+ * + * repeated .google.rpc.Status status = 2; + */ + com.google.rpc.StatusOrBuilder getStatusOrBuilder(int index); +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionRequest.java index c12cc7180..10dd6299b 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionRequest.java @@ -141,6 +141,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -164,6 +165,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return Whether the options field is set. */ + @java.lang.Override public boolean hasOptions() { return options_ != null; } @@ -205,6 +208,7 @@ public boolean hasOptions() { * * @return The options. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions getOptions() { return options_ == null ? com.google.firestore.v1.TransactionOptions.getDefaultInstance() @@ -220,6 +224,7 @@ public com.google.firestore.v1.TransactionOptions getOptions() { * * .google.firestore.v1.TransactionOptions options = 2; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptionsOrBuilder getOptionsOrBuilder() { return getOptions(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionResponse.java index 3449812dc..b7de35b60 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/BeginTransactionResponse.java @@ -122,6 +122,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -454,6 +455,7 @@ public Builder mergeFrom( * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitRequest.java index 21f31b7d1..116cd7eff 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitRequest.java @@ -146,6 +146,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -169,6 +170,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -193,6 +195,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * repeated .google.firestore.v1.Write writes = 2; */ + @java.lang.Override public java.util.List getWritesList() { return writes_; } @@ -206,6 +209,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1.Write writes = 2; */ + @java.lang.Override public java.util.List getWritesOrBuilderList() { return writes_; } @@ -219,6 +223,7 @@ public java.util.List getWrite * * repeated .google.firestore.v1.Write writes = 2; */ + @java.lang.Override public int getWritesCount() { return writes_.size(); } @@ -232,6 +237,7 @@ public int getWritesCount() { * * repeated .google.firestore.v1.Write writes = 2; */ + @java.lang.Override public com.google.firestore.v1.Write getWrites(int index) { return writes_.get(index); } @@ -245,6 +251,7 @@ public com.google.firestore.v1.Write getWrites(int index) { * * repeated .google.firestore.v1.Write writes = 2; */ + @java.lang.Override public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { return writes_.get(index); } @@ -262,6 +269,7 @@ public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -1139,6 +1147,7 @@ public java.util.List getWritesBuilderLis * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitResponse.java index 4ea1459d3..8675ccc60 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommitResponse.java @@ -147,6 +147,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1.WriteResult write_results = 1; */ + @java.lang.Override public java.util.List getWriteResultsList() { return writeResults_; } @@ -161,6 +162,7 @@ public java.util.List getWriteResultsList() * * repeated .google.firestore.v1.WriteResult write_results = 1; */ + @java.lang.Override public java.util.List getWriteResultsOrBuilderList() { return writeResults_; @@ -176,6 +178,7 @@ public java.util.List getWriteResultsList() * * repeated .google.firestore.v1.WriteResult write_results = 1; */ + @java.lang.Override public int getWriteResultsCount() { return writeResults_.size(); } @@ -190,6 +193,7 @@ public int getWriteResultsCount() { * * repeated .google.firestore.v1.WriteResult write_results = 1; */ + @java.lang.Override public com.google.firestore.v1.WriteResult getWriteResults(int index) { return writeResults_.get(index); } @@ -204,6 +208,7 @@ public com.google.firestore.v1.WriteResult getWriteResults(int index) { * * repeated .google.firestore.v1.WriteResult write_results = 1; */ + @java.lang.Override public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { return writeResults_.get(index); } @@ -222,6 +227,7 @@ public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int * * @return Whether the commitTime field is set. */ + @java.lang.Override public boolean hasCommitTime() { return commitTime_ != null; } @@ -237,6 +243,7 @@ public boolean hasCommitTime() { * * @return The commitTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCommitTime() { return commitTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : commitTime_; } @@ -250,6 +257,7 @@ public com.google.protobuf.Timestamp getCommitTime() { * * .google.protobuf.Timestamp commit_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCommitTimeOrBuilder() { return getCommitTime(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommonProto.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommonProto.java index 725a9f11d..bfc33a10e 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommonProto.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/CommonProto.java @@ -69,12 +69,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "actionOptions.ReadWriteH\000\032&\n\tReadWrite\022\031" + "\n\021retry_transaction\030\001 \001(\014\032S\n\010ReadOnly\022/\n" + "\tread_time\030\002 \001(\0132\032.google.protobuf.Times" - + "tampH\000B\026\n\024consistency_selectorB\006\n\004modeB\245" + + "tampH\000B\026\n\024consistency_selectorB\006\n\004modeB\304" + "\001\n\027com.google.firestore.v1B\013CommonProtoP" + "\001Z.google.firestore.v1.Document document = 4 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -366,6 +375,7 @@ public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -382,6 +392,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() : mask_; } @@ -396,6 +407,7 @@ public com.google.firestore.v1.DocumentMask getMask() { * * .google.firestore.v1.DocumentMask mask = 5; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Cursor.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Cursor.java index 7c6fe4cfb..0584089a0 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Cursor.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Cursor.java @@ -134,6 +134,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesList() { return values_; } @@ -148,6 +149,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesOrBuilderList() { return values_; } @@ -162,6 +164,7 @@ public java.util.List getValue * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public int getValuesCount() { return values_.size(); } @@ -176,6 +179,7 @@ public int getValuesCount() { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getValues(int index) { return values_.get(index); } @@ -190,6 +194,7 @@ public com.google.firestore.v1.Value getValues(int index) { * * repeated .google.firestore.v1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getValuesOrBuilder(int index) { return values_.get(index); } @@ -208,6 +213,7 @@ public com.google.firestore.v1.ValueOrBuilder getValuesOrBuilder(int index) { * * @return The before. */ + @java.lang.Override public boolean getBefore() { return before_; } @@ -975,6 +981,7 @@ public java.util.List getValuesBuilderLis * * @return The before. */ + @java.lang.Override public boolean getBefore() { return before_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DeleteDocumentRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DeleteDocumentRequest.java index 996794631..9f7303031 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DeleteDocumentRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DeleteDocumentRequest.java @@ -141,6 +141,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -164,6 +165,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -205,6 +208,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1.Precondition.getDefaultInstance() @@ -220,6 +224,7 @@ public com.google.firestore.v1.Precondition getCurrentDocument() { * * .google.firestore.v1.Precondition current_document = 2; */ + @java.lang.Override public com.google.firestore.v1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Document.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Document.java index 5d3512917..34121eea7 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Document.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Document.java @@ -182,6 +182,7 @@ protected com.google.protobuf.MapField internalGetMapField(int number) { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -205,6 +206,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -272,6 +274,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -279,6 +282,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -310,6 +314,7 @@ public java.util.Map getFields( * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -340,6 +345,7 @@ public java.util.Map getFieldsM * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1.Value defaultValue) { if (key == null) { @@ -376,6 +382,7 @@ public com.google.firestore.v1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -404,6 +411,7 @@ public com.google.firestore.v1.Value getFieldsOrThrow(java.lang.String key) { * * @return Whether the createTime field is set. */ + @java.lang.Override public boolean hasCreateTime() { return createTime_ != null; } @@ -421,6 +429,7 @@ public boolean hasCreateTime() { * * @return The createTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } @@ -436,6 +445,7 @@ public com.google.protobuf.Timestamp getCreateTime() { * * .google.protobuf.Timestamp create_time = 3; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return getCreateTime(); } @@ -456,6 +466,7 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return updateTime_ != null; } @@ -473,6 +484,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } @@ -488,6 +500,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return getUpdateTime(); } @@ -1070,6 +1083,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1077,6 +1091,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -1108,6 +1123,7 @@ public java.util.Map getFields( * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -1138,6 +1154,7 @@ public java.util.Map getFieldsM * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1.Value defaultValue) { if (key == null) { @@ -1174,6 +1191,7 @@ public com.google.firestore.v1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentChange.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentChange.java index 7dbb1d856..108a943dd 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentChange.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentChange.java @@ -191,6 +191,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -206,6 +207,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1.Document getDocument() { return document_ == null ? com.google.firestore.v1.Document.getDefaultInstance() : document_; } @@ -219,6 +221,7 @@ public com.google.firestore.v1.Document getDocument() { * * .google.firestore.v1.Document document = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -236,6 +239,7 @@ public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { * * @return A list containing the targetIds. */ + @java.lang.Override public java.util.List getTargetIdsList() { return targetIds_; } @@ -284,6 +288,7 @@ public int getTargetIds(int index) { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentDelete.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentDelete.java index 3aa2cb89c..fa714c4c9 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentDelete.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentDelete.java @@ -171,6 +171,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -193,6 +194,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -218,6 +220,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } @@ -267,6 +270,7 @@ public int getRemovedTargetIds(int index) { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -282,6 +286,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -295,6 +300,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentProto.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentProto.java index 48907e3e8..1acc3299b 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentProto.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentProto.java @@ -86,12 +86,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + ".Value\"\220\001\n\010MapValue\0229\n\006fields\030\001 \003(\0132).go" + "ogle.firestore.v1.MapValue.FieldsEntry\032I" + "\n\013FieldsEntry\022\013\n\003key\030\001 \001(\t\022)\n\005value\030\002 \001(" - + "\0132\032.google.firestore.v1.Value:\0028\001B\247\001\n\027co" + + "\0132\032.google.firestore.v1.Value:\0028\001B\306\001\n\027co" + "m.google.firestore.v1B\rDocumentProtoP\001Z<" + "google.golang.org/genproto/googleapis/fi" + "restore/v1;firestore\242\002\004GCFS\252\002\031Google.Clo" + "ud.Firestore.V1\312\002\031Google\\Cloud\\Firestore" - + "\\V1b\006proto3" + + "\\V1\352\002\034Google::Cloud::Firestore::V1b\006prot" + + "o3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentRemove.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentRemove.java index 347fcb5b5..5d86ab312 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentRemove.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentRemove.java @@ -172,6 +172,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -194,6 +195,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -219,6 +221,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } @@ -268,6 +271,7 @@ public int getRemovedTargetIds(int index) { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -283,6 +287,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -296,6 +301,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentTransform.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentTransform.java index 637dd4b34..f44df3dbe 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentTransform.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/DocumentTransform.java @@ -779,6 +779,10 @@ public ServerValue findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -886,6 +890,7 @@ public TransformTypeCase getTransformTypeCase() { * * @return The fieldPath. */ + @java.lang.Override public java.lang.String getFieldPath() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -909,6 +914,7 @@ public java.lang.String getFieldPath() { * * @return The bytes for fieldPath. */ + @java.lang.Override public com.google.protobuf.ByteString getFieldPathBytes() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -989,6 +995,7 @@ public int getSetToServerValueValue() { * * @return Whether the increment field is set. */ + @java.lang.Override public boolean hasIncrement() { return transformTypeCase_ == 3; } @@ -1011,6 +1018,7 @@ public boolean hasIncrement() { * * @return The increment. */ + @java.lang.Override public com.google.firestore.v1.Value getIncrement() { if (transformTypeCase_ == 3) { return (com.google.firestore.v1.Value) transformType_; @@ -1034,6 +1042,7 @@ public com.google.firestore.v1.Value getIncrement() { * * .google.firestore.v1.Value increment = 3; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getIncrementOrBuilder() { if (transformTypeCase_ == 3) { return (com.google.firestore.v1.Value) transformType_; @@ -1063,6 +1072,7 @@ public com.google.firestore.v1.ValueOrBuilder getIncrementOrBuilder() { * * @return Whether the maximum field is set. */ + @java.lang.Override public boolean hasMaximum() { return transformTypeCase_ == 4; } @@ -1087,6 +1097,7 @@ public boolean hasMaximum() { * * @return The maximum. */ + @java.lang.Override public com.google.firestore.v1.Value getMaximum() { if (transformTypeCase_ == 4) { return (com.google.firestore.v1.Value) transformType_; @@ -1112,6 +1123,7 @@ public com.google.firestore.v1.Value getMaximum() { * * .google.firestore.v1.Value maximum = 4; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getMaximumOrBuilder() { if (transformTypeCase_ == 4) { return (com.google.firestore.v1.Value) transformType_; @@ -1141,6 +1153,7 @@ public com.google.firestore.v1.ValueOrBuilder getMaximumOrBuilder() { * * @return Whether the minimum field is set. */ + @java.lang.Override public boolean hasMinimum() { return transformTypeCase_ == 5; } @@ -1165,6 +1178,7 @@ public boolean hasMinimum() { * * @return The minimum. */ + @java.lang.Override public com.google.firestore.v1.Value getMinimum() { if (transformTypeCase_ == 5) { return (com.google.firestore.v1.Value) transformType_; @@ -1190,6 +1204,7 @@ public com.google.firestore.v1.Value getMinimum() { * * .google.firestore.v1.Value minimum = 5; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getMinimumOrBuilder() { if (transformTypeCase_ == 5) { return (com.google.firestore.v1.Value) transformType_; @@ -1218,6 +1233,7 @@ public com.google.firestore.v1.ValueOrBuilder getMinimumOrBuilder() { * * @return Whether the appendMissingElements field is set. */ + @java.lang.Override public boolean hasAppendMissingElements() { return transformTypeCase_ == 6; } @@ -1241,6 +1257,7 @@ public boolean hasAppendMissingElements() { * * @return The appendMissingElements. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getAppendMissingElements() { if (transformTypeCase_ == 6) { return (com.google.firestore.v1.ArrayValue) transformType_; @@ -1265,6 +1282,7 @@ public com.google.firestore.v1.ArrayValue getAppendMissingElements() { * * .google.firestore.v1.ArrayValue append_missing_elements = 6; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getAppendMissingElementsOrBuilder() { if (transformTypeCase_ == 6) { return (com.google.firestore.v1.ArrayValue) transformType_; @@ -1291,6 +1309,7 @@ public com.google.firestore.v1.ArrayValueOrBuilder getAppendMissingElementsOrBui * * @return Whether the removeAllFromArray field is set. */ + @java.lang.Override public boolean hasRemoveAllFromArray() { return transformTypeCase_ == 7; } @@ -1312,6 +1331,7 @@ public boolean hasRemoveAllFromArray() { * * @return The removeAllFromArray. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getRemoveAllFromArray() { if (transformTypeCase_ == 7) { return (com.google.firestore.v1.ArrayValue) transformType_; @@ -1334,6 +1354,7 @@ public com.google.firestore.v1.ArrayValue getRemoveAllFromArray() { * * .google.firestore.v1.ArrayValue remove_all_from_array = 7; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getRemoveAllFromArrayOrBuilder() { if (transformTypeCase_ == 7) { return (com.google.firestore.v1.ArrayValue) transformType_; @@ -1978,6 +1999,7 @@ public Builder setFieldPathBytes(com.google.protobuf.ByteString value) { * * @return The enum numeric value on the wire for setToServerValue. */ + @java.lang.Override public int getSetToServerValueValue() { if (transformTypeCase_ == 2) { return ((java.lang.Integer) transformType_).intValue(); @@ -2017,6 +2039,7 @@ public Builder setSetToServerValueValue(int value) { * * @return The setToServerValue. */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform.FieldTransform.ServerValue getSetToServerValue() { if (transformTypeCase_ == 2) { @@ -2101,6 +2124,7 @@ public Builder clearSetToServerValue() { * * @return Whether the increment field is set. */ + @java.lang.Override public boolean hasIncrement() { return transformTypeCase_ == 3; } @@ -2123,6 +2147,7 @@ public boolean hasIncrement() { * * @return The increment. */ + @java.lang.Override public com.google.firestore.v1.Value getIncrement() { if (incrementBuilder_ == null) { if (transformTypeCase_ == 3) { @@ -2302,6 +2327,7 @@ public com.google.firestore.v1.Value.Builder getIncrementBuilder() { * * .google.firestore.v1.Value increment = 3; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getIncrementOrBuilder() { if ((transformTypeCase_ == 3) && (incrementBuilder_ != null)) { return incrementBuilder_.getMessageOrBuilder(); @@ -2380,6 +2406,7 @@ public com.google.firestore.v1.ValueOrBuilder getIncrementOrBuilder() { * * @return Whether the maximum field is set. */ + @java.lang.Override public boolean hasMaximum() { return transformTypeCase_ == 4; } @@ -2404,6 +2431,7 @@ public boolean hasMaximum() { * * @return The maximum. */ + @java.lang.Override public com.google.firestore.v1.Value getMaximum() { if (maximumBuilder_ == null) { if (transformTypeCase_ == 4) { @@ -2595,6 +2623,7 @@ public com.google.firestore.v1.Value.Builder getMaximumBuilder() { * * .google.firestore.v1.Value maximum = 4; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getMaximumOrBuilder() { if ((transformTypeCase_ == 4) && (maximumBuilder_ != null)) { return maximumBuilder_.getMessageOrBuilder(); @@ -2675,6 +2704,7 @@ public com.google.firestore.v1.ValueOrBuilder getMaximumOrBuilder() { * * @return Whether the minimum field is set. */ + @java.lang.Override public boolean hasMinimum() { return transformTypeCase_ == 5; } @@ -2699,6 +2729,7 @@ public boolean hasMinimum() { * * @return The minimum. */ + @java.lang.Override public com.google.firestore.v1.Value getMinimum() { if (minimumBuilder_ == null) { if (transformTypeCase_ == 5) { @@ -2890,6 +2921,7 @@ public com.google.firestore.v1.Value.Builder getMinimumBuilder() { * * .google.firestore.v1.Value minimum = 5; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getMinimumOrBuilder() { if ((transformTypeCase_ == 5) && (minimumBuilder_ != null)) { return minimumBuilder_.getMessageOrBuilder(); @@ -2969,6 +3001,7 @@ public com.google.firestore.v1.ValueOrBuilder getMinimumOrBuilder() { * * @return Whether the appendMissingElements field is set. */ + @java.lang.Override public boolean hasAppendMissingElements() { return transformTypeCase_ == 6; } @@ -2992,6 +3025,7 @@ public boolean hasAppendMissingElements() { * * @return The appendMissingElements. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getAppendMissingElements() { if (appendMissingElementsBuilder_ == null) { if (transformTypeCase_ == 6) { @@ -3178,6 +3212,7 @@ public com.google.firestore.v1.ArrayValue.Builder getAppendMissingElementsBuilde * * .google.firestore.v1.ArrayValue append_missing_elements = 6; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getAppendMissingElementsOrBuilder() { if ((transformTypeCase_ == 6) && (appendMissingElementsBuilder_ != null)) { return appendMissingElementsBuilder_.getMessageOrBuilder(); @@ -3254,6 +3289,7 @@ public com.google.firestore.v1.ArrayValueOrBuilder getAppendMissingElementsOrBui * * @return Whether the removeAllFromArray field is set. */ + @java.lang.Override public boolean hasRemoveAllFromArray() { return transformTypeCase_ == 7; } @@ -3275,6 +3311,7 @@ public boolean hasRemoveAllFromArray() { * * @return The removeAllFromArray. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getRemoveAllFromArray() { if (removeAllFromArrayBuilder_ == null) { if (transformTypeCase_ == 7) { @@ -3449,6 +3486,7 @@ public com.google.firestore.v1.ArrayValue.Builder getRemoveAllFromArrayBuilder() * * .google.firestore.v1.ArrayValue remove_all_from_array = 7; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getRemoveAllFromArrayOrBuilder() { if ((transformTypeCase_ == 7) && (removeAllFromArrayBuilder_ != null)) { return removeAllFromArrayBuilder_.getMessageOrBuilder(); @@ -3565,6 +3603,7 @@ public com.google.firestore.v1.DocumentTransform.FieldTransform getDefaultInstan * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -3587,6 +3626,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -3613,6 +3653,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public java.util.List getFieldTransformsList() { return fieldTransforms_; @@ -3629,6 +3670,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public java.util.List getFieldTransformsOrBuilderList() { return fieldTransforms_; @@ -3645,6 +3687,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public int getFieldTransformsCount() { return fieldTransforms_.size(); } @@ -3660,6 +3703,7 @@ public int getFieldTransformsCount() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform.FieldTransform getFieldTransforms(int index) { return fieldTransforms_.get(index); } @@ -3675,6 +3719,7 @@ public com.google.firestore.v1.DocumentTransform.FieldTransform getFieldTransfor * repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform.FieldTransformOrBuilder getFieldTransformsOrBuilder(int index) { return fieldTransforms_.get(index); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ExistenceFilter.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ExistenceFilter.java index 444c3f124..60a016650 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ExistenceFilter.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ExistenceFilter.java @@ -125,6 +125,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -144,6 +145,7 @@ public int getTargetId() { * * @return The count. */ + @java.lang.Override public int getCount() { return count_; } @@ -489,6 +491,7 @@ public Builder mergeFrom( * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -542,6 +545,7 @@ public Builder clearTargetId() { * * @return The count. */ + @java.lang.Override public int getCount() { return count_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreProto.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreProto.java index 50da056a3..28ec08f2b 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreProto.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/FirestoreProto.java @@ -87,6 +87,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_firestore_v1_RunQueryResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_firestore_v1_RunQueryResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_PartitionQueryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_PartitionQueryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_PartitionQueryResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_PartitionQueryResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_firestore_v1_WriteRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -135,6 +143,18 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_firestore_v1_ListCollectionIdsResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_firestore_v1_ListCollectionIdsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_BatchWriteRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_BatchWriteRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_BatchWriteRequest_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_BatchWriteRequest_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_BatchWriteResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_BatchWriteResponse_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -215,122 +235,148 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "nse\022\023\n\013transaction\030\002 \001(\014\022/\n\010document\030\001 \001" + "(\0132\035.google.firestore.v1.Document\022-\n\trea" + "d_time\030\003 \001(\0132\032.google.protobuf.Timestamp" - + "\022\027\n\017skipped_results\030\004 \001(\005\"\350\001\n\014WriteReque" - + "st\022\025\n\010database\030\001 \001(\tB\003\340A\002\022\021\n\tstream_id\030\002" - + " \001(\t\022*\n\006writes\030\003 \003(\0132\032.google.firestore." - + "v1.Write\022\024\n\014stream_token\030\004 \001(\014\022=\n\006labels" - + "\030\005 \003(\0132-.google.firestore.v1.WriteReques" - + "t.LabelsEntry\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(" - + "\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\242\001\n\rWriteResponse\022\021" - + "\n\tstream_id\030\001 \001(\t\022\024\n\014stream_token\030\002 \001(\014\022" - + "7\n\rwrite_results\030\003 \003(\0132 .google.firestor" - + "e.v1.WriteResult\022/\n\013commit_time\030\004 \001(\0132\032." - + "google.protobuf.Timestamp\"\362\001\n\rListenRequ" - + "est\022\025\n\010database\030\001 \001(\tB\003\340A\002\0221\n\nadd_target" - + "\030\002 \001(\0132\033.google.firestore.v1.TargetH\000\022\027\n" - + "\rremove_target\030\003 \001(\005H\000\022>\n\006labels\030\004 \003(\0132." - + ".google.firestore.v1.ListenRequest.Label" - + "sEntry\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005va" - + "lue\030\002 \001(\t:\0028\001B\017\n\rtarget_change\"\325\002\n\016Liste" - + "nResponse\022:\n\rtarget_change\030\002 \001(\0132!.googl" - + "e.firestore.v1.TargetChangeH\000\022>\n\017documen" - + "t_change\030\003 \001(\0132#.google.firestore.v1.Doc" - + "umentChangeH\000\022>\n\017document_delete\030\004 \001(\0132#" - + ".google.firestore.v1.DocumentDeleteH\000\022>\n" - + "\017document_remove\030\006 \001(\0132#.google.firestor" - + "e.v1.DocumentRemoveH\000\0226\n\006filter\030\005 \001(\0132$." - + "google.firestore.v1.ExistenceFilterH\000B\017\n" - + "\rresponse_type\"\241\003\n\006Target\0228\n\005query\030\002 \001(\013" - + "2\'.google.firestore.v1.Target.QueryTarge" - + "tH\000\022@\n\tdocuments\030\003 \001(\0132+.google.firestor" - + "e.v1.Target.DocumentsTargetH\000\022\026\n\014resume_" - + "token\030\004 \001(\014H\001\022/\n\tread_time\030\013 \001(\0132\032.googl" - + "e.protobuf.TimestampH\001\022\021\n\ttarget_id\030\005 \001(" - + "\005\022\014\n\004once\030\006 \001(\010\032$\n\017DocumentsTarget\022\021\n\tdo" - + "cuments\030\002 \003(\t\032m\n\013QueryTarget\022\016\n\006parent\030\001" - + " \001(\t\022@\n\020structured_query\030\002 \001(\0132$.google." - + "firestore.v1.StructuredQueryH\000B\014\n\nquery_" - + "typeB\r\n\013target_typeB\r\n\013resume_type\"\252\002\n\014T" - + "argetChange\022N\n\022target_change_type\030\001 \001(\0162" - + "2.google.firestore.v1.TargetChange.Targe" - + "tChangeType\022\022\n\ntarget_ids\030\002 \003(\005\022!\n\005cause" - + "\030\003 \001(\0132\022.google.rpc.Status\022\024\n\014resume_tok" - + "en\030\004 \001(\014\022-\n\tread_time\030\006 \001(\0132\032.google.pro" - + "tobuf.Timestamp\"N\n\020TargetChangeType\022\r\n\tN" - + "O_CHANGE\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE\020\002\022\013\n\007CURRE" - + "NT\020\003\022\t\n\005RESET\020\004\"V\n\030ListCollectionIdsRequ" - + "est\022\023\n\006parent\030\001 \001(\tB\003\340A\002\022\021\n\tpage_size\030\002 " - + "\001(\005\022\022\n\npage_token\030\003 \001(\t\"L\n\031ListCollectio" - + "nIdsResponse\022\026\n\016collection_ids\030\001 \003(\t\022\027\n\017" - + "next_page_token\030\002 \001(\t2\327\023\n\tFirestore\022\217\001\n\013" - + "GetDocument\022\'.google.firestore.v1.GetDoc" - + "umentRequest\032\035.google.firestore.v1.Docum" - + "ent\"8\202\323\344\223\0022\0220/v1/{name=projects/*/databa" - + "ses/*/documents/*/**}\022\262\001\n\rListDocuments\022" - + ").google.firestore.v1.ListDocumentsReque" - + "st\032*.google.firestore.v1.ListDocumentsRe" - + "sponse\"J\202\323\344\223\002D\022B/v1/{parent=projects/*/d" - + "atabases/*/documents/*/**}/{collection_i" - + "d}\022\277\001\n\016UpdateDocument\022*.google.firestore" - + ".v1.UpdateDocumentRequest\032\035.google.fires" - + "tore.v1.Document\"b\202\323\344\223\002E29/v1/{document." - + "name=projects/*/databases/*/documents/*/" - + "**}:\010document\332A\024document,update_mask\022\225\001\n" - + "\016DeleteDocument\022*.google.firestore.v1.De" - + "leteDocumentRequest\032\026.google.protobuf.Em" - + "pty\"?\202\323\344\223\0022*0/v1/{name=projects/*/databa" - + "ses/*/documents/*/**}\332A\004name\022\271\001\n\021BatchGe" - + "tDocuments\022-.google.firestore.v1.BatchGe" - + "tDocumentsRequest\032..google.firestore.v1." - + "BatchGetDocumentsResponse\"C\202\323\344\223\002=\"8/v1/{" - + "database=projects/*/databases/*}/documen" - + "ts:batchGet:\001*0\001\022\307\001\n\020BeginTransaction\022,." - + "google.firestore.v1.BeginTransactionRequ" - + "est\032-.google.firestore.v1.BeginTransacti" - + "onResponse\"V\202\323\344\223\002E\"@/v1/{database=projec" - + "ts/*/databases/*}/documents:beginTransac" - + "tion:\001*\332A\010database\022\246\001\n\006Commit\022\".google.f" - + "irestore.v1.CommitRequest\032#.google.fires" - + "tore.v1.CommitResponse\"S\202\323\344\223\002;\"6/v1/{dat" - + "abase=projects/*/databases/*}/documents:" - + "commit:\001*\332A\017database,writes\022\244\001\n\010Rollback" - + "\022$.google.firestore.v1.RollbackRequest\032\026" - + ".google.protobuf.Empty\"Z\202\323\344\223\002=\"8/v1/{dat" - + "abase=projects/*/databases/*}/documents:" - + "rollback:\001*\332A\024database,transaction\022\337\001\n\010R" - + "unQuery\022$.google.firestore.v1.RunQueryRe" - + "quest\032%.google.firestore.v1.RunQueryResp" - + "onse\"\203\001\202\323\344\223\002}\"6/v1/{parent=projects/*/da" - + "tabases/*/documents}:runQuery:\001*Z@\";/v1/" - + "{parent=projects/*/databases/*/documents" - + "/*/**}:runQuery:\001*0\001\022\224\001\n\005Write\022!.google." - + "firestore.v1.WriteRequest\032\".google.fires" - + "tore.v1.WriteResponse\"@\202\323\344\223\002:\"5/v1/{data" - + "base=projects/*/databases/*}/documents:w" - + "rite:\001*(\0010\001\022\230\001\n\006Listen\022\".google.firestor" - + "e.v1.ListenRequest\032#.google.firestore.v1" - + ".ListenResponse\"A\202\323\344\223\002;\"6/v1/{database=p" - + "rojects/*/databases/*}/documents:listen:" - + "\001*(\0010\001\022\224\002\n\021ListCollectionIds\022-.google.fi" - + "restore.v1.ListCollectionIdsRequest\032..go" - + "ogle.firestore.v1.ListCollectionIdsRespo" - + "nse\"\237\001\202\323\344\223\002\217\001\"?/v1/{parent=projects/*/da" - + "tabases/*/documents}:listCollectionIds:\001" - + "*ZI\"D/v1/{parent=projects/*/databases/*/" - + "documents/*/**}:listCollectionIds:\001*\332A\006p" - + "arent\022\257\001\n\016CreateDocument\022*.google.firest" - + "ore.v1.CreateDocumentRequest\032\035.google.fi" - + "restore.v1.Document\"R\202\323\344\223\002L\"@/v1/{parent" - + "=projects/*/databases/*/documents/**}/{c" - + "ollection_id}:\010document\032v\312A\030firestore.go" - + "ogleapis.com\322AXhttps://www.googleapis.co" - + "m/auth/cloud-platform,https://www.google" - + "apis.com/auth/datastoreB\250\001\n\027com.google.f" - + "irestore.v1B\016FirestoreProtoP\001Z\n\006lab" + + "els\030\004 \003(\0132..google.firestore.v1.ListenRe" + + "quest.LabelsEntry\032-\n\013LabelsEntry\022\013\n\003key\030" + + "\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001B\017\n\rtarget_chang" + + "e\"\325\002\n\016ListenResponse\022:\n\rtarget_change\030\002 " + + "\001(\0132!.google.firestore.v1.TargetChangeH\000" + + "\022>\n\017document_change\030\003 \001(\0132#.google.fires" + + "tore.v1.DocumentChangeH\000\022>\n\017document_del" + + "ete\030\004 \001(\0132#.google.firestore.v1.Document" + + "DeleteH\000\022>\n\017document_remove\030\006 \001(\0132#.goog" + + "le.firestore.v1.DocumentRemoveH\000\0226\n\006filt" + + "er\030\005 \001(\0132$.google.firestore.v1.Existence" + + "FilterH\000B\017\n\rresponse_type\"\241\003\n\006Target\0228\n\005" + + "query\030\002 \001(\0132\'.google.firestore.v1.Target" + + ".QueryTargetH\000\022@\n\tdocuments\030\003 \001(\0132+.goog" + + "le.firestore.v1.Target.DocumentsTargetH\000" + + "\022\026\n\014resume_token\030\004 \001(\014H\001\022/\n\tread_time\030\013 " + + "\001(\0132\032.google.protobuf.TimestampH\001\022\021\n\ttar" + + "get_id\030\005 \001(\005\022\014\n\004once\030\006 \001(\010\032$\n\017DocumentsT" + + "arget\022\021\n\tdocuments\030\002 \003(\t\032m\n\013QueryTarget\022" + + "\016\n\006parent\030\001 \001(\t\022@\n\020structured_query\030\002 \001(" + + "\0132$.google.firestore.v1.StructuredQueryH" + + "\000B\014\n\nquery_typeB\r\n\013target_typeB\r\n\013resume" + + "_type\"\252\002\n\014TargetChange\022N\n\022target_change_" + + "type\030\001 \001(\01622.google.firestore.v1.TargetC" + + "hange.TargetChangeType\022\022\n\ntarget_ids\030\002 \003" + + "(\005\022!\n\005cause\030\003 \001(\0132\022.google.rpc.Status\022\024\n" + + "\014resume_token\030\004 \001(\014\022-\n\tread_time\030\006 \001(\0132\032" + + ".google.protobuf.Timestamp\"N\n\020TargetChan" + + "geType\022\r\n\tNO_CHANGE\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE" + + "\020\002\022\013\n\007CURRENT\020\003\022\t\n\005RESET\020\004\"V\n\030ListCollec" + + "tionIdsRequest\022\023\n\006parent\030\001 \001(\tB\003\340A\002\022\021\n\tp" + + "age_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"L\n\031Li" + + "stCollectionIdsResponse\022\026\n\016collection_id" + + "s\030\001 \003(\t\022\027\n\017next_page_token\030\002 \001(\t\"\311\001\n\021Bat" + + "chWriteRequest\022\025\n\010database\030\001 \001(\tB\003\340A\002\022*\n" + + "\006writes\030\002 \003(\0132\032.google.firestore.v1.Writ" + + "e\022B\n\006labels\030\003 \003(\01322.google.firestore.v1." + + "BatchWriteRequest.LabelsEntry\032-\n\013LabelsE" + + "ntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"q\n\022" + + "BatchWriteResponse\0227\n\rwrite_results\030\001 \003(" + + "\0132 .google.firestore.v1.WriteResult\022\"\n\006s" + + "tatus\030\002 \003(\0132\022.google.rpc.Status2\375\026\n\tFire" + + "store\022\217\001\n\013GetDocument\022\'.google.firestore" + + ".v1.GetDocumentRequest\032\035.google.firestor" + + "e.v1.Document\"8\202\323\344\223\0022\0220/v1/{name=project" + + "s/*/databases/*/documents/*/**}\022\262\001\n\rList" + + "Documents\022).google.firestore.v1.ListDocu" + + "mentsRequest\032*.google.firestore.v1.ListD" + + "ocumentsResponse\"J\202\323\344\223\002D\022B/v1/{parent=pr" + + "ojects/*/databases/*/documents/*/**}/{co" + + "llection_id}\022\277\001\n\016UpdateDocument\022*.google" + + ".firestore.v1.UpdateDocumentRequest\032\035.go" + + "ogle.firestore.v1.Document\"b\202\323\344\223\002E29/v1/" + + "{document.name=projects/*/databases/*/do" + + "cuments/*/**}:\010document\332A\024document,updat" + + "e_mask\022\225\001\n\016DeleteDocument\022*.google.fires" + + "tore.v1.DeleteDocumentRequest\032\026.google.p" + + "rotobuf.Empty\"?\202\323\344\223\0022*0/v1/{name=project" + + "s/*/databases/*/documents/*/**}\332A\004name\022\271" + + "\001\n\021BatchGetDocuments\022-.google.firestore." + + "v1.BatchGetDocumentsRequest\032..google.fir" + + "estore.v1.BatchGetDocumentsResponse\"C\202\323\344" + + "\223\002=\"8/v1/{database=projects/*/databases/" + + "*}/documents:batchGet:\001*0\001\022\307\001\n\020BeginTran" + + "saction\022,.google.firestore.v1.BeginTrans" + + "actionRequest\032-.google.firestore.v1.Begi" + + "nTransactionResponse\"V\202\323\344\223\002E\"@/v1/{datab" + + "ase=projects/*/databases/*}/documents:be" + + "ginTransaction:\001*\332A\010database\022\246\001\n\006Commit\022" + + "\".google.firestore.v1.CommitRequest\032#.go" + + "ogle.firestore.v1.CommitResponse\"S\202\323\344\223\002;" + + "\"6/v1/{database=projects/*/databases/*}/" + + "documents:commit:\001*\332A\017database,writes\022\244\001" + + "\n\010Rollback\022$.google.firestore.v1.Rollbac" + + "kRequest\032\026.google.protobuf.Empty\"Z\202\323\344\223\002=" + + "\"8/v1/{database=projects/*/databases/*}/" + + "documents:rollback:\001*\332A\024database,transac" + + "tion\022\337\001\n\010RunQuery\022$.google.firestore.v1." + + "RunQueryRequest\032%.google.firestore.v1.Ru" + + "nQueryResponse\"\203\001\202\323\344\223\002}\"6/v1/{parent=pro" + + "jects/*/databases/*/documents}:runQuery:" + + "\001*Z@\";/v1/{parent=projects/*/databases/*" + + "/documents/*/**}:runQuery:\001*0\001\022\374\001\n\016Parti" + + "tionQuery\022*.google.firestore.v1.Partitio" + + "nQueryRequest\032+.google.firestore.v1.Part" + + "itionQueryResponse\"\220\001\202\323\344\223\002\211\001\".google.firestore.v1.DocumentMask mask = 2; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -305,6 +310,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 3) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -318,13 +324,14 @@ public com.google.protobuf.ByteString getTransaction() { * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 5; } @@ -333,13 +340,14 @@ public boolean hasReadTime() { * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -351,11 +359,12 @@ public com.google.protobuf.Timestamp getReadTime() { * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1167,13 +1176,14 @@ public Builder clearTransaction() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 5; } @@ -1182,13 +1192,14 @@ public boolean hasReadTime() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 5) { @@ -1207,7 +1218,7 @@ public com.google.protobuf.Timestamp getReadTime() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; @@ -1230,7 +1241,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; @@ -1250,7 +1261,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp.Builder builderForValue * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; @@ -1282,7 +1293,7 @@ public Builder mergeReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; @@ -1308,7 +1319,7 @@ public Builder clearReadTime() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; @@ -1321,11 +1332,12 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 5) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -1341,7 +1353,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * *
      * Reads the version of the document at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 5; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/GetDocumentRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/GetDocumentRequestOrBuilder.java index 8a9143bad..3fd4be1a7 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/GetDocumentRequestOrBuilder.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/GetDocumentRequestOrBuilder.java @@ -109,7 +109,7 @@ public interface GetDocumentRequestOrBuilder * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; @@ -122,7 +122,7 @@ public interface GetDocumentRequestOrBuilder * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; @@ -135,7 +135,7 @@ public interface GetDocumentRequestOrBuilder * *
    * Reads the version of the document at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 5; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsRequest.java index 93518a6d7..e180036d7 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsRequest.java @@ -140,6 +140,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -165,6 +166,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -208,6 +211,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -231,6 +235,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -724,6 +729,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsResponse.java index 4bccaafb0..c94981ee8 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListCollectionIdsResponse.java @@ -200,6 +200,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -222,6 +223,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequest.java index 5a0591fec..7d45c0d11 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequest.java @@ -247,6 +247,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -274,6 +275,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -300,6 +302,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The collectionId. */ + @java.lang.Override public java.lang.String getCollectionId() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -323,6 +326,7 @@ public java.lang.String getCollectionId() { * * @return The bytes for collectionId. */ + @java.lang.Override public com.google.protobuf.ByteString getCollectionIdBytes() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -348,6 +352,7 @@ public com.google.protobuf.ByteString getCollectionIdBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -365,6 +370,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -387,6 +393,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -412,6 +419,7 @@ public com.google.protobuf.ByteString getPageTokenBytes() { * * @return The orderBy. */ + @java.lang.Override public java.lang.String getOrderBy() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { @@ -434,6 +442,7 @@ public java.lang.String getOrderBy() { * * @return The bytes for orderBy. */ + @java.lang.Override public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { @@ -461,6 +470,7 @@ public com.google.protobuf.ByteString getOrderByBytes() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -477,6 +487,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() : mask_; } @@ -491,6 +502,7 @@ public com.google.firestore.v1.DocumentMask getMask() { * * .google.firestore.v1.DocumentMask mask = 7; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -507,6 +519,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 8) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -520,13 +533,14 @@ public com.google.protobuf.ByteString getTransaction() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 10; } @@ -535,13 +549,14 @@ public boolean hasReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 10) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -553,11 +568,12 @@ public com.google.protobuf.Timestamp getReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 10) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -583,6 +599,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The showMissing. */ + @java.lang.Override public boolean getShowMissing() { return showMissing_; } @@ -1345,6 +1362,7 @@ public Builder setCollectionIdBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -1863,13 +1881,14 @@ public Builder clearTransaction() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 10; } @@ -1878,13 +1897,14 @@ public boolean hasReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 10) { @@ -1903,7 +1923,7 @@ public com.google.protobuf.Timestamp getReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -1926,7 +1946,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -1946,7 +1966,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp.Builder builderForValue * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -1978,7 +1998,7 @@ public Builder mergeReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -2004,7 +2024,7 @@ public Builder clearReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -2017,11 +2037,12 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 10) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -2037,7 +2058,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 10; @@ -2084,6 +2105,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The showMissing. */ + @java.lang.Override public boolean getShowMissing() { return showMissing_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequestOrBuilder.java index f3293a116..7ff66b64b 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequestOrBuilder.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsRequestOrBuilder.java @@ -207,7 +207,7 @@ public interface ListDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; @@ -220,7 +220,7 @@ public interface ListDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; @@ -233,7 +233,7 @@ public interface ListDocumentsRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 10; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsResponse.java index 1b487f2fd..7995f3dc7 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListDocumentsResponse.java @@ -137,6 +137,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1.Document documents = 1; */ + @java.lang.Override public java.util.List getDocumentsList() { return documents_; } @@ -149,6 +150,7 @@ public java.util.List getDocumentsList() { * * repeated .google.firestore.v1.Document documents = 1; */ + @java.lang.Override public java.util.List getDocumentsOrBuilderList() { return documents_; @@ -162,6 +164,7 @@ public java.util.List getDocumentsList() { * * repeated .google.firestore.v1.Document documents = 1; */ + @java.lang.Override public int getDocumentsCount() { return documents_.size(); } @@ -174,6 +177,7 @@ public int getDocumentsCount() { * * repeated .google.firestore.v1.Document documents = 1; */ + @java.lang.Override public com.google.firestore.v1.Document getDocuments(int index) { return documents_.get(index); } @@ -186,6 +190,7 @@ public com.google.firestore.v1.Document getDocuments(int index) { * * repeated .google.firestore.v1.Document documents = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getDocumentsOrBuilder(int index) { return documents_.get(index); } @@ -203,6 +208,7 @@ public com.google.firestore.v1.DocumentOrBuilder getDocumentsOrBuilder(int index * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -225,6 +231,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenRequest.java index b0ffbc148..80238b7b1 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenRequest.java @@ -218,6 +218,7 @@ public TargetChangeCase getTargetChangeCase() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -241,6 +242,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -265,6 +267,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return Whether the addTarget field is set. */ + @java.lang.Override public boolean hasAddTarget() { return targetChangeCase_ == 2; } @@ -279,6 +282,7 @@ public boolean hasAddTarget() { * * @return The addTarget. */ + @java.lang.Override public com.google.firestore.v1.Target getAddTarget() { if (targetChangeCase_ == 2) { return (com.google.firestore.v1.Target) targetChange_; @@ -294,6 +298,7 @@ public com.google.firestore.v1.Target getAddTarget() { * * .google.firestore.v1.Target add_target = 2; */ + @java.lang.Override public com.google.firestore.v1.TargetOrBuilder getAddTargetOrBuilder() { if (targetChangeCase_ == 2) { return (com.google.firestore.v1.Target) targetChange_; @@ -313,6 +318,7 @@ public com.google.firestore.v1.TargetOrBuilder getAddTargetOrBuilder() { * * @return The removeTarget. */ + @java.lang.Override public int getRemoveTarget() { if (targetChangeCase_ == 3) { return (java.lang.Integer) targetChange_; @@ -354,6 +360,7 @@ public int getLabelsCount() { * * map<string, string> labels = 4; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -361,6 +368,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -374,6 +382,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -386,6 +395,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); @@ -402,6 +412,7 @@ public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.Strin * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -980,6 +991,7 @@ public Builder setDatabaseBytes(com.google.protobuf.ByteString value) { * * @return Whether the addTarget field is set. */ + @java.lang.Override public boolean hasAddTarget() { return targetChangeCase_ == 2; } @@ -994,6 +1006,7 @@ public boolean hasAddTarget() { * * @return The addTarget. */ + @java.lang.Override public com.google.firestore.v1.Target getAddTarget() { if (addTargetBuilder_ == null) { if (targetChangeCase_ == 2) { @@ -1125,6 +1138,7 @@ public com.google.firestore.v1.Target.Builder getAddTargetBuilder() { * * .google.firestore.v1.Target add_target = 2; */ + @java.lang.Override public com.google.firestore.v1.TargetOrBuilder getAddTargetOrBuilder() { if ((targetChangeCase_ == 2) && (addTargetBuilder_ != null)) { return addTargetBuilder_.getMessageOrBuilder(); @@ -1256,6 +1270,7 @@ public int getLabelsCount() { * * map<string, string> labels = 4; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1263,6 +1278,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -1276,6 +1292,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -1288,6 +1305,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { @@ -1305,6 +1323,7 @@ public java.lang.String getLabelsOrDefault( * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenResponse.java index a3763a6d1..6532c1694 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/ListenResponse.java @@ -250,6 +250,7 @@ public ResponseTypeCase getResponseTypeCase() { * * @return Whether the targetChange field is set. */ + @java.lang.Override public boolean hasTargetChange() { return responseTypeCase_ == 2; } @@ -264,6 +265,7 @@ public boolean hasTargetChange() { * * @return The targetChange. */ + @java.lang.Override public com.google.firestore.v1.TargetChange getTargetChange() { if (responseTypeCase_ == 2) { return (com.google.firestore.v1.TargetChange) responseType_; @@ -279,6 +281,7 @@ public com.google.firestore.v1.TargetChange getTargetChange() { * * .google.firestore.v1.TargetChange target_change = 2; */ + @java.lang.Override public com.google.firestore.v1.TargetChangeOrBuilder getTargetChangeOrBuilder() { if (responseTypeCase_ == 2) { return (com.google.firestore.v1.TargetChange) responseType_; @@ -298,6 +301,7 @@ public com.google.firestore.v1.TargetChangeOrBuilder getTargetChangeOrBuilder() * * @return Whether the documentChange field is set. */ + @java.lang.Override public boolean hasDocumentChange() { return responseTypeCase_ == 3; } @@ -312,6 +316,7 @@ public boolean hasDocumentChange() { * * @return The documentChange. */ + @java.lang.Override public com.google.firestore.v1.DocumentChange getDocumentChange() { if (responseTypeCase_ == 3) { return (com.google.firestore.v1.DocumentChange) responseType_; @@ -327,6 +332,7 @@ public com.google.firestore.v1.DocumentChange getDocumentChange() { * * .google.firestore.v1.DocumentChange document_change = 3; */ + @java.lang.Override public com.google.firestore.v1.DocumentChangeOrBuilder getDocumentChangeOrBuilder() { if (responseTypeCase_ == 3) { return (com.google.firestore.v1.DocumentChange) responseType_; @@ -346,6 +352,7 @@ public com.google.firestore.v1.DocumentChangeOrBuilder getDocumentChangeOrBuilde * * @return Whether the documentDelete field is set. */ + @java.lang.Override public boolean hasDocumentDelete() { return responseTypeCase_ == 4; } @@ -360,6 +367,7 @@ public boolean hasDocumentDelete() { * * @return The documentDelete. */ + @java.lang.Override public com.google.firestore.v1.DocumentDelete getDocumentDelete() { if (responseTypeCase_ == 4) { return (com.google.firestore.v1.DocumentDelete) responseType_; @@ -375,6 +383,7 @@ public com.google.firestore.v1.DocumentDelete getDocumentDelete() { * * .google.firestore.v1.DocumentDelete document_delete = 4; */ + @java.lang.Override public com.google.firestore.v1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilder() { if (responseTypeCase_ == 4) { return (com.google.firestore.v1.DocumentDelete) responseType_; @@ -395,6 +404,7 @@ public com.google.firestore.v1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilde * * @return Whether the documentRemove field is set. */ + @java.lang.Override public boolean hasDocumentRemove() { return responseTypeCase_ == 6; } @@ -410,6 +420,7 @@ public boolean hasDocumentRemove() { * * @return The documentRemove. */ + @java.lang.Override public com.google.firestore.v1.DocumentRemove getDocumentRemove() { if (responseTypeCase_ == 6) { return (com.google.firestore.v1.DocumentRemove) responseType_; @@ -426,6 +437,7 @@ public com.google.firestore.v1.DocumentRemove getDocumentRemove() { * * .google.firestore.v1.DocumentRemove document_remove = 6; */ + @java.lang.Override public com.google.firestore.v1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilder() { if (responseTypeCase_ == 6) { return (com.google.firestore.v1.DocumentRemove) responseType_; @@ -448,6 +460,7 @@ public com.google.firestore.v1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilde * * @return Whether the filter field is set. */ + @java.lang.Override public boolean hasFilter() { return responseTypeCase_ == 5; } @@ -465,6 +478,7 @@ public boolean hasFilter() { * * @return The filter. */ + @java.lang.Override public com.google.firestore.v1.ExistenceFilter getFilter() { if (responseTypeCase_ == 5) { return (com.google.firestore.v1.ExistenceFilter) responseType_; @@ -483,6 +497,7 @@ public com.google.firestore.v1.ExistenceFilter getFilter() { * * .google.firestore.v1.ExistenceFilter filter = 5; */ + @java.lang.Override public com.google.firestore.v1.ExistenceFilterOrBuilder getFilterOrBuilder() { if (responseTypeCase_ == 5) { return (com.google.firestore.v1.ExistenceFilter) responseType_; @@ -972,6 +987,7 @@ public Builder clearResponseType() { * * @return Whether the targetChange field is set. */ + @java.lang.Override public boolean hasTargetChange() { return responseTypeCase_ == 2; } @@ -986,6 +1002,7 @@ public boolean hasTargetChange() { * * @return The targetChange. */ + @java.lang.Override public com.google.firestore.v1.TargetChange getTargetChange() { if (targetChangeBuilder_ == null) { if (responseTypeCase_ == 2) { @@ -1117,6 +1134,7 @@ public com.google.firestore.v1.TargetChange.Builder getTargetChangeBuilder() { * * .google.firestore.v1.TargetChange target_change = 2; */ + @java.lang.Override public com.google.firestore.v1.TargetChangeOrBuilder getTargetChangeOrBuilder() { if ((responseTypeCase_ == 2) && (targetChangeBuilder_ != null)) { return targetChangeBuilder_.getMessageOrBuilder(); @@ -1177,6 +1195,7 @@ public com.google.firestore.v1.TargetChangeOrBuilder getTargetChangeOrBuilder() * * @return Whether the documentChange field is set. */ + @java.lang.Override public boolean hasDocumentChange() { return responseTypeCase_ == 3; } @@ -1191,6 +1210,7 @@ public boolean hasDocumentChange() { * * @return The documentChange. */ + @java.lang.Override public com.google.firestore.v1.DocumentChange getDocumentChange() { if (documentChangeBuilder_ == null) { if (responseTypeCase_ == 3) { @@ -1323,6 +1343,7 @@ public com.google.firestore.v1.DocumentChange.Builder getDocumentChangeBuilder() * * .google.firestore.v1.DocumentChange document_change = 3; */ + @java.lang.Override public com.google.firestore.v1.DocumentChangeOrBuilder getDocumentChangeOrBuilder() { if ((responseTypeCase_ == 3) && (documentChangeBuilder_ != null)) { return documentChangeBuilder_.getMessageOrBuilder(); @@ -1383,6 +1404,7 @@ public com.google.firestore.v1.DocumentChangeOrBuilder getDocumentChangeOrBuilde * * @return Whether the documentDelete field is set. */ + @java.lang.Override public boolean hasDocumentDelete() { return responseTypeCase_ == 4; } @@ -1397,6 +1419,7 @@ public boolean hasDocumentDelete() { * * @return The documentDelete. */ + @java.lang.Override public com.google.firestore.v1.DocumentDelete getDocumentDelete() { if (documentDeleteBuilder_ == null) { if (responseTypeCase_ == 4) { @@ -1529,6 +1552,7 @@ public com.google.firestore.v1.DocumentDelete.Builder getDocumentDeleteBuilder() * * .google.firestore.v1.DocumentDelete document_delete = 4; */ + @java.lang.Override public com.google.firestore.v1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilder() { if ((responseTypeCase_ == 4) && (documentDeleteBuilder_ != null)) { return documentDeleteBuilder_.getMessageOrBuilder(); @@ -1590,6 +1614,7 @@ public com.google.firestore.v1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilde * * @return Whether the documentRemove field is set. */ + @java.lang.Override public boolean hasDocumentRemove() { return responseTypeCase_ == 6; } @@ -1605,6 +1630,7 @@ public boolean hasDocumentRemove() { * * @return The documentRemove. */ + @java.lang.Override public com.google.firestore.v1.DocumentRemove getDocumentRemove() { if (documentRemoveBuilder_ == null) { if (responseTypeCase_ == 6) { @@ -1743,6 +1769,7 @@ public com.google.firestore.v1.DocumentRemove.Builder getDocumentRemoveBuilder() * * .google.firestore.v1.DocumentRemove document_remove = 6; */ + @java.lang.Override public com.google.firestore.v1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilder() { if ((responseTypeCase_ == 6) && (documentRemoveBuilder_ != null)) { return documentRemoveBuilder_.getMessageOrBuilder(); @@ -1807,6 +1834,7 @@ public com.google.firestore.v1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilde * * @return Whether the filter field is set. */ + @java.lang.Override public boolean hasFilter() { return responseTypeCase_ == 5; } @@ -1824,6 +1852,7 @@ public boolean hasFilter() { * * @return The filter. */ + @java.lang.Override public com.google.firestore.v1.ExistenceFilter getFilter() { if (filterBuilder_ == null) { if (responseTypeCase_ == 5) { @@ -1973,6 +2002,7 @@ public com.google.firestore.v1.ExistenceFilter.Builder getFilterBuilder() { * * .google.firestore.v1.ExistenceFilter filter = 5; */ + @java.lang.Override public com.google.firestore.v1.ExistenceFilterOrBuilder getFilterOrBuilder() { if ((responseTypeCase_ == 5) && (filterBuilder_ != null)) { return filterBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/MapValue.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/MapValue.java index 0ca9795df..88c0f17ff 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/MapValue.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/MapValue.java @@ -169,6 +169,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -176,6 +177,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -193,6 +195,7 @@ public java.util.Map getFields( * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -209,6 +212,7 @@ public java.util.Map getFieldsM * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1.Value defaultValue) { if (key == null) { @@ -231,6 +235,7 @@ public com.google.firestore.v1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -623,6 +628,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -630,6 +636,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -647,6 +654,7 @@ public java.util.Map getFields( * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -663,6 +671,7 @@ public java.util.Map getFieldsM * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1.Value defaultValue) { if (key == null) { @@ -685,6 +694,7 @@ public com.google.firestore.v1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequest.java new file mode 100644 index 000000000..d2e156566 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequest.java @@ -0,0 +1,1524 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +/** + * + * + *
+ * The request for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery].
+ * 
+ * + * Protobuf type {@code google.firestore.v1.PartitionQueryRequest} + */ +public final class PartitionQueryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.firestore.v1.PartitionQueryRequest) + PartitionQueryRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use PartitionQueryRequest.newBuilder() to construct. + private PartitionQueryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private PartitionQueryRequest() { + parent_ = ""; + pageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new PartitionQueryRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private PartitionQueryRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: + { + com.google.firestore.v1.StructuredQuery.Builder subBuilder = null; + if (queryTypeCase_ == 2) { + subBuilder = ((com.google.firestore.v1.StructuredQuery) queryType_).toBuilder(); + } + queryType_ = + input.readMessage( + com.google.firestore.v1.StructuredQuery.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.firestore.v1.StructuredQuery) queryType_); + queryType_ = subBuilder.buildPartial(); + } + queryTypeCase_ = 2; + break; + } + case 24: + { + partitionCount_ = input.readInt64(); + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + pageToken_ = s; + break; + } + case 40: + { + pageSize_ = input.readInt32(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.PartitionQueryRequest.class, + com.google.firestore.v1.PartitionQueryRequest.Builder.class); + } + + private int queryTypeCase_ = 0; + private java.lang.Object queryType_; + + public enum QueryTypeCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + STRUCTURED_QUERY(2), + QUERYTYPE_NOT_SET(0); + private final int value; + + private QueryTypeCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static QueryTypeCase valueOf(int value) { + return forNumber(value); + } + + public static QueryTypeCase forNumber(int value) { + switch (value) { + case 2: + return STRUCTURED_QUERY; + case 0: + return QUERYTYPE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public QueryTypeCase getQueryTypeCase() { + return QueryTypeCase.forNumber(queryTypeCase_); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent resource name. In the format:
+   * `projects/{project_id}/databases/{database_id}/documents`.
+   * Document resource names are not supported; only database resource names
+   * can be specified.
+   * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent resource name. In the format:
+   * `projects/{project_id}/databases/{database_id}/documents`.
+   * Document resource names are not supported; only database resource names
+   * can be specified.
+   * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STRUCTURED_QUERY_FIELD_NUMBER = 2; + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return Whether the structuredQuery field is set. + */ + @java.lang.Override + public boolean hasStructuredQuery() { + return queryTypeCase_ == 2; + } + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return The structuredQuery. + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery getStructuredQuery() { + if (queryTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery) queryType_; + } + return com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { + if (queryTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery) queryType_; + } + return com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } + + public static final int PARTITION_COUNT_FIELD_NUMBER = 3; + private long partitionCount_; + /** + * + * + *
+   * The desired maximum number of partition points.
+   * The partitions may be returned across multiple pages of results.
+   * The number must be strictly positive. The actual number of partitions
+   * returned may be fewer.
+   * For example, this may be set to one fewer than the number of parallel
+   * queries to be run, or in running a data pipeline job, one fewer than the
+   * number of workers or compute instances available.
+   * 
+ * + * int64 partition_count = 3; + * + * @return The partitionCount. + */ + @java.lang.Override + public long getPartitionCount() { + return partitionCount_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 4; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The `next_page_token` value returned from a previous call to
+   * PartitionQuery that may be used to get an additional set of results.
+   * There are no ordering guarantees between sets of results. Thus, using
+   * multiple sets of results will require merging the different result sets.
+   * For example, two subsequent calls using a page_token may return:
+   *  * cursor B, cursor M, cursor Q
+   *  * cursor A, cursor U, cursor W
+   * To obtain a complete result set ordered with respect to the results of the
+   * query supplied to PartitionQuery, the results sets should be merged:
+   * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+   * 
+ * + * string page_token = 4; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + /** + * + * + *
+   * The `next_page_token` value returned from a previous call to
+   * PartitionQuery that may be used to get an additional set of results.
+   * There are no ordering guarantees between sets of results. Thus, using
+   * multiple sets of results will require merging the different result sets.
+   * For example, two subsequent calls using a page_token may return:
+   *  * cursor B, cursor M, cursor Q
+   *  * cursor A, cursor U, cursor W
+   * To obtain a complete result set ordered with respect to the results of the
+   * query supplied to PartitionQuery, the results sets should be merged:
+   * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+   * 
+ * + * string page_token = 4; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 5; + private int pageSize_; + /** + * + * + *
+   * The maximum number of partitions to return in this call, subject to
+   * `partition_count`.
+   * For example, if `partition_count` = 10 and `page_size` = 8, the first call
+   * to PartitionQuery will return up to 8 partitions and a `next_page_token`
+   * if more results exist. A second call to PartitionQuery will return up to
+   * 2 partitions, to complete the total of 10 specified in `partition_count`.
+   * 
+ * + * int32 page_size = 5; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (queryTypeCase_ == 2) { + output.writeMessage(2, (com.google.firestore.v1.StructuredQuery) queryType_); + } + if (partitionCount_ != 0L) { + output.writeInt64(3, partitionCount_); + } + if (!getPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_); + } + if (pageSize_ != 0) { + output.writeInt32(5, pageSize_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (queryTypeCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.firestore.v1.StructuredQuery) queryType_); + } + if (partitionCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, partitionCount_); + } + if (!getPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(5, pageSize_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.firestore.v1.PartitionQueryRequest)) { + return super.equals(obj); + } + com.google.firestore.v1.PartitionQueryRequest other = + (com.google.firestore.v1.PartitionQueryRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPartitionCount() != other.getPartitionCount()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getQueryTypeCase().equals(other.getQueryTypeCase())) return false; + switch (queryTypeCase_) { + case 2: + if (!getStructuredQuery().equals(other.getStructuredQuery())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PARTITION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getPartitionCount()); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + switch (queryTypeCase_) { + case 2: + hash = (37 * hash) + STRUCTURED_QUERY_FIELD_NUMBER; + hash = (53 * hash) + getStructuredQuery().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.firestore.v1.PartitionQueryRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery].
+   * 
+ * + * Protobuf type {@code google.firestore.v1.PartitionQueryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.firestore.v1.PartitionQueryRequest) + com.google.firestore.v1.PartitionQueryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.PartitionQueryRequest.class, + com.google.firestore.v1.PartitionQueryRequest.Builder.class); + } + + // Construct using com.google.firestore.v1.PartitionQueryRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + partitionCount_ = 0L; + + pageToken_ = ""; + + pageSize_ = 0; + + queryTypeCase_ = 0; + queryType_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryRequest_descriptor; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryRequest getDefaultInstanceForType() { + return com.google.firestore.v1.PartitionQueryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryRequest build() { + com.google.firestore.v1.PartitionQueryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryRequest buildPartial() { + com.google.firestore.v1.PartitionQueryRequest result = + new com.google.firestore.v1.PartitionQueryRequest(this); + result.parent_ = parent_; + if (queryTypeCase_ == 2) { + if (structuredQueryBuilder_ == null) { + result.queryType_ = queryType_; + } else { + result.queryType_ = structuredQueryBuilder_.build(); + } + } + result.partitionCount_ = partitionCount_; + result.pageToken_ = pageToken_; + result.pageSize_ = pageSize_; + result.queryTypeCase_ = queryTypeCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.firestore.v1.PartitionQueryRequest) { + return mergeFrom((com.google.firestore.v1.PartitionQueryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.firestore.v1.PartitionQueryRequest other) { + if (other == com.google.firestore.v1.PartitionQueryRequest.getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPartitionCount() != 0L) { + setPartitionCount(other.getPartitionCount()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + switch (other.getQueryTypeCase()) { + case STRUCTURED_QUERY: + { + mergeStructuredQuery(other.getStructuredQuery()); + break; + } + case QUERYTYPE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.firestore.v1.PartitionQueryRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.firestore.v1.PartitionQueryRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int queryTypeCase_ = 0; + private java.lang.Object queryType_; + + public QueryTypeCase getQueryTypeCase() { + return QueryTypeCase.forNumber(queryTypeCase_); + } + + public Builder clearQueryType() { + queryTypeCase_ = 0; + queryType_ = null; + onChanged(); + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent resource name. In the format:
+     * `projects/{project_id}/databases/{database_id}/documents`.
+     * Document resource names are not supported; only database resource names
+     * can be specified.
+     * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent resource name. In the format:
+     * `projects/{project_id}/databases/{database_id}/documents`.
+     * Document resource names are not supported; only database resource names
+     * can be specified.
+     * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent resource name. In the format:
+     * `projects/{project_id}/databases/{database_id}/documents`.
+     * Document resource names are not supported; only database resource names
+     * can be specified.
+     * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent resource name. In the format:
+     * `projects/{project_id}/databases/{database_id}/documents`.
+     * Document resource names are not supported; only database resource names
+     * can be specified.
+     * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent resource name. In the format:
+     * `projects/{project_id}/databases/{database_id}/documents`.
+     * Document resource names are not supported; only database resource names
+     * can be specified.
+     * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.firestore.v1.StructuredQuery, + com.google.firestore.v1.StructuredQuery.Builder, + com.google.firestore.v1.StructuredQueryOrBuilder> + structuredQueryBuilder_; + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return Whether the structuredQuery field is set. + */ + @java.lang.Override + public boolean hasStructuredQuery() { + return queryTypeCase_ == 2; + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return The structuredQuery. + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery getStructuredQuery() { + if (structuredQueryBuilder_ == null) { + if (queryTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery) queryType_; + } + return com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } else { + if (queryTypeCase_ == 2) { + return structuredQueryBuilder_.getMessage(); + } + return com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + public Builder setStructuredQuery(com.google.firestore.v1.StructuredQuery value) { + if (structuredQueryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + queryType_ = value; + onChanged(); + } else { + structuredQueryBuilder_.setMessage(value); + } + queryTypeCase_ = 2; + return this; + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + public Builder setStructuredQuery( + com.google.firestore.v1.StructuredQuery.Builder builderForValue) { + if (structuredQueryBuilder_ == null) { + queryType_ = builderForValue.build(); + onChanged(); + } else { + structuredQueryBuilder_.setMessage(builderForValue.build()); + } + queryTypeCase_ = 2; + return this; + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + public Builder mergeStructuredQuery(com.google.firestore.v1.StructuredQuery value) { + if (structuredQueryBuilder_ == null) { + if (queryTypeCase_ == 2 + && queryType_ != com.google.firestore.v1.StructuredQuery.getDefaultInstance()) { + queryType_ = + com.google.firestore.v1.StructuredQuery.newBuilder( + (com.google.firestore.v1.StructuredQuery) queryType_) + .mergeFrom(value) + .buildPartial(); + } else { + queryType_ = value; + } + onChanged(); + } else { + if (queryTypeCase_ == 2) { + structuredQueryBuilder_.mergeFrom(value); + } + structuredQueryBuilder_.setMessage(value); + } + queryTypeCase_ = 2; + return this; + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + public Builder clearStructuredQuery() { + if (structuredQueryBuilder_ == null) { + if (queryTypeCase_ == 2) { + queryTypeCase_ = 0; + queryType_ = null; + onChanged(); + } + } else { + if (queryTypeCase_ == 2) { + queryTypeCase_ = 0; + queryType_ = null; + } + structuredQueryBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + public com.google.firestore.v1.StructuredQuery.Builder getStructuredQueryBuilder() { + return getStructuredQueryFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { + if ((queryTypeCase_ == 2) && (structuredQueryBuilder_ != null)) { + return structuredQueryBuilder_.getMessageOrBuilder(); + } else { + if (queryTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery) queryType_; + } + return com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } + } + /** + * + * + *
+     * A structured query.
+     * Filters, order bys, limits, offsets, and start/end cursors are not
+     * supported.
+     * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.firestore.v1.StructuredQuery, + com.google.firestore.v1.StructuredQuery.Builder, + com.google.firestore.v1.StructuredQueryOrBuilder> + getStructuredQueryFieldBuilder() { + if (structuredQueryBuilder_ == null) { + if (!(queryTypeCase_ == 2)) { + queryType_ = com.google.firestore.v1.StructuredQuery.getDefaultInstance(); + } + structuredQueryBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.firestore.v1.StructuredQuery, + com.google.firestore.v1.StructuredQuery.Builder, + com.google.firestore.v1.StructuredQueryOrBuilder>( + (com.google.firestore.v1.StructuredQuery) queryType_, + getParentForChildren(), + isClean()); + queryType_ = null; + } + queryTypeCase_ = 2; + onChanged(); + ; + return structuredQueryBuilder_; + } + + private long partitionCount_; + /** + * + * + *
+     * The desired maximum number of partition points.
+     * The partitions may be returned across multiple pages of results.
+     * The number must be strictly positive. The actual number of partitions
+     * returned may be fewer.
+     * For example, this may be set to one fewer than the number of parallel
+     * queries to be run, or in running a data pipeline job, one fewer than the
+     * number of workers or compute instances available.
+     * 
+ * + * int64 partition_count = 3; + * + * @return The partitionCount. + */ + @java.lang.Override + public long getPartitionCount() { + return partitionCount_; + } + /** + * + * + *
+     * The desired maximum number of partition points.
+     * The partitions may be returned across multiple pages of results.
+     * The number must be strictly positive. The actual number of partitions
+     * returned may be fewer.
+     * For example, this may be set to one fewer than the number of parallel
+     * queries to be run, or in running a data pipeline job, one fewer than the
+     * number of workers or compute instances available.
+     * 
+ * + * int64 partition_count = 3; + * + * @param value The partitionCount to set. + * @return This builder for chaining. + */ + public Builder setPartitionCount(long value) { + + partitionCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The desired maximum number of partition points.
+     * The partitions may be returned across multiple pages of results.
+     * The number must be strictly positive. The actual number of partitions
+     * returned may be fewer.
+     * For example, this may be set to one fewer than the number of parallel
+     * queries to be run, or in running a data pipeline job, one fewer than the
+     * number of workers or compute instances available.
+     * 
+ * + * int64 partition_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearPartitionCount() { + + partitionCount_ = 0L; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The `next_page_token` value returned from a previous call to
+     * PartitionQuery that may be used to get an additional set of results.
+     * There are no ordering guarantees between sets of results. Thus, using
+     * multiple sets of results will require merging the different result sets.
+     * For example, two subsequent calls using a page_token may return:
+     *  * cursor B, cursor M, cursor Q
+     *  * cursor A, cursor U, cursor W
+     * To obtain a complete result set ordered with respect to the results of the
+     * query supplied to PartitionQuery, the results sets should be merged:
+     * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+     * 
+ * + * string page_token = 4; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The `next_page_token` value returned from a previous call to
+     * PartitionQuery that may be used to get an additional set of results.
+     * There are no ordering guarantees between sets of results. Thus, using
+     * multiple sets of results will require merging the different result sets.
+     * For example, two subsequent calls using a page_token may return:
+     *  * cursor B, cursor M, cursor Q
+     *  * cursor A, cursor U, cursor W
+     * To obtain a complete result set ordered with respect to the results of the
+     * query supplied to PartitionQuery, the results sets should be merged:
+     * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+     * 
+ * + * string page_token = 4; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The `next_page_token` value returned from a previous call to
+     * PartitionQuery that may be used to get an additional set of results.
+     * There are no ordering guarantees between sets of results. Thus, using
+     * multiple sets of results will require merging the different result sets.
+     * For example, two subsequent calls using a page_token may return:
+     *  * cursor B, cursor M, cursor Q
+     *  * cursor A, cursor U, cursor W
+     * To obtain a complete result set ordered with respect to the results of the
+     * query supplied to PartitionQuery, the results sets should be merged:
+     * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+     * 
+ * + * string page_token = 4; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + pageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The `next_page_token` value returned from a previous call to
+     * PartitionQuery that may be used to get an additional set of results.
+     * There are no ordering guarantees between sets of results. Thus, using
+     * multiple sets of results will require merging the different result sets.
+     * For example, two subsequent calls using a page_token may return:
+     *  * cursor B, cursor M, cursor Q
+     *  * cursor A, cursor U, cursor W
+     * To obtain a complete result set ordered with respect to the results of the
+     * query supplied to PartitionQuery, the results sets should be merged:
+     * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+     * 
+ * + * string page_token = 4; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The `next_page_token` value returned from a previous call to
+     * PartitionQuery that may be used to get an additional set of results.
+     * There are no ordering guarantees between sets of results. Thus, using
+     * multiple sets of results will require merging the different result sets.
+     * For example, two subsequent calls using a page_token may return:
+     *  * cursor B, cursor M, cursor Q
+     *  * cursor A, cursor U, cursor W
+     * To obtain a complete result set ordered with respect to the results of the
+     * query supplied to PartitionQuery, the results sets should be merged:
+     * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+     * 
+ * + * string page_token = 4; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + pageToken_ = value; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of partitions to return in this call, subject to
+     * `partition_count`.
+     * For example, if `partition_count` = 10 and `page_size` = 8, the first call
+     * to PartitionQuery will return up to 8 partitions and a `next_page_token`
+     * if more results exist. A second call to PartitionQuery will return up to
+     * 2 partitions, to complete the total of 10 specified in `partition_count`.
+     * 
+ * + * int32 page_size = 5; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of partitions to return in this call, subject to
+     * `partition_count`.
+     * For example, if `partition_count` = 10 and `page_size` = 8, the first call
+     * to PartitionQuery will return up to 8 partitions and a `next_page_token`
+     * if more results exist. A second call to PartitionQuery will return up to
+     * 2 partitions, to complete the total of 10 specified in `partition_count`.
+     * 
+ * + * int32 page_size = 5; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of partitions to return in this call, subject to
+     * `partition_count`.
+     * For example, if `partition_count` = 10 and `page_size` = 8, the first call
+     * to PartitionQuery will return up to 8 partitions and a `next_page_token`
+     * if more results exist. A second call to PartitionQuery will return up to
+     * 2 partitions, to complete the total of 10 specified in `partition_count`.
+     * 
+ * + * int32 page_size = 5; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.firestore.v1.PartitionQueryRequest) + } + + // @@protoc_insertion_point(class_scope:google.firestore.v1.PartitionQueryRequest) + private static final com.google.firestore.v1.PartitionQueryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.firestore.v1.PartitionQueryRequest(); + } + + public static com.google.firestore.v1.PartitionQueryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PartitionQueryRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PartitionQueryRequest(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequestOrBuilder.java new file mode 100644 index 000000000..ea95a0f81 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryRequestOrBuilder.java @@ -0,0 +1,179 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +public interface PartitionQueryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.firestore.v1.PartitionQueryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent resource name. In the format:
+   * `projects/{project_id}/databases/{database_id}/documents`.
+   * Document resource names are not supported; only database resource names
+   * can be specified.
+   * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent resource name. In the format:
+   * `projects/{project_id}/databases/{database_id}/documents`.
+   * Document resource names are not supported; only database resource names
+   * can be specified.
+   * 
+ * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return Whether the structuredQuery field is set. + */ + boolean hasStructuredQuery(); + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + * + * @return The structuredQuery. + */ + com.google.firestore.v1.StructuredQuery getStructuredQuery(); + /** + * + * + *
+   * A structured query.
+   * Filters, order bys, limits, offsets, and start/end cursors are not
+   * supported.
+   * 
+ * + * .google.firestore.v1.StructuredQuery structured_query = 2; + */ + com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder(); + + /** + * + * + *
+   * The desired maximum number of partition points.
+   * The partitions may be returned across multiple pages of results.
+   * The number must be strictly positive. The actual number of partitions
+   * returned may be fewer.
+   * For example, this may be set to one fewer than the number of parallel
+   * queries to be run, or in running a data pipeline job, one fewer than the
+   * number of workers or compute instances available.
+   * 
+ * + * int64 partition_count = 3; + * + * @return The partitionCount. + */ + long getPartitionCount(); + + /** + * + * + *
+   * The `next_page_token` value returned from a previous call to
+   * PartitionQuery that may be used to get an additional set of results.
+   * There are no ordering guarantees between sets of results. Thus, using
+   * multiple sets of results will require merging the different result sets.
+   * For example, two subsequent calls using a page_token may return:
+   *  * cursor B, cursor M, cursor Q
+   *  * cursor A, cursor U, cursor W
+   * To obtain a complete result set ordered with respect to the results of the
+   * query supplied to PartitionQuery, the results sets should be merged:
+   * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+   * 
+ * + * string page_token = 4; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The `next_page_token` value returned from a previous call to
+   * PartitionQuery that may be used to get an additional set of results.
+   * There are no ordering guarantees between sets of results. Thus, using
+   * multiple sets of results will require merging the different result sets.
+   * For example, two subsequent calls using a page_token may return:
+   *  * cursor B, cursor M, cursor Q
+   *  * cursor A, cursor U, cursor W
+   * To obtain a complete result set ordered with respect to the results of the
+   * query supplied to PartitionQuery, the results sets should be merged:
+   * cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W
+   * 
+ * + * string page_token = 4; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * The maximum number of partitions to return in this call, subject to
+   * `partition_count`.
+   * For example, if `partition_count` = 10 and `page_size` = 8, the first call
+   * to PartitionQuery will return up to 8 partitions and a `next_page_token`
+   * if more results exist. A second call to PartitionQuery will return up to
+   * 2 partitions, to complete the total of 10 specified in `partition_count`.
+   * 
+ * + * int32 page_size = 5; + * + * @return The pageSize. + */ + int getPageSize(); + + public com.google.firestore.v1.PartitionQueryRequest.QueryTypeCase getQueryTypeCase(); +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponse.java new file mode 100644 index 000000000..04766aff5 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponse.java @@ -0,0 +1,1391 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +/** + * + * + *
+ * The response for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery].
+ * 
+ * + * Protobuf type {@code google.firestore.v1.PartitionQueryResponse} + */ +public final class PartitionQueryResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.firestore.v1.PartitionQueryResponse) + PartitionQueryResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use PartitionQueryResponse.newBuilder() to construct. + private PartitionQueryResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private PartitionQueryResponse() { + partitions_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new PartitionQueryResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private PartitionQueryResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + partitions_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + partitions_.add( + input.readMessage(com.google.firestore.v1.Cursor.parser(), extensionRegistry)); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + nextPageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + partitions_ = java.util.Collections.unmodifiableList(partitions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.PartitionQueryResponse.class, + com.google.firestore.v1.PartitionQueryResponse.Builder.class); + } + + public static final int PARTITIONS_FIELD_NUMBER = 1; + private java.util.List partitions_; + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + @java.lang.Override + public java.util.List getPartitionsList() { + return partitions_; + } + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + @java.lang.Override + public java.util.List + getPartitionsOrBuilderList() { + return partitions_; + } + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + @java.lang.Override + public int getPartitionsCount() { + return partitions_.size(); + } + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + @java.lang.Override + public com.google.firestore.v1.Cursor getPartitions(int index) { + return partitions_.get(index); + } + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + @java.lang.Override + public com.google.firestore.v1.CursorOrBuilder getPartitionsOrBuilder(int index) { + return partitions_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * A page token that may be used to request an additional set of results, up
+   * to the number specified by `partition_count` in the PartitionQuery request.
+   * If blank, there are no more results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * A page token that may be used to request an additional set of results, up
+   * to the number specified by `partition_count` in the PartitionQuery request.
+   * If blank, there are no more results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < partitions_.size(); i++) { + output.writeMessage(1, partitions_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < partitions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, partitions_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.firestore.v1.PartitionQueryResponse)) { + return super.equals(obj); + } + com.google.firestore.v1.PartitionQueryResponse other = + (com.google.firestore.v1.PartitionQueryResponse) obj; + + if (!getPartitionsList().equals(other.getPartitionsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getPartitionsCount() > 0) { + hash = (37 * hash) + PARTITIONS_FIELD_NUMBER; + hash = (53 * hash) + getPartitionsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.PartitionQueryResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.firestore.v1.PartitionQueryResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery].
+   * 
+ * + * Protobuf type {@code google.firestore.v1.PartitionQueryResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.firestore.v1.PartitionQueryResponse) + com.google.firestore.v1.PartitionQueryResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.PartitionQueryResponse.class, + com.google.firestore.v1.PartitionQueryResponse.Builder.class); + } + + // Construct using com.google.firestore.v1.PartitionQueryResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getPartitionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (partitionsBuilder_ == null) { + partitions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + partitionsBuilder_.clear(); + } + nextPageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.firestore.v1.FirestoreProto + .internal_static_google_firestore_v1_PartitionQueryResponse_descriptor; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryResponse getDefaultInstanceForType() { + return com.google.firestore.v1.PartitionQueryResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryResponse build() { + com.google.firestore.v1.PartitionQueryResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryResponse buildPartial() { + com.google.firestore.v1.PartitionQueryResponse result = + new com.google.firestore.v1.PartitionQueryResponse(this); + int from_bitField0_ = bitField0_; + if (partitionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + partitions_ = java.util.Collections.unmodifiableList(partitions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.partitions_ = partitions_; + } else { + result.partitions_ = partitionsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.firestore.v1.PartitionQueryResponse) { + return mergeFrom((com.google.firestore.v1.PartitionQueryResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.firestore.v1.PartitionQueryResponse other) { + if (other == com.google.firestore.v1.PartitionQueryResponse.getDefaultInstance()) return this; + if (partitionsBuilder_ == null) { + if (!other.partitions_.isEmpty()) { + if (partitions_.isEmpty()) { + partitions_ = other.partitions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensurePartitionsIsMutable(); + partitions_.addAll(other.partitions_); + } + onChanged(); + } + } else { + if (!other.partitions_.isEmpty()) { + if (partitionsBuilder_.isEmpty()) { + partitionsBuilder_.dispose(); + partitionsBuilder_ = null; + partitions_ = other.partitions_; + bitField0_ = (bitField0_ & ~0x00000001); + partitionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getPartitionsFieldBuilder() + : null; + } else { + partitionsBuilder_.addAllMessages(other.partitions_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.firestore.v1.PartitionQueryResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.firestore.v1.PartitionQueryResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List partitions_ = + java.util.Collections.emptyList(); + + private void ensurePartitionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + partitions_ = new java.util.ArrayList(partitions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Cursor, + com.google.firestore.v1.Cursor.Builder, + com.google.firestore.v1.CursorOrBuilder> + partitionsBuilder_; + + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public java.util.List getPartitionsList() { + if (partitionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(partitions_); + } else { + return partitionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public int getPartitionsCount() { + if (partitionsBuilder_ == null) { + return partitions_.size(); + } else { + return partitionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public com.google.firestore.v1.Cursor getPartitions(int index) { + if (partitionsBuilder_ == null) { + return partitions_.get(index); + } else { + return partitionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder setPartitions(int index, com.google.firestore.v1.Cursor value) { + if (partitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePartitionsIsMutable(); + partitions_.set(index, value); + onChanged(); + } else { + partitionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder setPartitions( + int index, com.google.firestore.v1.Cursor.Builder builderForValue) { + if (partitionsBuilder_ == null) { + ensurePartitionsIsMutable(); + partitions_.set(index, builderForValue.build()); + onChanged(); + } else { + partitionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder addPartitions(com.google.firestore.v1.Cursor value) { + if (partitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePartitionsIsMutable(); + partitions_.add(value); + onChanged(); + } else { + partitionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder addPartitions(int index, com.google.firestore.v1.Cursor value) { + if (partitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePartitionsIsMutable(); + partitions_.add(index, value); + onChanged(); + } else { + partitionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder addPartitions(com.google.firestore.v1.Cursor.Builder builderForValue) { + if (partitionsBuilder_ == null) { + ensurePartitionsIsMutable(); + partitions_.add(builderForValue.build()); + onChanged(); + } else { + partitionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder addPartitions( + int index, com.google.firestore.v1.Cursor.Builder builderForValue) { + if (partitionsBuilder_ == null) { + ensurePartitionsIsMutable(); + partitions_.add(index, builderForValue.build()); + onChanged(); + } else { + partitionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder addAllPartitions( + java.lang.Iterable values) { + if (partitionsBuilder_ == null) { + ensurePartitionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, partitions_); + onChanged(); + } else { + partitionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder clearPartitions() { + if (partitionsBuilder_ == null) { + partitions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + partitionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public Builder removePartitions(int index) { + if (partitionsBuilder_ == null) { + ensurePartitionsIsMutable(); + partitions_.remove(index); + onChanged(); + } else { + partitionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public com.google.firestore.v1.Cursor.Builder getPartitionsBuilder(int index) { + return getPartitionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public com.google.firestore.v1.CursorOrBuilder getPartitionsOrBuilder(int index) { + if (partitionsBuilder_ == null) { + return partitions_.get(index); + } else { + return partitionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public java.util.List + getPartitionsOrBuilderList() { + if (partitionsBuilder_ != null) { + return partitionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(partitions_); + } + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public com.google.firestore.v1.Cursor.Builder addPartitionsBuilder() { + return getPartitionsFieldBuilder() + .addBuilder(com.google.firestore.v1.Cursor.getDefaultInstance()); + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public com.google.firestore.v1.Cursor.Builder addPartitionsBuilder(int index) { + return getPartitionsFieldBuilder() + .addBuilder(index, com.google.firestore.v1.Cursor.getDefaultInstance()); + } + /** + * + * + *
+     * Partition results.
+     * Each partition is a split point that can be used by RunQuery as a starting
+     * or end point for the query results. The RunQuery requests must be made with
+     * the same query supplied to this PartitionQuery request. The partition
+     * cursors will be ordered according to same ordering as the results of the
+     * query supplied to PartitionQuery.
+     * For example, if a PartitionQuery request returns partition cursors A and B,
+     * running the following three queries will return the entire result set of
+     * the original query:
+     *  * query, end_at A
+     *  * query, start_at A, end_at B
+     *  * query, start_at B
+     * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + public java.util.List getPartitionsBuilderList() { + return getPartitionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Cursor, + com.google.firestore.v1.Cursor.Builder, + com.google.firestore.v1.CursorOrBuilder> + getPartitionsFieldBuilder() { + if (partitionsBuilder_ == null) { + partitionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.Cursor, + com.google.firestore.v1.Cursor.Builder, + com.google.firestore.v1.CursorOrBuilder>( + partitions_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + partitions_ = null; + } + return partitionsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * A page token that may be used to request an additional set of results, up
+     * to the number specified by `partition_count` in the PartitionQuery request.
+     * If blank, there are no more results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A page token that may be used to request an additional set of results, up
+     * to the number specified by `partition_count` in the PartitionQuery request.
+     * If blank, there are no more results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A page token that may be used to request an additional set of results, up
+     * to the number specified by `partition_count` in the PartitionQuery request.
+     * If blank, there are no more results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that may be used to request an additional set of results, up
+     * to the number specified by `partition_count` in the PartitionQuery request.
+     * If blank, there are no more results.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that may be used to request an additional set of results, up
+     * to the number specified by `partition_count` in the PartitionQuery request.
+     * If blank, there are no more results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.firestore.v1.PartitionQueryResponse) + } + + // @@protoc_insertion_point(class_scope:google.firestore.v1.PartitionQueryResponse) + private static final com.google.firestore.v1.PartitionQueryResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.firestore.v1.PartitionQueryResponse(); + } + + public static com.google.firestore.v1.PartitionQueryResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PartitionQueryResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PartitionQueryResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.firestore.v1.PartitionQueryResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponseOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponseOrBuilder.java new file mode 100644 index 000000000..c6ab160b7 --- /dev/null +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/PartitionQueryResponseOrBuilder.java @@ -0,0 +1,160 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/firestore/v1/firestore.proto + +package com.google.firestore.v1; + +public interface PartitionQueryResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.firestore.v1.PartitionQueryResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + java.util.List getPartitionsList(); + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + com.google.firestore.v1.Cursor getPartitions(int index); + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + int getPartitionsCount(); + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + java.util.List getPartitionsOrBuilderList(); + /** + * + * + *
+   * Partition results.
+   * Each partition is a split point that can be used by RunQuery as a starting
+   * or end point for the query results. The RunQuery requests must be made with
+   * the same query supplied to this PartitionQuery request. The partition
+   * cursors will be ordered according to same ordering as the results of the
+   * query supplied to PartitionQuery.
+   * For example, if a PartitionQuery request returns partition cursors A and B,
+   * running the following three queries will return the entire result set of
+   * the original query:
+   *  * query, end_at A
+   *  * query, start_at A, end_at B
+   *  * query, start_at B
+   * 
+ * + * repeated .google.firestore.v1.Cursor partitions = 1; + */ + com.google.firestore.v1.CursorOrBuilder getPartitionsOrBuilder(int index); + + /** + * + * + *
+   * A page token that may be used to request an additional set of results, up
+   * to the number specified by `partition_count` in the PartitionQuery request.
+   * If blank, there are no more results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * A page token that may be used to request an additional set of results, up
+   * to the number specified by `partition_count` in the PartitionQuery request.
+   * If blank, there are no more results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Precondition.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Precondition.java index 6d62c83f5..ec3d8ebc5 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Precondition.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Precondition.java @@ -183,6 +183,7 @@ public ConditionTypeCase getConditionTypeCase() { * * @return The exists. */ + @java.lang.Override public boolean getExists() { if (conditionTypeCase_ == 1) { return (java.lang.Boolean) conditionType_; @@ -203,6 +204,7 @@ public boolean getExists() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return conditionTypeCase_ == 2; } @@ -218,6 +220,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { if (conditionTypeCase_ == 2) { return (com.google.protobuf.Timestamp) conditionType_; @@ -234,6 +237,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (conditionTypeCase_ == 2) { return (com.google.protobuf.Timestamp) conditionType_; @@ -695,6 +699,7 @@ public Builder clearExists() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return conditionTypeCase_ == 2; } @@ -710,6 +715,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { if (conditionTypeCase_ == 2) { @@ -847,6 +853,7 @@ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { * * .google.protobuf.Timestamp update_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if ((conditionTypeCase_ == 2) && (updateTimeBuilder_ != null)) { return updateTimeBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/QueryProto.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/QueryProto.java index d4d5e4c82..cd49e1654 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/QueryProto.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/QueryProto.java @@ -47,10 +47,6 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_firestore_v1_StructuredQuery_FieldFilter_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_firestore_v1_StructuredQuery_FieldFilter_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -59,6 +55,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_firestore_v1_StructuredQuery_FieldReference_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_firestore_v1_StructuredQuery_Order_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -113,27 +113,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "AN\020\001\022\026\n\022LESS_THAN_OR_EQUAL\020\002\022\020\n\014GREATER_" + "THAN\020\003\022\031\n\025GREATER_THAN_OR_EQUAL\020\004\022\t\n\005EQU" + "AL\020\005\022\022\n\016ARRAY_CONTAINS\020\007\022\006\n\002IN\020\010\022\026\n\022ARRA" - + "Y_CONTAINS_ANY\020\t\032Q\n\nProjection\022C\n\006fields" - + "\030\002 \003(\01323.google.firestore.v1.StructuredQ" - + "uery.FieldReference\032\351\001\n\013UnaryFilter\022E\n\002o" - + "p\030\001 \001(\01629.google.firestore.v1.Structured" - + "Query.UnaryFilter.Operator\022D\n\005field\030\002 \001(" - + "\01323.google.firestore.v1.StructuredQuery." - + "FieldReferenceH\000\"=\n\010Operator\022\030\n\024OPERATOR" - + "_UNSPECIFIED\020\000\022\n\n\006IS_NAN\020\002\022\013\n\007IS_NULL\020\003B" - + "\016\n\014operand_type\032$\n\016FieldReference\022\022\n\nfie" - + "ld_path\030\002 \001(\t\032\216\001\n\005Order\022B\n\005field\030\001 \001(\01323" + + "Y_CONTAINS_ANY\020\t\032\351\001\n\013UnaryFilter\022E\n\002op\030\001" + + " \001(\01629.google.firestore.v1.StructuredQue" + + "ry.UnaryFilter.Operator\022D\n\005field\030\002 \001(\01323" + + ".google.firestore.v1.StructuredQuery.Fie" + + "ldReferenceH\000\"=\n\010Operator\022\030\n\024OPERATOR_UN" + + "SPECIFIED\020\000\022\n\n\006IS_NAN\020\002\022\013\n\007IS_NULL\020\003B\016\n\014" + + "operand_type\032$\n\016FieldReference\022\022\n\nfield_" + + "path\030\002 \001(\t\032Q\n\nProjection\022C\n\006fields\030\002 \003(\013" + + "23.google.firestore.v1.StructuredQuery.F" + + "ieldReference\032\216\001\n\005Order\022B\n\005field\030\001 \001(\01323" + ".google.firestore.v1.StructuredQuery.Fie" + "ldReference\022A\n\tdirection\030\002 \001(\0162..google." + "firestore.v1.StructuredQuery.Direction\"E" + "\n\tDirection\022\031\n\025DIRECTION_UNSPECIFIED\020\000\022\r" + "\n\tASCENDING\020\001\022\016\n\nDESCENDING\020\002\"D\n\006Cursor\022" + "*\n\006values\030\001 \003(\0132\032.google.firestore.v1.Va" - + "lue\022\016\n\006before\030\002 \001(\010B\244\001\n\027com.google.fires" + + "lue\022\016\n\006before\030\002 \001(\010B\303\001\n\027com.google.fires" + "tore.v1B\nQueryProtoP\001Z.google.firestore.v1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1.StructuredQuery) queryType_; @@ -377,6 +382,7 @@ public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuil * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -399,6 +405,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 6; } @@ -416,6 +423,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions getNewTransaction() { if (consistencySelectorCase_ == 6) { return (com.google.firestore.v1.TransactionOptions) consistencySelector_; @@ -434,6 +442,7 @@ public com.google.firestore.v1.TransactionOptions getNewTransaction() { * * .google.firestore.v1.TransactionOptions new_transaction = 6; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if (consistencySelectorCase_ == 6) { return (com.google.firestore.v1.TransactionOptions) consistencySelector_; @@ -447,13 +456,14 @@ public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBu * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -462,13 +472,14 @@ public boolean hasReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -480,11 +491,12 @@ public com.google.protobuf.Timestamp getReadTime() { * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1122,6 +1134,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1136,6 +1149,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery getStructuredQuery() { if (structuredQueryBuilder_ == null) { if (queryTypeCase_ == 2) { @@ -1268,6 +1282,7 @@ public com.google.firestore.v1.StructuredQuery.Builder getStructuredQueryBuilder * * .google.firestore.v1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if ((queryTypeCase_ == 2) && (structuredQueryBuilder_ != null)) { return structuredQueryBuilder_.getMessageOrBuilder(); @@ -1389,6 +1404,7 @@ public Builder clearTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 6; } @@ -1406,6 +1422,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions getNewTransaction() { if (newTransactionBuilder_ == null) { if (consistencySelectorCase_ == 6) { @@ -1557,6 +1574,7 @@ public com.google.firestore.v1.TransactionOptions.Builder getNewTransactionBuild * * .google.firestore.v1.TransactionOptions new_transaction = 6; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if ((consistencySelectorCase_ == 6) && (newTransactionBuilder_ != null)) { return newTransactionBuilder_.getMessageOrBuilder(); @@ -1614,13 +1632,14 @@ public com.google.firestore.v1.TransactionOptionsOrBuilder getNewTransactionOrBu * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -1629,13 +1648,14 @@ public boolean hasReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 7) { @@ -1654,7 +1674,7 @@ public com.google.protobuf.Timestamp getReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1677,7 +1697,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1697,7 +1717,7 @@ public Builder setReadTime(com.google.protobuf.Timestamp.Builder builderForValue * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1729,7 +1749,7 @@ public Builder mergeReadTime(com.google.protobuf.Timestamp value) { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1755,7 +1775,7 @@ public Builder clearReadTime() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; @@ -1768,11 +1788,12 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 7) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -1788,7 +1809,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * *
      * Reads documents as they were at the given time.
-     * This may not be older than 60 seconds.
+     * This may not be older than 270 seconds.
      * 
* * .google.protobuf.Timestamp read_time = 7; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryRequestOrBuilder.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryRequestOrBuilder.java index ca54f6591..c34cb4767 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryRequestOrBuilder.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryRequestOrBuilder.java @@ -155,7 +155,7 @@ public interface RunQueryRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; @@ -168,7 +168,7 @@ public interface RunQueryRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; @@ -181,7 +181,7 @@ public interface RunQueryRequestOrBuilder * *
    * Reads documents as they were at the given time.
-   * This may not be older than 60 seconds.
+   * This may not be older than 270 seconds.
    * 
* * .google.protobuf.Timestamp read_time = 7; diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryResponse.java index 48c303e6b..afa5d3fbc 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/RunQueryResponse.java @@ -160,6 +160,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -178,6 +179,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -193,6 +195,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1.Document getDocument() { return document_ == null ? com.google.firestore.v1.Document.getDefaultInstance() : document_; } @@ -206,6 +209,7 @@ public com.google.firestore.v1.Document getDocument() { * * .google.firestore.v1.Document document = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -228,6 +232,7 @@ public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -247,6 +252,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -264,6 +270,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 3; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -282,6 +289,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The skippedResults. */ + @java.lang.Override public int getSkippedResults() { return skippedResults_; } @@ -686,6 +694,7 @@ public Builder mergeFrom( * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -1165,6 +1174,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The skippedResults. */ + @java.lang.Override public int getSkippedResults() { return skippedResults_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/StructuredQuery.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/StructuredQuery.java index 6a6867192..99f7edfc6 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/StructuredQuery.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/StructuredQuery.java @@ -341,6 +341,10 @@ public Direction findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -532,6 +536,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The collectionId. */ + @java.lang.Override public java.lang.String getCollectionId() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -555,6 +560,7 @@ public java.lang.String getCollectionId() { * * @return The bytes for collectionId. */ + @java.lang.Override public com.google.protobuf.ByteString getCollectionIdBytes() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -582,6 +588,7 @@ public com.google.protobuf.ByteString getCollectionIdBytes() { * * @return The allDescendants. */ + @java.lang.Override public boolean getAllDescendants() { return allDescendants_; } @@ -1051,6 +1058,7 @@ public Builder setCollectionIdBytes(com.google.protobuf.ByteString value) { * * @return The allDescendants. */ + @java.lang.Override public boolean getAllDescendants() { return allDescendants_; } @@ -1465,6 +1473,7 @@ public FilterTypeCase getFilterTypeCase() { * * @return Whether the compositeFilter field is set. */ + @java.lang.Override public boolean hasCompositeFilter() { return filterTypeCase_ == 1; } @@ -1479,6 +1488,7 @@ public boolean hasCompositeFilter() { * * @return The compositeFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilter getCompositeFilter() { if (filterTypeCase_ == 1) { return (com.google.firestore.v1.StructuredQuery.CompositeFilter) filterType_; @@ -1494,6 +1504,7 @@ public com.google.firestore.v1.StructuredQuery.CompositeFilter getCompositeFilte * * .google.firestore.v1.StructuredQuery.CompositeFilter composite_filter = 1; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilterOrBuilder getCompositeFilterOrBuilder() { if (filterTypeCase_ == 1) { @@ -1514,6 +1525,7 @@ public com.google.firestore.v1.StructuredQuery.CompositeFilter getCompositeFilte * * @return Whether the fieldFilter field is set. */ + @java.lang.Override public boolean hasFieldFilter() { return filterTypeCase_ == 2; } @@ -1528,6 +1540,7 @@ public boolean hasFieldFilter() { * * @return The fieldFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilter getFieldFilter() { if (filterTypeCase_ == 2) { return (com.google.firestore.v1.StructuredQuery.FieldFilter) filterType_; @@ -1543,6 +1556,7 @@ public com.google.firestore.v1.StructuredQuery.FieldFilter getFieldFilter() { * * .google.firestore.v1.StructuredQuery.FieldFilter field_filter = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilterOrBuilder getFieldFilterOrBuilder() { if (filterTypeCase_ == 2) { return (com.google.firestore.v1.StructuredQuery.FieldFilter) filterType_; @@ -1562,6 +1576,7 @@ public com.google.firestore.v1.StructuredQuery.FieldFilterOrBuilder getFieldFilt * * @return Whether the unaryFilter field is set. */ + @java.lang.Override public boolean hasUnaryFilter() { return filterTypeCase_ == 3; } @@ -1576,6 +1591,7 @@ public boolean hasUnaryFilter() { * * @return The unaryFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.UnaryFilter getUnaryFilter() { if (filterTypeCase_ == 3) { return (com.google.firestore.v1.StructuredQuery.UnaryFilter) filterType_; @@ -1591,6 +1607,7 @@ public com.google.firestore.v1.StructuredQuery.UnaryFilter getUnaryFilter() { * * .google.firestore.v1.StructuredQuery.UnaryFilter unary_filter = 3; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.UnaryFilterOrBuilder getUnaryFilterOrBuilder() { if (filterTypeCase_ == 3) { return (com.google.firestore.v1.StructuredQuery.UnaryFilter) filterType_; @@ -2033,6 +2050,7 @@ public Builder clearFilterType() { * * @return Whether the compositeFilter field is set. */ + @java.lang.Override public boolean hasCompositeFilter() { return filterTypeCase_ == 1; } @@ -2047,6 +2065,7 @@ public boolean hasCompositeFilter() { * * @return The compositeFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilter getCompositeFilter() { if (compositeFilterBuilder_ == null) { if (filterTypeCase_ == 1) { @@ -2183,6 +2202,7 @@ public Builder clearCompositeFilter() { * * .google.firestore.v1.StructuredQuery.CompositeFilter composite_filter = 1; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilterOrBuilder getCompositeFilterOrBuilder() { if ((filterTypeCase_ == 1) && (compositeFilterBuilder_ != null)) { @@ -2245,6 +2265,7 @@ public Builder clearCompositeFilter() { * * @return Whether the fieldFilter field is set. */ + @java.lang.Override public boolean hasFieldFilter() { return filterTypeCase_ == 2; } @@ -2259,6 +2280,7 @@ public boolean hasFieldFilter() { * * @return The fieldFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilter getFieldFilter() { if (fieldFilterBuilder_ == null) { if (filterTypeCase_ == 2) { @@ -2392,6 +2414,7 @@ public com.google.firestore.v1.StructuredQuery.FieldFilter.Builder getFieldFilte * * .google.firestore.v1.StructuredQuery.FieldFilter field_filter = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilterOrBuilder getFieldFilterOrBuilder() { if ((filterTypeCase_ == 2) && (fieldFilterBuilder_ != null)) { @@ -2453,6 +2476,7 @@ public com.google.firestore.v1.StructuredQuery.FieldFilter.Builder getFieldFilte * * @return Whether the unaryFilter field is set. */ + @java.lang.Override public boolean hasUnaryFilter() { return filterTypeCase_ == 3; } @@ -2467,6 +2491,7 @@ public boolean hasUnaryFilter() { * * @return The unaryFilter. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.UnaryFilter getUnaryFilter() { if (unaryFilterBuilder_ == null) { if (filterTypeCase_ == 3) { @@ -2600,6 +2625,7 @@ public com.google.firestore.v1.StructuredQuery.UnaryFilter.Builder getUnaryFilte * * .google.firestore.v1.StructuredQuery.UnaryFilter unary_filter = 3; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.UnaryFilterOrBuilder getUnaryFilterOrBuilder() { if ((filterTypeCase_ == 3) && (unaryFilterBuilder_ != null)) { @@ -2994,6 +3020,10 @@ public Operator findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -3041,6 +3071,7 @@ private Operator(int value) { * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -3055,6 +3086,7 @@ public int getOpValue() { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.CompositeFilter.Operator result = @@ -3076,6 +3108,7 @@ public com.google.firestore.v1.StructuredQuery.CompositeFilter.Operator getOp() * * repeated .google.firestore.v1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public java.util.List getFiltersList() { return filters_; } @@ -3089,6 +3122,7 @@ public java.util.List getFilters * * repeated .google.firestore.v1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public java.util.List getFiltersOrBuilderList() { return filters_; @@ -3103,6 +3137,7 @@ public java.util.List getFilters * * repeated .google.firestore.v1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public int getFiltersCount() { return filters_.size(); } @@ -3116,6 +3151,7 @@ public int getFiltersCount() { * * repeated .google.firestore.v1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Filter getFilters(int index) { return filters_.get(index); } @@ -3129,6 +3165,7 @@ public com.google.firestore.v1.StructuredQuery.Filter getFilters(int index) { * * repeated .google.firestore.v1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FilterOrBuilder getFiltersOrBuilder(int index) { return filters_.get(index); } @@ -3529,6 +3566,7 @@ public Builder mergeFrom( * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -3545,6 +3583,7 @@ public int getOpValue() { * @return This builder for chaining. */ public Builder setOpValue(int value) { + op_ = value; onChanged(); return this; @@ -3560,6 +3599,7 @@ public Builder setOpValue(int value) { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CompositeFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.CompositeFilter.Operator result = @@ -4278,7 +4318,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Less than. Requires that the field come first in `order_by`.
+       * The given `field` is less than the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * LESS_THAN = 1; @@ -4288,7 +4330,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Less than or equal. Requires that the field come first in `order_by`.
+       * The given `field` is less than or equal to the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * LESS_THAN_OR_EQUAL = 2; @@ -4298,7 +4342,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Greater than. Requires that the field come first in `order_by`.
+       * The given `field` is greater than the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * GREATER_THAN = 3; @@ -4308,8 +4354,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Greater than or equal. Requires that the field come first in
-       * `order_by`.
+       * The given `field` is greater than or equal to the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * GREATER_THAN_OR_EQUAL = 4; @@ -4319,7 +4366,7 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Equal.
+       * The given `field` is equal to the given `value`.
        * 
* * EQUAL = 5; @@ -4329,7 +4376,7 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Contains. Requires that the field is an array.
+       * The given `field` is an array that contains the given `value`.
        * 
* * ARRAY_CONTAINS = 7; @@ -4339,8 +4386,10 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * In. Requires that `value` is a non-empty ArrayValue with at most 10
-       * values.
+       * The given `field` is equal to at least one value in the given array.
+       * Requires:
+       * * That `value` is a non-empty `ArrayValue` with at most 10 values.
+       * * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`.
        * 
* * IN = 8; @@ -4350,8 +4399,11 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Contains any. Requires that the field is an array and
-       * `value` is a non-empty ArrayValue with at most 10 values.
+       * The given `field` is an array that contains any of the values in the
+       * given array.
+       * Requires:
+       * * That `value` is a non-empty `ArrayValue` with at most 10 values.
+       * * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`.
        * 
* * ARRAY_CONTAINS_ANY = 9; @@ -4374,7 +4426,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Less than. Requires that the field come first in `order_by`.
+       * The given `field` is less than the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * LESS_THAN = 1; @@ -4384,7 +4438,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Less than or equal. Requires that the field come first in `order_by`.
+       * The given `field` is less than or equal to the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * LESS_THAN_OR_EQUAL = 2; @@ -4394,7 +4450,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Greater than. Requires that the field come first in `order_by`.
+       * The given `field` is greater than the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * GREATER_THAN = 3; @@ -4404,8 +4462,9 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Greater than or equal. Requires that the field come first in
-       * `order_by`.
+       * The given `field` is greater than or equal to the given `value`.
+       * Requires:
+       * * That `field` come first in `order_by`.
        * 
* * GREATER_THAN_OR_EQUAL = 4; @@ -4415,7 +4474,7 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Equal.
+       * The given `field` is equal to the given `value`.
        * 
* * EQUAL = 5; @@ -4425,7 +4484,7 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Contains. Requires that the field is an array.
+       * The given `field` is an array that contains the given `value`.
        * 
* * ARRAY_CONTAINS = 7; @@ -4435,8 +4494,10 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * In. Requires that `value` is a non-empty ArrayValue with at most 10
-       * values.
+       * The given `field` is equal to at least one value in the given array.
+       * Requires:
+       * * That `value` is a non-empty `ArrayValue` with at most 10 values.
+       * * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`.
        * 
* * IN = 8; @@ -4446,8 +4507,11 @@ public enum Operator implements com.google.protobuf.ProtocolMessageEnum { * * *
-       * Contains any. Requires that the field is an array and
-       * `value` is a non-empty ArrayValue with at most 10 values.
+       * The given `field` is an array that contains any of the values in the
+       * given array.
+       * Requires:
+       * * That `value` is a non-empty `ArrayValue` with at most 10 values.
+       * * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`.
        * 
* * ARRAY_CONTAINS_ANY = 9; @@ -4513,6 +4577,10 @@ public Operator findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -4560,6 +4628,7 @@ private Operator(int value) { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return field_ != null; } @@ -4574,6 +4643,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldReference getField() { return field_ == null ? com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance() @@ -4588,6 +4658,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReference getField() { * * .google.firestore.v1.StructuredQuery.FieldReference field = 1; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { return getField(); } @@ -4605,6 +4676,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldO * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -4619,6 +4691,7 @@ public int getOpValue() { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.FieldFilter.Operator result = @@ -4641,6 +4714,7 @@ public com.google.firestore.v1.StructuredQuery.FieldFilter.Operator getOp() { * * @return Whether the value field is set. */ + @java.lang.Override public boolean hasValue() { return value_ != null; } @@ -4655,6 +4729,7 @@ public boolean hasValue() { * * @return The value. */ + @java.lang.Override public com.google.firestore.v1.Value getValue() { return value_ == null ? com.google.firestore.v1.Value.getDefaultInstance() : value_; } @@ -4667,6 +4742,7 @@ public com.google.firestore.v1.Value getValue() { * * .google.firestore.v1.Value value = 3; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getValueOrBuilder() { return getValue(); } @@ -5251,6 +5327,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldO * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -5267,6 +5344,7 @@ public int getOpValue() { * @return This builder for chaining. */ public Builder setOpValue(int value) { + op_ = value; onChanged(); return this; @@ -5282,6 +5360,7 @@ public Builder setOpValue(int value) { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.FieldFilter.Operator result = @@ -5560,100 +5639,100 @@ public com.google.firestore.v1.StructuredQuery.FieldFilter getDefaultInstanceFor } } - public interface ProjectionOrBuilder + public interface UnaryFilterOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.Projection) + // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.UnaryFilter) com.google.protobuf.MessageOrBuilder { /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * The unary operator to apply.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The enum numeric value on the wire for op. */ - java.util.List getFieldsList(); + int getOpValue(); /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * The unary operator to apply.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The op. */ - com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index); + com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp(); + /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * The field to which to apply the operator.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return Whether the field field is set. */ - int getFieldsCount(); + boolean hasField(); /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * The field to which to apply the operator.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return The field. */ - java.util.List - getFieldsOrBuilderList(); + com.google.firestore.v1.StructuredQuery.FieldReference getField(); /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * The field to which to apply the operator.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder(int index); + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder(); + + public com.google.firestore.v1.StructuredQuery.UnaryFilter.OperandTypeCase getOperandTypeCase(); } /** * * *
-   * The projection of document's fields to return.
+   * A filter with a single operand.
    * 
* - * Protobuf type {@code google.firestore.v1.StructuredQuery.Projection} + * Protobuf type {@code google.firestore.v1.StructuredQuery.UnaryFilter} */ - public static final class Projection extends com.google.protobuf.GeneratedMessageV3 + public static final class UnaryFilter extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.Projection) - ProjectionOrBuilder { + // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.UnaryFilter) + UnaryFilterOrBuilder { private static final long serialVersionUID = 0L; - // Use Projection.newBuilder() to construct. - private Projection(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use UnaryFilter.newBuilder() to construct. + private UnaryFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Projection() { - fields_ = java.util.Collections.emptyList(); + private UnaryFilter() { + op_ = 0; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Projection(); + return new UnaryFilter(); } @java.lang.Override @@ -5661,7 +5740,7 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Projection( + private UnaryFilter( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -5669,7 +5748,6 @@ private Projection( if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } - int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -5680,18 +5758,31 @@ private Projection( case 0: done = true; break; + case 8: + { + int rawValue = input.readEnum(); + + op_ = rawValue; + break; + } case 18: { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fields_ = - new java.util.ArrayList< - com.google.firestore.v1.StructuredQuery.FieldReference>(); - mutable_bitField0_ |= 0x00000001; + com.google.firestore.v1.StructuredQuery.FieldReference.Builder subBuilder = null; + if (operandTypeCase_ == 2) { + subBuilder = + ((com.google.firestore.v1.StructuredQuery.FieldReference) operandType_) + .toBuilder(); } - fields_.add( + operandType_ = input.readMessage( com.google.firestore.v1.StructuredQuery.FieldReference.parser(), - extensionRegistry)); + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); + operandType_ = subBuilder.buildPartial(); + } + operandTypeCase_ = 2; break; } default: @@ -5708,9 +5799,6 @@ private Projection( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - fields_ = java.util.Collections.unmodifiableList(fields_); - } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -5718,370 +5806,610 @@ private Projection( public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable + .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.Projection.class, - com.google.firestore.v1.StructuredQuery.Projection.Builder.class); + com.google.firestore.v1.StructuredQuery.UnaryFilter.class, + com.google.firestore.v1.StructuredQuery.UnaryFilter.Builder.class); } - public static final int FIELDS_FIELD_NUMBER = 2; - private java.util.List fields_; - /** - * - * - *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
-     * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public java.util.List getFieldsList() { - return fields_; - } - /** - * - * - *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
-     * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public java.util.List - getFieldsOrBuilderList() { - return fields_; - } - /** - * - * - *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
-     * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public int getFieldsCount() { - return fields_.size(); - } - /** - * - * - *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
-     * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index) { - return fields_.get(index); - } /** * * *
-     * The fields to return.
-     * If empty, all fields are returned. To only return the name
-     * of the document, use `['__name__']`.
+     * A unary operator.
      * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * Protobuf enum {@code google.firestore.v1.StructuredQuery.UnaryFilter.Operator} */ - public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder( - int index) { - return fields_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < fields_.size(); i++) { - output.writeMessage(2, fields_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + public enum Operator implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unspecified. This value must not be used.
+       * 
+ * + * OPERATOR_UNSPECIFIED = 0; + */ + OPERATOR_UNSPECIFIED(0), + /** + * + * + *
+       * The given `field` is equal to `NaN`.
+       * 
+ * + * IS_NAN = 2; + */ + IS_NAN(2), + /** + * + * + *
+       * The given `field` is equal to `NULL`.
+       * 
+ * + * IS_NULL = 3; + */ + IS_NULL(3), + UNRECOGNIZED(-1), + ; - size = 0; - for (int i = 0; i < fields_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, fields_.get(i)); + /** + * + * + *
+       * Unspecified. This value must not be used.
+       * 
+ * + * OPERATOR_UNSPECIFIED = 0; + */ + public static final int OPERATOR_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * The given `field` is equal to `NaN`.
+       * 
+ * + * IS_NAN = 2; + */ + public static final int IS_NAN_VALUE = 2; + /** + * + * + *
+       * The given `field` is equal to `NULL`.
+       * 
+ * + * IS_NULL = 3; + */ + public static final int IS_NULL_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Operator valueOf(int value) { + return forNumber(value); } - if (!(obj instanceof com.google.firestore.v1.StructuredQuery.Projection)) { - return super.equals(obj); + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Operator forNumber(int value) { + switch (value) { + case 0: + return OPERATOR_UNSPECIFIED; + case 2: + return IS_NAN; + case 3: + return IS_NULL; + default: + return null; + } } - com.google.firestore.v1.StructuredQuery.Projection other = - (com.google.firestore.v1.StructuredQuery.Projection) obj; - if (!getFieldsList().equals(other.getFieldsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Operator findValueByNumber(int number) { + return Operator.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFieldsCount() > 0) { - hash = (37 * hash) + FIELDS_FIELD_NUMBER; - hash = (53 * hash) + getFieldsList().hashCode(); + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.firestore.v1.StructuredQuery.UnaryFilter.getDescriptor() + .getEnumTypes() + .get(0); + } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + private static final Operator[] VALUES = values(); - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + public static Operator valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + private final int value; - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + private Operator(int value) { + this.value = value; + } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + // @@protoc_insertion_point(enum_scope:google.firestore.v1.StructuredQuery.UnaryFilter.Operator) } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } + private int operandTypeCase_ = 0; + private java.lang.Object operandType_; - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } + public enum OperandTypeCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + FIELD(2), + OPERANDTYPE_NOT_SET(0); + private final int value; - public static com.google.firestore.v1.StructuredQuery.Projection parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } + private OperandTypeCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OperandTypeCase valueOf(int value) { + return forNumber(value); + } - public static com.google.firestore.v1.StructuredQuery.Projection parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } + public static OperandTypeCase forNumber(int value) { + switch (value) { + case 2: + return FIELD; + case 0: + return OPERANDTYPE_NOT_SET; + default: + return null; + } + } - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); + public int getNumber() { + return this.value; + } + }; + + public OperandTypeCase getOperandTypeCase() { + return OperandTypeCase.forNumber(operandTypeCase_); } + public static final int OP_FIELD_NUMBER = 1; + private int op_; + /** + * + * + *
+     * The unary operator to apply.
+     * 
+ * + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The enum numeric value on the wire for op. + */ @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); + public int getOpValue() { + return op_; } - - public static Builder newBuilder(com.google.firestore.v1.StructuredQuery.Projection prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + /** + * + * + *
+     * The unary operator to apply.
+     * 
+ * + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The op. + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp() { + @SuppressWarnings("deprecation") + com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator result = + com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.valueOf(op_); + return result == null + ? com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.UNRECOGNIZED + : result; } + public static final int FIELD_FIELD_NUMBER = 2; + /** + * + * + *
+     * The field to which to apply the operator.
+     * 
+ * + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return Whether the field field is set. + */ @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + public boolean hasField() { + return operandTypeCase_ == 2; } - + /** + * + * + *
+     * The field to which to apply the operator.
+     * 
+ * + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return The field. + */ @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; + public com.google.firestore.v1.StructuredQuery.FieldReference getField() { + if (operandTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; + } + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); } /** * * *
-     * The projection of document's fields to return.
+     * The field to which to apply the operator.
      * 
* - * Protobuf type {@code google.firestore.v1.StructuredQuery.Projection} + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.Projection) - com.google.firestore.v1.StructuredQuery.ProjectionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { + if (operandTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; } + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.Projection.class, - com.google.firestore.v1.StructuredQuery.Projection.Builder.class); - } + private byte memoizedIsInitialized = -1; - // Construct using com.google.firestore.v1.StructuredQuery.Projection.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } + memoizedIsInitialized = 1; + return true; + } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFieldsFieldBuilder(); - } + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (op_ + != com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.OPERATOR_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, op_); } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (fieldsBuilder_ == null) { - fields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - fieldsBuilder_.clear(); - } - return this; + if (operandTypeCase_ == 2) { + output.writeMessage( + 2, (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); } + unknownFields.writeTo(output); + } - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; - } + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; - @java.lang.Override - public com.google.firestore.v1.StructuredQuery.Projection getDefaultInstanceForType() { - return com.google.firestore.v1.StructuredQuery.Projection.getDefaultInstance(); + size = 0; + if (op_ + != com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.OPERATOR_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, op_); } - - @java.lang.Override - public com.google.firestore.v1.StructuredQuery.Projection build() { - com.google.firestore.v1.StructuredQuery.Projection result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; + if (operandTypeCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } - @java.lang.Override - public com.google.firestore.v1.StructuredQuery.Projection buildPartial() { - com.google.firestore.v1.StructuredQuery.Projection result = - new com.google.firestore.v1.StructuredQuery.Projection(this); - int from_bitField0_ = bitField0_; - if (fieldsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - fields_ = java.util.Collections.unmodifiableList(fields_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fields_ = fields_; - } else { - result.fields_ = fieldsBuilder_.build(); - } - onBuilt(); - return result; + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; } - - @java.lang.Override - public Builder clone() { - return super.clone(); + if (!(obj instanceof com.google.firestore.v1.StructuredQuery.UnaryFilter)) { + return super.equals(obj); } + com.google.firestore.v1.StructuredQuery.UnaryFilter other = + (com.google.firestore.v1.StructuredQuery.UnaryFilter) obj; - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); + if (op_ != other.op_) return false; + if (!getOperandTypeCase().equals(other.getOperandTypeCase())) return false; + switch (operandTypeCase_) { + case 2: + if (!getField().equals(other.getField())) return false; + break; + case 0: + default: } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + OP_FIELD_NUMBER; + hash = (53 * hash) + op_; + switch (operandTypeCase_) { + case 2: + hash = (37 * hash) + FIELD_FIELD_NUMBER; + hash = (53 * hash) + getField().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.firestore.v1.StructuredQuery.UnaryFilter prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * A filter with a single operand.
+     * 
+ * + * Protobuf type {@code google.firestore.v1.StructuredQuery.UnaryFilter} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.UnaryFilter) + com.google.firestore.v1.StructuredQuery.UnaryFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.firestore.v1.QueryProto + .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.firestore.v1.QueryProto + .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.firestore.v1.StructuredQuery.UnaryFilter.class, + com.google.firestore.v1.StructuredQuery.UnaryFilter.Builder.class); + } + + // Construct using com.google.firestore.v1.StructuredQuery.UnaryFilter.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + op_ = 0; + + operandTypeCase_ = 0; + operandType_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.firestore.v1.QueryProto + .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; + } + + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstanceForType() { + return com.google.firestore.v1.StructuredQuery.UnaryFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.UnaryFilter build() { + com.google.firestore.v1.StructuredQuery.UnaryFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.UnaryFilter buildPartial() { + com.google.firestore.v1.StructuredQuery.UnaryFilter result = + new com.google.firestore.v1.StructuredQuery.UnaryFilter(this); + result.op_ = op_; + if (operandTypeCase_ == 2) { + if (fieldBuilder_ == null) { + result.operandType_ = operandType_; + } else { + result.operandType_ = fieldBuilder_.build(); + } + } + result.operandTypeCase_ = operandTypeCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); } @java.lang.Override @@ -6100,43 +6428,30 @@ public Builder addRepeatedField( @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.firestore.v1.StructuredQuery.Projection) { - return mergeFrom((com.google.firestore.v1.StructuredQuery.Projection) other); + if (other instanceof com.google.firestore.v1.StructuredQuery.UnaryFilter) { + return mergeFrom((com.google.firestore.v1.StructuredQuery.UnaryFilter) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.Projection other) { - if (other == com.google.firestore.v1.StructuredQuery.Projection.getDefaultInstance()) + public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.UnaryFilter other) { + if (other == com.google.firestore.v1.StructuredQuery.UnaryFilter.getDefaultInstance()) return this; - if (fieldsBuilder_ == null) { - if (!other.fields_.isEmpty()) { - if (fields_.isEmpty()) { - fields_ = other.fields_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFieldsIsMutable(); - fields_.addAll(other.fields_); + if (other.op_ != 0) { + setOpValue(other.getOpValue()); + } + switch (other.getOperandTypeCase()) { + case FIELD: + { + mergeField(other.getField()); + break; } - onChanged(); - } - } else { - if (!other.fields_.isEmpty()) { - if (fieldsBuilder_.isEmpty()) { - fieldsBuilder_.dispose(); - fieldsBuilder_ = null; - fields_ = other.fields_; - bitField0_ = (bitField0_ & ~0x00000001); - fieldsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getFieldsFieldBuilder() - : null; - } else { - fieldsBuilder_.addAllMessages(other.fields_); + case OPERANDTYPE_NOT_SET: + { + break; } - } } this.mergeUnknownFields(other.unknownFields); onChanged(); @@ -6153,12 +6468,12 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.firestore.v1.StructuredQuery.Projection parsedMessage = null; + com.google.firestore.v1.StructuredQuery.UnaryFilter parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = - (com.google.firestore.v1.StructuredQuery.Projection) e.getUnfinishedMessage(); + (com.google.firestore.v1.StructuredQuery.UnaryFilter) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -6168,285 +6483,254 @@ public Builder mergeFrom( return this; } - private int bitField0_; - - private java.util.List fields_ = - java.util.Collections.emptyList(); + private int operandTypeCase_ = 0; + private java.lang.Object operandType_; - private void ensureFieldsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - fields_ = - new java.util.ArrayList( - fields_); - bitField0_ |= 0x00000001; - } + public OperandTypeCase getOperandTypeCase() { + return OperandTypeCase.forNumber(operandTypeCase_); } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.firestore.v1.StructuredQuery.FieldReference, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder, - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> - fieldsBuilder_; + public Builder clearOperandType() { + operandTypeCase_ = 0; + operandType_ = null; + onChanged(); + return this; + } + private int op_ = 0; /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The unary operator to apply.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The enum numeric value on the wire for op. */ - public java.util.List - getFieldsList() { - if (fieldsBuilder_ == null) { - return java.util.Collections.unmodifiableList(fields_); - } else { - return fieldsBuilder_.getMessageList(); - } + @java.lang.Override + public int getOpValue() { + return op_; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The unary operator to apply.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @param value The enum numeric value on the wire for op to set. + * @return This builder for chaining. */ - public int getFieldsCount() { - if (fieldsBuilder_ == null) { - return fields_.size(); - } else { - return fieldsBuilder_.getCount(); - } + public Builder setOpValue(int value) { + + op_ = value; + onChanged(); + return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The unary operator to apply.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return The op. */ - public com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index) { - if (fieldsBuilder_ == null) { - return fields_.get(index); - } else { - return fieldsBuilder_.getMessage(index); - } + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp() { + @SuppressWarnings("deprecation") + com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator result = + com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.valueOf(op_); + return result == null + ? com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.UNRECOGNIZED + : result; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The unary operator to apply.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @param value The op to set. + * @return This builder for chaining. */ - public Builder setFields( - int index, com.google.firestore.v1.StructuredQuery.FieldReference value) { - if (fieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.set(index, value); - onChanged(); - } else { - fieldsBuilder_.setMessage(index, value); + public Builder setOp(com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator value) { + if (value == null) { + throw new NullPointerException(); } + + op_ = value.getNumber(); + onChanged(); return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The unary operator to apply.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * + * @return This builder for chaining. */ - public Builder setFields( - int index, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.set(index, builderForValue.build()); - onChanged(); - } else { - fieldsBuilder_.setMessage(index, builderForValue.build()); - } + public Builder clearOp() { + + op_ = 0; + onChanged(); return this; } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.firestore.v1.StructuredQuery.FieldReference, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder, + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> + fieldBuilder_; /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return Whether the field field is set. */ - public Builder addFields(com.google.firestore.v1.StructuredQuery.FieldReference value) { - if (fieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); + @java.lang.Override + public boolean hasField() { + return operandTypeCase_ == 2; + } + /** + * + * + *
+       * The field to which to apply the operator.
+       * 
+ * + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; + * + * @return The field. + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.FieldReference getField() { + if (fieldBuilder_ == null) { + if (operandTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; } - ensureFieldsIsMutable(); - fields_.add(value); - onChanged(); + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); } else { - fieldsBuilder_.addMessage(value); + if (operandTypeCase_ == 2) { + return fieldBuilder_.getMessage(); + } + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); } - return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public Builder addFields( - int index, com.google.firestore.v1.StructuredQuery.FieldReference value) { - if (fieldsBuilder_ == null) { + public Builder setField(com.google.firestore.v1.StructuredQuery.FieldReference value) { + if (fieldBuilder_ == null) { if (value == null) { throw new NullPointerException(); } - ensureFieldsIsMutable(); - fields_.add(index, value); + operandType_ = value; onChanged(); } else { - fieldsBuilder_.addMessage(index, value); + fieldBuilder_.setMessage(value); } + operandTypeCase_ = 2; return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public Builder addFields( + public Builder setField( com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.add(builderForValue.build()); + if (fieldBuilder_ == null) { + operandType_ = builderForValue.build(); onChanged(); } else { - fieldsBuilder_.addMessage(builderForValue.build()); + fieldBuilder_.setMessage(builderForValue.build()); } + operandTypeCase_ = 2; return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public Builder addFields( - int index, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.add(index, builderForValue.build()); + public Builder mergeField(com.google.firestore.v1.StructuredQuery.FieldReference value) { + if (fieldBuilder_ == null) { + if (operandTypeCase_ == 2 + && operandType_ + != com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()) { + operandType_ = + com.google.firestore.v1.StructuredQuery.FieldReference.newBuilder( + (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_) + .mergeFrom(value) + .buildPartial(); + } else { + operandType_ = value; + } onChanged(); } else { - fieldsBuilder_.addMessage(index, builderForValue.build()); + if (operandTypeCase_ == 2) { + fieldBuilder_.mergeFrom(value); + } + fieldBuilder_.setMessage(value); } + operandTypeCase_ = 2; return this; } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public Builder addAllFields( - java.lang.Iterable - values) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fields_); - onChanged(); - } else { - fieldsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
-       * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public Builder clearFields() { - if (fieldsBuilder_ == null) { - fields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fieldsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
-       * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public Builder removeFields(int index) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.remove(index); - onChanged(); + public Builder clearField() { + if (fieldBuilder_ == null) { + if (operandTypeCase_ == 2) { + operandTypeCase_ = 0; + operandType_ = null; + onChanged(); + } } else { - fieldsBuilder_.remove(index); + if (operandTypeCase_ == 2) { + operandTypeCase_ = 0; + operandType_ = null; + } + fieldBuilder_.clear(); } return this; } @@ -6454,120 +6738,67 @@ public Builder removeFields(int index) { * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
-       * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReference.Builder getFieldsBuilder( - int index) { - return getFieldsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder( - int index) { - if (fieldsBuilder_ == null) { - return fields_.get(index); - } else { - return fieldsBuilder_.getMessageOrBuilder(index); - } + public com.google.firestore.v1.StructuredQuery.FieldReference.Builder getFieldBuilder() { + return getFieldFieldBuilder().getBuilder(); } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public java.util.List< - ? extends com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> - getFieldsOrBuilderList() { - if (fieldsBuilder_ != null) { - return fieldsBuilder_.getMessageOrBuilderList(); + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { + if ((operandTypeCase_ == 2) && (fieldBuilder_ != null)) { + return fieldBuilder_.getMessageOrBuilder(); } else { - return java.util.Collections.unmodifiableList(fields_); + if (operandTypeCase_ == 2) { + return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; + } + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); } } /** * * *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
-       * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReference.Builder addFieldsBuilder() { - return getFieldsFieldBuilder() - .addBuilder( - com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()); - } - /** - * - * - *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
-       * 
- * - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReference.Builder addFieldsBuilder( - int index) { - return getFieldsFieldBuilder() - .addBuilder( - index, com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()); - } - /** - * - * - *
-       * The fields to return.
-       * If empty, all fields are returned. To only return the name
-       * of the document, use `['__name__']`.
+       * The field to which to apply the operator.
        * 
* - * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + * .google.firestore.v1.StructuredQuery.FieldReference field = 2; */ - public java.util.List - getFieldsBuilderList() { - return getFieldsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< + private com.google.protobuf.SingleFieldBuilderV3< com.google.firestore.v1.StructuredQuery.FieldReference, com.google.firestore.v1.StructuredQuery.FieldReference.Builder, com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> - getFieldsFieldBuilder() { - if (fieldsBuilder_ == null) { - fieldsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< + getFieldFieldBuilder() { + if (fieldBuilder_ == null) { + if (!(operandTypeCase_ == 2)) { + operandType_ = + com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); + } + fieldBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< com.google.firestore.v1.StructuredQuery.FieldReference, com.google.firestore.v1.StructuredQuery.FieldReference.Builder, com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder>( - fields_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - fields_ = null; + (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_, + getParentForChildren(), + isClean()); + operandType_ = null; } - return fieldsBuilder_; + operandTypeCase_ = 2; + onChanged(); + ; + return fieldBuilder_; } @java.lang.Override @@ -6582,140 +6813,91 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.Projection) + // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.UnaryFilter) } - // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.Projection) - private static final com.google.firestore.v1.StructuredQuery.Projection DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.UnaryFilter) + private static final com.google.firestore.v1.StructuredQuery.UnaryFilter DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.Projection(); + DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.UnaryFilter(); } - public static com.google.firestore.v1.StructuredQuery.Projection getDefaultInstance() { + public static com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { @java.lang.Override - public Projection parsePartialFrom( + public UnaryFilter parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Projection(input, extensionRegistry); + return new UnaryFilter(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.Projection getDefaultInstanceForType() { + public com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } - public interface UnaryFilterOrBuilder + public interface FieldReferenceOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.UnaryFilter) + // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.FieldReference) com.google.protobuf.MessageOrBuilder { /** + * string field_path = 2; * - * - *
-     * The unary operator to apply.
-     * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The enum numeric value on the wire for op. + * @return The fieldPath. */ - int getOpValue(); + java.lang.String getFieldPath(); /** + * string field_path = 2; * - * - *
-     * The unary operator to apply.
-     * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The op. + * @return The bytes for fieldPath. */ - com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp(); + com.google.protobuf.ByteString getFieldPathBytes(); + } + /** + * + * + *
+   * A reference to a field, such as `max(messages.time) as max_time`.
+   * 
+ * + * Protobuf type {@code google.firestore.v1.StructuredQuery.FieldReference} + */ + public static final class FieldReference extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.FieldReference) + FieldReferenceOrBuilder { + private static final long serialVersionUID = 0L; + // Use FieldReference.newBuilder() to construct. + private FieldReference(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return Whether the field field is set. - */ - boolean hasField(); - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return The field. - */ - com.google.firestore.v1.StructuredQuery.FieldReference getField(); - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder(); - - public com.google.firestore.v1.StructuredQuery.UnaryFilter.OperandTypeCase getOperandTypeCase(); - } - /** - * - * - *
-   * A filter with a single operand.
-   * 
- * - * Protobuf type {@code google.firestore.v1.StructuredQuery.UnaryFilter} - */ - public static final class UnaryFilter extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.UnaryFilter) - UnaryFilterOrBuilder { - private static final long serialVersionUID = 0L; - // Use UnaryFilter.newBuilder() to construct. - private UnaryFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UnaryFilter() { - op_ = 0; + private FieldReference() { + fieldPath_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new UnaryFilter(); + return new FieldReference(); } @java.lang.Override @@ -6723,7 +6905,7 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UnaryFilter( + private FieldReference( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -6741,31 +6923,11 @@ private UnaryFilter( case 0: done = true; break; - case 8: - { - int rawValue = input.readEnum(); - - op_ = rawValue; - break; - } case 18: { - com.google.firestore.v1.StructuredQuery.FieldReference.Builder subBuilder = null; - if (operandTypeCase_ == 2) { - subBuilder = - ((com.google.firestore.v1.StructuredQuery.FieldReference) operandType_) - .toBuilder(); - } - operandType_ = - input.readMessage( - com.google.firestore.v1.StructuredQuery.FieldReference.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); - operandType_ = subBuilder.buildPartial(); - } - operandTypeCase_ = 2; + java.lang.String s = input.readStringRequireUtf8(); + + fieldPath_ = s; break; } default: @@ -6789,369 +6951,102 @@ private UnaryFilter( public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_fieldAccessorTable + .internal_static_google_firestore_v1_StructuredQuery_FieldReference_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.UnaryFilter.class, - com.google.firestore.v1.StructuredQuery.UnaryFilter.Builder.class); + com.google.firestore.v1.StructuredQuery.FieldReference.class, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder.class); } + public static final int FIELD_PATH_FIELD_NUMBER = 2; + private volatile java.lang.Object fieldPath_; /** + * string field_path = 2; * + * @return The fieldPath. + */ + @java.lang.Override + public java.lang.String getFieldPath() { + java.lang.Object ref = fieldPath_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + fieldPath_ = s; + return s; + } + } + /** + * string field_path = 2; * - *
-     * A unary operator.
-     * 
- * - * Protobuf enum {@code google.firestore.v1.StructuredQuery.UnaryFilter.Operator} + * @return The bytes for fieldPath. */ - public enum Operator implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unspecified. This value must not be used.
-       * 
- * - * OPERATOR_UNSPECIFIED = 0; - */ - OPERATOR_UNSPECIFIED(0), - /** - * - * - *
-       * Test if a field is equal to NaN.
-       * 
- * - * IS_NAN = 2; - */ - IS_NAN(2), - /** - * - * - *
-       * Test if an expression evaluates to Null.
-       * 
- * - * IS_NULL = 3; - */ - IS_NULL(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unspecified. This value must not be used.
-       * 
- * - * OPERATOR_UNSPECIFIED = 0; - */ - public static final int OPERATOR_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Test if a field is equal to NaN.
-       * 
- * - * IS_NAN = 2; - */ - public static final int IS_NAN_VALUE = 2; - /** - * - * - *
-       * Test if an expression evaluates to Null.
-       * 
- * - * IS_NULL = 3; - */ - public static final int IS_NULL_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; + @java.lang.Override + public com.google.protobuf.ByteString getFieldPathBytes() { + java.lang.Object ref = fieldPath_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldPath_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; } + } - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Operator valueOf(int value) { - return forNumber(value); - } + private byte memoizedIsInitialized = -1; - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static Operator forNumber(int value) { - switch (value) { - case 0: - return OPERATOR_UNSPECIFIED; - case 2: - return IS_NAN; - case 3: - return IS_NULL; - default: - return null; - } - } + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getFieldPathBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, fieldPath_); } + unknownFields.writeTo(output); + } - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Operator findValueByNumber(int number) { - return Operator.forNumber(number); - } - }; + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - return getDescriptor().getValues().get(ordinal()); + size = 0; + if (!getFieldPathBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, fieldPath_); } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.firestore.v1.StructuredQuery.UnaryFilter.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Operator[] VALUES = values(); - - public static Operator valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Operator(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.firestore.v1.StructuredQuery.UnaryFilter.Operator) - } - - private int operandTypeCase_ = 0; - private java.lang.Object operandType_; - - public enum OperandTypeCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - FIELD(2), - OPERANDTYPE_NOT_SET(0); - private final int value; - - private OperandTypeCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static OperandTypeCase valueOf(int value) { - return forNumber(value); - } - - public static OperandTypeCase forNumber(int value) { - switch (value) { - case 2: - return FIELD; - case 0: - return OPERANDTYPE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public OperandTypeCase getOperandTypeCase() { - return OperandTypeCase.forNumber(operandTypeCase_); - } - - public static final int OP_FIELD_NUMBER = 1; - private int op_; - /** - * - * - *
-     * The unary operator to apply.
-     * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The enum numeric value on the wire for op. - */ - public int getOpValue() { - return op_; - } - /** - * - * - *
-     * The unary operator to apply.
-     * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The op. - */ - public com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp() { - @SuppressWarnings("deprecation") - com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator result = - com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.valueOf(op_); - return result == null - ? com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.UNRECOGNIZED - : result; - } - - public static final int FIELD_FIELD_NUMBER = 2; - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return Whether the field field is set. - */ - public boolean hasField() { - return operandTypeCase_ == 2; - } - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return The field. - */ - public com.google.firestore.v1.StructuredQuery.FieldReference getField() { - if (operandTypeCase_ == 2) { - return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; - } - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); - } - /** - * - * - *
-     * The field to which to apply the operator.
-     * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { - if (operandTypeCase_ == 2) { - return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; - } - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (op_ - != com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.OPERATOR_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, op_); - } - if (operandTypeCase_ == 2) { - output.writeMessage( - 2, (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (op_ - != com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.OPERATOR_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, op_); - } - if (operandTypeCase_ == 2) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 2, (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.firestore.v1.StructuredQuery.UnaryFilter)) { + if (!(obj instanceof com.google.firestore.v1.StructuredQuery.FieldReference)) { return super.equals(obj); } - com.google.firestore.v1.StructuredQuery.UnaryFilter other = - (com.google.firestore.v1.StructuredQuery.UnaryFilter) obj; + com.google.firestore.v1.StructuredQuery.FieldReference other = + (com.google.firestore.v1.StructuredQuery.FieldReference) obj; - if (op_ != other.op_) return false; - if (!getOperandTypeCase().equals(other.getOperandTypeCase())) return false; - switch (operandTypeCase_) { - case 2: - if (!getField().equals(other.getField())) return false; - break; - case 0: - default: - } + if (!getFieldPath().equals(other.getFieldPath())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -7163,86 +7058,78 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + OP_FIELD_NUMBER; - hash = (53 * hash) + op_; - switch (operandTypeCase_) { - case 2: - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - break; - case 0: - default: - } + hash = (37 * hash) + FIELD_PATH_FIELD_NUMBER; + hash = (53 * hash) + getFieldPath().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom(byte[] data) + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseDelimitedFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseDelimitedFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter parseFrom( + public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -7260,7 +7147,7 @@ public static Builder newBuilder() { } public static Builder newBuilder( - com.google.firestore.v1.StructuredQuery.UnaryFilter prototype) { + com.google.firestore.v1.StructuredQuery.FieldReference prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @@ -7279,32 +7166,32 @@ protected Builder newBuilderForType( * * *
-     * A filter with a single operand.
+     * A reference to a field, such as `max(messages.time) as max_time`.
      * 
* - * Protobuf type {@code google.firestore.v1.StructuredQuery.UnaryFilter} + * Protobuf type {@code google.firestore.v1.StructuredQuery.FieldReference} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.UnaryFilter) - com.google.firestore.v1.StructuredQuery.UnaryFilterOrBuilder { + // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.FieldReference) + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_fieldAccessorTable + .internal_static_google_firestore_v1_StructuredQuery_FieldReference_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.UnaryFilter.class, - com.google.firestore.v1.StructuredQuery.UnaryFilter.Builder.class); + com.google.firestore.v1.StructuredQuery.FieldReference.class, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder.class); } - // Construct using com.google.firestore.v1.StructuredQuery.UnaryFilter.newBuilder() + // Construct using com.google.firestore.v1.StructuredQuery.FieldReference.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -7321,27 +7208,25 @@ private void maybeForceBuilderInitialization() { @java.lang.Override public Builder clear() { super.clear(); - op_ = 0; + fieldPath_ = ""; - operandTypeCase_ = 0; - operandType_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_UnaryFilter_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstanceForType() { - return com.google.firestore.v1.StructuredQuery.UnaryFilter.getDefaultInstance(); + public com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstanceForType() { + return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.UnaryFilter build() { - com.google.firestore.v1.StructuredQuery.UnaryFilter result = buildPartial(); + public com.google.firestore.v1.StructuredQuery.FieldReference build() { + com.google.firestore.v1.StructuredQuery.FieldReference result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } @@ -7349,18 +7234,10 @@ public com.google.firestore.v1.StructuredQuery.UnaryFilter build() { } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.UnaryFilter buildPartial() { - com.google.firestore.v1.StructuredQuery.UnaryFilter result = - new com.google.firestore.v1.StructuredQuery.UnaryFilter(this); - result.op_ = op_; - if (operandTypeCase_ == 2) { - if (fieldBuilder_ == null) { - result.operandType_ = operandType_; - } else { - result.operandType_ = fieldBuilder_.build(); - } - } - result.operandTypeCase_ = operandTypeCase_; + public com.google.firestore.v1.StructuredQuery.FieldReference buildPartial() { + com.google.firestore.v1.StructuredQuery.FieldReference result = + new com.google.firestore.v1.StructuredQuery.FieldReference(this); + result.fieldPath_ = fieldPath_; onBuilt(); return result; } @@ -7402,30 +7279,20 @@ public Builder addRepeatedField( @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.firestore.v1.StructuredQuery.UnaryFilter) { - return mergeFrom((com.google.firestore.v1.StructuredQuery.UnaryFilter) other); + if (other instanceof com.google.firestore.v1.StructuredQuery.FieldReference) { + return mergeFrom((com.google.firestore.v1.StructuredQuery.FieldReference) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.UnaryFilter other) { - if (other == com.google.firestore.v1.StructuredQuery.UnaryFilter.getDefaultInstance()) + public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.FieldReference other) { + if (other == com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()) return this; - if (other.op_ != 0) { - setOpValue(other.getOpValue()); - } - switch (other.getOperandTypeCase()) { - case FIELD: - { - mergeField(other.getField()); - break; - } - case OPERANDTYPE_NOT_SET: - { - break; - } + if (!other.getFieldPath().isEmpty()) { + fieldPath_ = other.fieldPath_; + onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); @@ -7442,12 +7309,12 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.firestore.v1.StructuredQuery.UnaryFilter parsedMessage = null; + com.google.firestore.v1.StructuredQuery.FieldReference parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = - (com.google.firestore.v1.StructuredQuery.UnaryFilter) e.getUnfinishedMessage(); + (com.google.firestore.v1.StructuredQuery.FieldReference) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -7457,316 +7324,80 @@ public Builder mergeFrom( return this; } - private int operandTypeCase_ = 0; - private java.lang.Object operandType_; - - public OperandTypeCase getOperandTypeCase() { - return OperandTypeCase.forNumber(operandTypeCase_); - } - - public Builder clearOperandType() { - operandTypeCase_ = 0; - operandType_ = null; - onChanged(); - return this; - } - - private int op_ = 0; - /** - * - * - *
-       * The unary operator to apply.
-       * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The enum numeric value on the wire for op. - */ - public int getOpValue() { - return op_; - } + private java.lang.Object fieldPath_ = ""; /** + * string field_path = 2; * - * - *
-       * The unary operator to apply.
-       * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @param value The enum numeric value on the wire for op to set. - * @return This builder for chaining. + * @return The fieldPath. */ - public Builder setOpValue(int value) { - op_ = value; - onChanged(); - return this; + public java.lang.String getFieldPath() { + java.lang.Object ref = fieldPath_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + fieldPath_ = s; + return s; + } else { + return (java.lang.String) ref; + } } /** + * string field_path = 2; * - * - *
-       * The unary operator to apply.
-       * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @return The op. + * @return The bytes for fieldPath. */ - public com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator getOp() { - @SuppressWarnings("deprecation") - com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator result = - com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.valueOf(op_); - return result == null - ? com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator.UNRECOGNIZED - : result; + public com.google.protobuf.ByteString getFieldPathBytes() { + java.lang.Object ref = fieldPath_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + fieldPath_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } } /** + * string field_path = 2; * - * - *
-       * The unary operator to apply.
-       * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; - * - * @param value The op to set. + * @param value The fieldPath to set. * @return This builder for chaining. */ - public Builder setOp(com.google.firestore.v1.StructuredQuery.UnaryFilter.Operator value) { + public Builder setFieldPath(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - op_ = value.getNumber(); + fieldPath_ = value; onChanged(); return this; } /** - * - * - *
-       * The unary operator to apply.
-       * 
- * - * .google.firestore.v1.StructuredQuery.UnaryFilter.Operator op = 1; + * string field_path = 2; * * @return This builder for chaining. */ - public Builder clearOp() { + public Builder clearFieldPath() { - op_ = 0; + fieldPath_ = getDefaultInstance().getFieldPath(); onChanged(); return this; } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.firestore.v1.StructuredQuery.FieldReference, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder, - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> - fieldBuilder_; - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return Whether the field field is set. - */ - public boolean hasField() { - return operandTypeCase_ == 2; - } /** + * string field_path = 2; * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - * - * @return The field. + * @param value The bytes for fieldPath to set. + * @return This builder for chaining. */ - public com.google.firestore.v1.StructuredQuery.FieldReference getField() { - if (fieldBuilder_ == null) { - if (operandTypeCase_ == 2) { - return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; - } - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); - } else { - if (operandTypeCase_ == 2) { - return fieldBuilder_.getMessage(); - } - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); + public Builder setFieldPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); } - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public Builder setField(com.google.firestore.v1.StructuredQuery.FieldReference value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - operandType_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - operandTypeCase_ = 2; - return this; - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public Builder setField( - com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { - if (fieldBuilder_ == null) { - operandType_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - operandTypeCase_ = 2; - return this; - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public Builder mergeField(com.google.firestore.v1.StructuredQuery.FieldReference value) { - if (fieldBuilder_ == null) { - if (operandTypeCase_ == 2 - && operandType_ - != com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()) { - operandType_ = - com.google.firestore.v1.StructuredQuery.FieldReference.newBuilder( - (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_) - .mergeFrom(value) - .buildPartial(); - } else { - operandType_ = value; - } - onChanged(); - } else { - if (operandTypeCase_ == 2) { - fieldBuilder_.mergeFrom(value); - } - fieldBuilder_.setMessage(value); - } - operandTypeCase_ = 2; - return this; - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - if (operandTypeCase_ == 2) { - operandTypeCase_ = 0; - operandType_ = null; - onChanged(); - } - } else { - if (operandTypeCase_ == 2) { - operandTypeCase_ = 0; - operandType_ = null; - } - fieldBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReference.Builder getFieldBuilder() { - return getFieldFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { - if ((operandTypeCase_ == 2) && (fieldBuilder_ != null)) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - if (operandTypeCase_ == 2) { - return (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_; - } - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); - } - } - /** - * - * - *
-       * The field to which to apply the operator.
-       * 
- * - * .google.firestore.v1.StructuredQuery.FieldReference field = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.firestore.v1.StructuredQuery.FieldReference, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder, - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - if (!(operandTypeCase_ == 2)) { - operandType_ = - com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); - } - fieldBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.firestore.v1.StructuredQuery.FieldReference, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder, - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder>( - (com.google.firestore.v1.StructuredQuery.FieldReference) operandType_, - getParentForChildren(), - isClean()); - operandType_ = null; - } - operandTypeCase_ = 2; - onChanged(); - ; - return fieldBuilder_; + checkByteStringIsUtf8(value); + + fieldPath_ = value; + onChanged(); + return this; } @java.lang.Override @@ -7781,91 +7412,140 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.UnaryFilter) + // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.FieldReference) } - // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.UnaryFilter) - private static final com.google.firestore.v1.StructuredQuery.UnaryFilter DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.FieldReference) + private static final com.google.firestore.v1.StructuredQuery.FieldReference DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.UnaryFilter(); + DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.FieldReference(); } - public static com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstance() { + public static com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { @java.lang.Override - public UnaryFilter parsePartialFrom( + public FieldReference parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UnaryFilter(input, extensionRegistry); + return new FieldReference(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.UnaryFilter getDefaultInstanceForType() { + public com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } - public interface FieldReferenceOrBuilder + public interface ProjectionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.FieldReference) + // @@protoc_insertion_point(interface_extends:google.firestore.v1.StructuredQuery.Projection) com.google.protobuf.MessageOrBuilder { /** - * string field_path = 2; * - * @return The fieldPath. + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - java.lang.String getFieldPath(); + java.util.List getFieldsList(); /** - * string field_path = 2; * - * @return The bytes for fieldPath. + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - com.google.protobuf.ByteString getFieldPathBytes(); + com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index); + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + int getFieldsCount(); + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + java.util.List + getFieldsOrBuilderList(); + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder(int index); } /** * * *
-   * A reference to a field, such as `max(messages.time) as max_time`.
+   * The projection of document's fields to return.
    * 
* - * Protobuf type {@code google.firestore.v1.StructuredQuery.FieldReference} + * Protobuf type {@code google.firestore.v1.StructuredQuery.Projection} */ - public static final class FieldReference extends com.google.protobuf.GeneratedMessageV3 + public static final class Projection extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.FieldReference) - FieldReferenceOrBuilder { + // @@protoc_insertion_point(message_implements:google.firestore.v1.StructuredQuery.Projection) + ProjectionOrBuilder { private static final long serialVersionUID = 0L; - // Use FieldReference.newBuilder() to construct. - private FieldReference(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use Projection.newBuilder() to construct. + private Projection(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private FieldReference() { - fieldPath_ = ""; + private Projection() { + fields_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new FieldReference(); + return new Projection(); } @java.lang.Override @@ -7873,7 +7553,7 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private FieldReference( + private Projection( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -7881,6 +7561,7 @@ private FieldReference( if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } + int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -7893,9 +7574,16 @@ private FieldReference( break; case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - fieldPath_ = s; + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + fields_ = + new java.util.ArrayList< + com.google.firestore.v1.StructuredQuery.FieldReference>(); + mutable_bitField0_ |= 0x00000001; + } + fields_.add( + input.readMessage( + com.google.firestore.v1.StructuredQuery.FieldReference.parser(), + extensionRegistry)); break; } default: @@ -7912,6 +7600,9 @@ private FieldReference( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + fields_ = java.util.Collections.unmodifiableList(fields_); + } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -7919,52 +7610,97 @@ private FieldReference( public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_FieldReference_fieldAccessorTable + .internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.FieldReference.class, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder.class); + com.google.firestore.v1.StructuredQuery.Projection.class, + com.google.firestore.v1.StructuredQuery.Projection.Builder.class); } - public static final int FIELD_PATH_FIELD_NUMBER = 2; - private volatile java.lang.Object fieldPath_; + public static final int FIELDS_FIELD_NUMBER = 2; + private java.util.List fields_; /** - * string field_path = 2; * - * @return The fieldPath. + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public java.lang.String getFieldPath() { - java.lang.Object ref = fieldPath_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - fieldPath_ = s; - return s; - } + @java.lang.Override + public java.util.List getFieldsList() { + return fields_; } /** - * string field_path = 2; * - * @return The bytes for fieldPath. + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public com.google.protobuf.ByteString getFieldPathBytes() { - java.lang.Object ref = fieldPath_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - fieldPath_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } + @java.lang.Override + public java.util.List + getFieldsOrBuilderList() { + return fields_; + } + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + @java.lang.Override + public int getFieldsCount() { + return fields_.size(); + } + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index) { + return fields_.get(index); + } + /** + * + * + *
+     * The fields to return.
+     * If empty, all fields are returned. To only return the name
+     * of the document, use `['__name__']`.
+     * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + @java.lang.Override + public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder( + int index) { + return fields_.get(index); } private byte memoizedIsInitialized = -1; @@ -7981,8 +7717,8 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getFieldPathBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, fieldPath_); + for (int i = 0; i < fields_.size(); i++) { + output.writeMessage(2, fields_.get(i)); } unknownFields.writeTo(output); } @@ -7993,8 +7729,8 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (!getFieldPathBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, fieldPath_); + for (int i = 0; i < fields_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, fields_.get(i)); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -8006,13 +7742,13 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.firestore.v1.StructuredQuery.FieldReference)) { + if (!(obj instanceof com.google.firestore.v1.StructuredQuery.Projection)) { return super.equals(obj); } - com.google.firestore.v1.StructuredQuery.FieldReference other = - (com.google.firestore.v1.StructuredQuery.FieldReference) obj; + com.google.firestore.v1.StructuredQuery.Projection other = + (com.google.firestore.v1.StructuredQuery.Projection) obj; - if (!getFieldPath().equals(other.getFieldPath())) return false; + if (!getFieldsList().equals(other.getFieldsList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -8024,78 +7760,80 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + FIELD_PATH_FIELD_NUMBER; - hash = (53 * hash) + getFieldPath().hashCode(); + if (getFieldsCount() > 0) { + hash = (37 * hash) + FIELDS_FIELD_NUMBER; + hash = (53 * hash) + getFieldsList().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom(byte[] data) + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseDelimitedFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseDelimitedFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.firestore.v1.StructuredQuery.FieldReference parseFrom( + public static com.google.firestore.v1.StructuredQuery.Projection parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -8112,8 +7850,7 @@ public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder( - com.google.firestore.v1.StructuredQuery.FieldReference prototype) { + public static Builder newBuilder(com.google.firestore.v1.StructuredQuery.Projection prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @@ -8132,32 +7869,32 @@ protected Builder newBuilderForType( * * *
-     * A reference to a field, such as `max(messages.time) as max_time`.
+     * The projection of document's fields to return.
      * 
* - * Protobuf type {@code google.firestore.v1.StructuredQuery.FieldReference} + * Protobuf type {@code google.firestore.v1.StructuredQuery.Projection} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.FieldReference) - com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder { + // @@protoc_insertion_point(builder_implements:google.firestore.v1.StructuredQuery.Projection) + com.google.firestore.v1.StructuredQuery.ProjectionOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_FieldReference_fieldAccessorTable + .internal_static_google_firestore_v1_StructuredQuery_Projection_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.firestore.v1.StructuredQuery.FieldReference.class, - com.google.firestore.v1.StructuredQuery.FieldReference.Builder.class); + com.google.firestore.v1.StructuredQuery.Projection.class, + com.google.firestore.v1.StructuredQuery.Projection.Builder.class); } - // Construct using com.google.firestore.v1.StructuredQuery.FieldReference.newBuilder() + // Construct using com.google.firestore.v1.StructuredQuery.Projection.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -8168,31 +7905,37 @@ private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { } private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getFieldsFieldBuilder(); + } } @java.lang.Override public Builder clear() { super.clear(); - fieldPath_ = ""; - + if (fieldsBuilder_ == null) { + fields_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + fieldsBuilder_.clear(); + } return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.firestore.v1.QueryProto - .internal_static_google_firestore_v1_StructuredQuery_FieldReference_descriptor; + .internal_static_google_firestore_v1_StructuredQuery_Projection_descriptor; } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstanceForType() { - return com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance(); + public com.google.firestore.v1.StructuredQuery.Projection getDefaultInstanceForType() { + return com.google.firestore.v1.StructuredQuery.Projection.getDefaultInstance(); } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.FieldReference build() { - com.google.firestore.v1.StructuredQuery.FieldReference result = buildPartial(); + public com.google.firestore.v1.StructuredQuery.Projection build() { + com.google.firestore.v1.StructuredQuery.Projection result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } @@ -8200,10 +7943,19 @@ public com.google.firestore.v1.StructuredQuery.FieldReference build() { } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.FieldReference buildPartial() { - com.google.firestore.v1.StructuredQuery.FieldReference result = - new com.google.firestore.v1.StructuredQuery.FieldReference(this); - result.fieldPath_ = fieldPath_; + public com.google.firestore.v1.StructuredQuery.Projection buildPartial() { + com.google.firestore.v1.StructuredQuery.Projection result = + new com.google.firestore.v1.StructuredQuery.Projection(this); + int from_bitField0_ = bitField0_; + if (fieldsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + fields_ = java.util.Collections.unmodifiableList(fields_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.fields_ = fields_; + } else { + result.fields_ = fieldsBuilder_.build(); + } onBuilt(); return result; } @@ -8245,125 +7997,474 @@ public Builder addRepeatedField( @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.firestore.v1.StructuredQuery.FieldReference) { - return mergeFrom((com.google.firestore.v1.StructuredQuery.FieldReference) other); + if (other instanceof com.google.firestore.v1.StructuredQuery.Projection) { + return mergeFrom((com.google.firestore.v1.StructuredQuery.Projection) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.Projection other) { + if (other == com.google.firestore.v1.StructuredQuery.Projection.getDefaultInstance()) + return this; + if (fieldsBuilder_ == null) { + if (!other.fields_.isEmpty()) { + if (fields_.isEmpty()) { + fields_ = other.fields_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureFieldsIsMutable(); + fields_.addAll(other.fields_); + } + onChanged(); + } + } else { + if (!other.fields_.isEmpty()) { + if (fieldsBuilder_.isEmpty()) { + fieldsBuilder_.dispose(); + fieldsBuilder_ = null; + fields_ = other.fields_; + bitField0_ = (bitField0_ & ~0x00000001); + fieldsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getFieldsFieldBuilder() + : null; + } else { + fieldsBuilder_.addAllMessages(other.fields_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.firestore.v1.StructuredQuery.Projection parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.firestore.v1.StructuredQuery.Projection) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List fields_ = + java.util.Collections.emptyList(); + + private void ensureFieldsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + fields_ = + new java.util.ArrayList( + fields_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.StructuredQuery.FieldReference, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder, + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> + fieldsBuilder_; + + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public java.util.List + getFieldsList() { + if (fieldsBuilder_ == null) { + return java.util.Collections.unmodifiableList(fields_); + } else { + return fieldsBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public int getFieldsCount() { + if (fieldsBuilder_ == null) { + return fields_.size(); + } else { + return fieldsBuilder_.getCount(); + } + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public com.google.firestore.v1.StructuredQuery.FieldReference getFields(int index) { + if (fieldsBuilder_ == null) { + return fields_.get(index); + } else { + return fieldsBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder setFields( + int index, com.google.firestore.v1.StructuredQuery.FieldReference value) { + if (fieldsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFieldsIsMutable(); + fields_.set(index, value); + onChanged(); + } else { + fieldsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder setFields( + int index, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { + if (fieldsBuilder_ == null) { + ensureFieldsIsMutable(); + fields_.set(index, builderForValue.build()); + onChanged(); + } else { + fieldsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder addFields(com.google.firestore.v1.StructuredQuery.FieldReference value) { + if (fieldsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFieldsIsMutable(); + fields_.add(value); + onChanged(); + } else { + fieldsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder addFields( + int index, com.google.firestore.v1.StructuredQuery.FieldReference value) { + if (fieldsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFieldsIsMutable(); + fields_.add(index, value); + onChanged(); + } else { + fieldsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder addFields( + com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { + if (fieldsBuilder_ == null) { + ensureFieldsIsMutable(); + fields_.add(builderForValue.build()); + onChanged(); + } else { + fieldsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder addFields( + int index, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder builderForValue) { + if (fieldsBuilder_ == null) { + ensureFieldsIsMutable(); + fields_.add(index, builderForValue.build()); + onChanged(); + } else { + fieldsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder addAllFields( + java.lang.Iterable + values) { + if (fieldsBuilder_ == null) { + ensureFieldsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fields_); + onChanged(); + } else { + fieldsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder clearFields() { + if (fieldsBuilder_ == null) { + fields_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); } else { - super.mergeFrom(other); - return this; + fieldsBuilder_.clear(); } + return this; } - - public Builder mergeFrom(com.google.firestore.v1.StructuredQuery.FieldReference other) { - if (other == com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()) - return this; - if (!other.getFieldPath().isEmpty()) { - fieldPath_ = other.fieldPath_; + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public Builder removeFields(int index) { + if (fieldsBuilder_ == null) { + ensureFieldsIsMutable(); + fields_.remove(index); onChanged(); + } else { + fieldsBuilder_.remove(index); } - this.mergeUnknownFields(other.unknownFields); - onChanged(); return this; } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.firestore.v1.StructuredQuery.FieldReference parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.firestore.v1.StructuredQuery.FieldReference) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; + /** + * + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; + */ + public com.google.firestore.v1.StructuredQuery.FieldReference.Builder getFieldsBuilder( + int index) { + return getFieldsFieldBuilder().getBuilder(index); } - - private java.lang.Object fieldPath_ = ""; /** - * string field_path = 2; * - * @return The fieldPath. + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public java.lang.String getFieldPath() { - java.lang.Object ref = fieldPath_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - fieldPath_ = s; - return s; + public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder( + int index) { + if (fieldsBuilder_ == null) { + return fields_.get(index); } else { - return (java.lang.String) ref; + return fieldsBuilder_.getMessageOrBuilder(index); } } /** - * string field_path = 2; * - * @return The bytes for fieldPath. + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public com.google.protobuf.ByteString getFieldPathBytes() { - java.lang.Object ref = fieldPath_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - fieldPath_ = b; - return b; + public java.util.List< + ? extends com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> + getFieldsOrBuilderList() { + if (fieldsBuilder_ != null) { + return fieldsBuilder_.getMessageOrBuilderList(); } else { - return (com.google.protobuf.ByteString) ref; + return java.util.Collections.unmodifiableList(fields_); } } /** - * string field_path = 2; * - * @param value The fieldPath to set. - * @return This builder for chaining. + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public Builder setFieldPath(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - fieldPath_ = value; - onChanged(); - return this; + public com.google.firestore.v1.StructuredQuery.FieldReference.Builder addFieldsBuilder() { + return getFieldsFieldBuilder() + .addBuilder( + com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()); } /** - * string field_path = 2; * - * @return This builder for chaining. + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public Builder clearFieldPath() { - - fieldPath_ = getDefaultInstance().getFieldPath(); - onChanged(); - return this; + public com.google.firestore.v1.StructuredQuery.FieldReference.Builder addFieldsBuilder( + int index) { + return getFieldsFieldBuilder() + .addBuilder( + index, com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance()); } /** - * string field_path = 2; * - * @param value The bytes for fieldPath to set. - * @return This builder for chaining. + * + *
+       * The fields to return.
+       * If empty, all fields are returned. To only return the name
+       * of the document, use `['__name__']`.
+       * 
+ * + * repeated .google.firestore.v1.StructuredQuery.FieldReference fields = 2; */ - public Builder setFieldPathBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + public java.util.List + getFieldsBuilderList() { + return getFieldsFieldBuilder().getBuilderList(); + } - fieldPath_ = value; - onChanged(); - return this; + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.StructuredQuery.FieldReference, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder, + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder> + getFieldsFieldBuilder() { + if (fieldsBuilder_ == null) { + fieldsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.firestore.v1.StructuredQuery.FieldReference, + com.google.firestore.v1.StructuredQuery.FieldReference.Builder, + com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder>( + fields_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + fields_ = null; + } + return fieldsBuilder_; } @java.lang.Override @@ -8378,42 +8479,42 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.FieldReference) + // @@protoc_insertion_point(builder_scope:google.firestore.v1.StructuredQuery.Projection) } - // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.FieldReference) - private static final com.google.firestore.v1.StructuredQuery.FieldReference DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.firestore.v1.StructuredQuery.Projection) + private static final com.google.firestore.v1.StructuredQuery.Projection DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.FieldReference(); + DEFAULT_INSTANCE = new com.google.firestore.v1.StructuredQuery.Projection(); } - public static com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstance() { + public static com.google.firestore.v1.StructuredQuery.Projection getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { @java.lang.Override - public FieldReference parsePartialFrom( + public Projection parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new FieldReference(input, extensionRegistry); + return new Projection(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public com.google.firestore.v1.StructuredQuery.FieldReference getDefaultInstanceForType() { + public com.google.firestore.v1.StructuredQuery.Projection getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } @@ -8606,6 +8707,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return field_ != null; } @@ -8620,6 +8722,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldReference getField() { return field_ == null ? com.google.firestore.v1.StructuredQuery.FieldReference.getDefaultInstance() @@ -8634,6 +8737,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReference getField() { * * .google.firestore.v1.StructuredQuery.FieldReference field = 1; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { return getField(); } @@ -8651,6 +8755,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldO * * @return The enum numeric value on the wire for direction. */ + @java.lang.Override public int getDirectionValue() { return direction_; } @@ -8665,6 +8770,7 @@ public int getDirectionValue() { * * @return The direction. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Direction getDirection() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.Direction result = @@ -9222,6 +9328,7 @@ public com.google.firestore.v1.StructuredQuery.FieldReferenceOrBuilder getFieldO * * @return The enum numeric value on the wire for direction. */ + @java.lang.Override public int getDirectionValue() { return direction_; } @@ -9238,6 +9345,7 @@ public int getDirectionValue() { * @return This builder for chaining. */ public Builder setDirectionValue(int value) { + direction_ = value; onChanged(); return this; @@ -9253,6 +9361,7 @@ public Builder setDirectionValue(int value) { * * @return The direction. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Direction getDirection() { @SuppressWarnings("deprecation") com.google.firestore.v1.StructuredQuery.Direction result = @@ -9365,6 +9474,7 @@ public com.google.firestore.v1.StructuredQuery.Order getDefaultInstanceForType() * * @return Whether the select field is set. */ + @java.lang.Override public boolean hasSelect() { return select_ != null; } @@ -9379,6 +9489,7 @@ public boolean hasSelect() { * * @return The select. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Projection getSelect() { return select_ == null ? com.google.firestore.v1.StructuredQuery.Projection.getDefaultInstance() @@ -9393,6 +9504,7 @@ public com.google.firestore.v1.StructuredQuery.Projection getSelect() { * * .google.firestore.v1.StructuredQuery.Projection select = 1; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.ProjectionOrBuilder getSelectOrBuilder() { return getSelect(); } @@ -9408,6 +9520,7 @@ public com.google.firestore.v1.StructuredQuery.ProjectionOrBuilder getSelectOrBu * * repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public java.util.List getFromList() { return from_; } @@ -9420,6 +9533,7 @@ public java.util.Listrepeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public java.util.List< ? extends com.google.firestore.v1.StructuredQuery.CollectionSelectorOrBuilder> getFromOrBuilderList() { @@ -9434,6 +9548,7 @@ public java.util.Listrepeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public int getFromCount() { return from_.size(); } @@ -9446,6 +9561,7 @@ public int getFromCount() { * * repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CollectionSelector getFrom(int index) { return from_.get(index); } @@ -9458,6 +9574,7 @@ public com.google.firestore.v1.StructuredQuery.CollectionSelector getFrom(int in * * repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.CollectionSelectorOrBuilder getFromOrBuilder( int index) { return from_.get(index); @@ -9476,6 +9593,7 @@ public com.google.firestore.v1.StructuredQuery.CollectionSelectorOrBuilder getFr * * @return Whether the where field is set. */ + @java.lang.Override public boolean hasWhere() { return where_ != null; } @@ -9490,6 +9608,7 @@ public boolean hasWhere() { * * @return The where. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Filter getWhere() { return where_ == null ? com.google.firestore.v1.StructuredQuery.Filter.getDefaultInstance() @@ -9504,6 +9623,7 @@ public com.google.firestore.v1.StructuredQuery.Filter getWhere() { * * .google.firestore.v1.StructuredQuery.Filter where = 3; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.FilterOrBuilder getWhereOrBuilder() { return getWhere(); } @@ -9532,6 +9652,7 @@ public com.google.firestore.v1.StructuredQuery.FilterOrBuilder getWhereOrBuilder * * repeated .google.firestore.v1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public java.util.List getOrderByList() { return orderBy_; } @@ -9557,6 +9678,7 @@ public java.util.List getOrderByL * * repeated .google.firestore.v1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public java.util.List getOrderByOrBuilderList() { return orderBy_; @@ -9583,6 +9705,7 @@ public java.util.List getOrderByL * * repeated .google.firestore.v1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public int getOrderByCount() { return orderBy_.size(); } @@ -9608,6 +9731,7 @@ public int getOrderByCount() { * * repeated .google.firestore.v1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.Order getOrderBy(int index) { return orderBy_.get(index); } @@ -9633,6 +9757,7 @@ public com.google.firestore.v1.StructuredQuery.Order getOrderBy(int index) { * * repeated .google.firestore.v1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery.OrderOrBuilder getOrderByOrBuilder(int index) { return orderBy_.get(index); } @@ -9650,6 +9775,7 @@ public com.google.firestore.v1.StructuredQuery.OrderOrBuilder getOrderByOrBuilde * * @return Whether the startAt field is set. */ + @java.lang.Override public boolean hasStartAt() { return startAt_ != null; } @@ -9664,6 +9790,7 @@ public boolean hasStartAt() { * * @return The startAt. */ + @java.lang.Override public com.google.firestore.v1.Cursor getStartAt() { return startAt_ == null ? com.google.firestore.v1.Cursor.getDefaultInstance() : startAt_; } @@ -9676,6 +9803,7 @@ public com.google.firestore.v1.Cursor getStartAt() { * * .google.firestore.v1.Cursor start_at = 7; */ + @java.lang.Override public com.google.firestore.v1.CursorOrBuilder getStartAtOrBuilder() { return getStartAt(); } @@ -9693,6 +9821,7 @@ public com.google.firestore.v1.CursorOrBuilder getStartAtOrBuilder() { * * @return Whether the endAt field is set. */ + @java.lang.Override public boolean hasEndAt() { return endAt_ != null; } @@ -9707,6 +9836,7 @@ public boolean hasEndAt() { * * @return The endAt. */ + @java.lang.Override public com.google.firestore.v1.Cursor getEndAt() { return endAt_ == null ? com.google.firestore.v1.Cursor.getDefaultInstance() : endAt_; } @@ -9719,6 +9849,7 @@ public com.google.firestore.v1.Cursor getEndAt() { * * .google.firestore.v1.Cursor end_at = 8; */ + @java.lang.Override public com.google.firestore.v1.CursorOrBuilder getEndAtOrBuilder() { return getEndAt(); } @@ -9738,6 +9869,7 @@ public com.google.firestore.v1.CursorOrBuilder getEndAtOrBuilder() { * * @return The offset. */ + @java.lang.Override public int getOffset() { return offset_; } @@ -9757,6 +9889,7 @@ public int getOffset() { * * @return Whether the limit field is set. */ + @java.lang.Override public boolean hasLimit() { return limit_ != null; } @@ -9773,6 +9906,7 @@ public boolean hasLimit() { * * @return The limit. */ + @java.lang.Override public com.google.protobuf.Int32Value getLimit() { return limit_ == null ? com.google.protobuf.Int32Value.getDefaultInstance() : limit_; } @@ -9787,6 +9921,7 @@ public com.google.protobuf.Int32Value getLimit() { * * .google.protobuf.Int32Value limit = 5; */ + @java.lang.Override public com.google.protobuf.Int32ValueOrBuilder getLimitOrBuilder() { return getLimit(); } @@ -12050,6 +12185,7 @@ public com.google.firestore.v1.CursorOrBuilder getEndAtOrBuilder() { * * @return The offset. */ + @java.lang.Override public int getOffset() { return offset_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Target.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Target.java index 09d4f87ab..6b2ce715b 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Target.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Target.java @@ -1242,6 +1242,7 @@ public QueryTypeCase getQueryTypeCase() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -1269,6 +1270,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -1293,6 +1295,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1307,6 +1310,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery getStructuredQuery() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1.StructuredQuery) queryType_; @@ -1322,6 +1326,7 @@ public com.google.firestore.v1.StructuredQuery getStructuredQuery() { * * .google.firestore.v1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1.StructuredQuery) queryType_; @@ -1855,6 +1860,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1869,6 +1875,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1.StructuredQuery getStructuredQuery() { if (structuredQueryBuilder_ == null) { if (queryTypeCase_ == 2) { @@ -2001,6 +2008,7 @@ public com.google.firestore.v1.StructuredQuery.Builder getStructuredQueryBuilder * * .google.firestore.v1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if ((queryTypeCase_ == 2) && (structuredQueryBuilder_ != null)) { return structuredQueryBuilder_.getMessageOrBuilder(); @@ -2203,6 +2211,7 @@ public ResumeTypeCase getResumeTypeCase() { * * @return Whether the query field is set. */ + @java.lang.Override public boolean hasQuery() { return targetTypeCase_ == 2; } @@ -2217,6 +2226,7 @@ public boolean hasQuery() { * * @return The query. */ + @java.lang.Override public com.google.firestore.v1.Target.QueryTarget getQuery() { if (targetTypeCase_ == 2) { return (com.google.firestore.v1.Target.QueryTarget) targetType_; @@ -2232,6 +2242,7 @@ public com.google.firestore.v1.Target.QueryTarget getQuery() { * * .google.firestore.v1.Target.QueryTarget query = 2; */ + @java.lang.Override public com.google.firestore.v1.Target.QueryTargetOrBuilder getQueryOrBuilder() { if (targetTypeCase_ == 2) { return (com.google.firestore.v1.Target.QueryTarget) targetType_; @@ -2251,6 +2262,7 @@ public com.google.firestore.v1.Target.QueryTargetOrBuilder getQueryOrBuilder() { * * @return Whether the documents field is set. */ + @java.lang.Override public boolean hasDocuments() { return targetTypeCase_ == 3; } @@ -2265,6 +2277,7 @@ public boolean hasDocuments() { * * @return The documents. */ + @java.lang.Override public com.google.firestore.v1.Target.DocumentsTarget getDocuments() { if (targetTypeCase_ == 3) { return (com.google.firestore.v1.Target.DocumentsTarget) targetType_; @@ -2280,6 +2293,7 @@ public com.google.firestore.v1.Target.DocumentsTarget getDocuments() { * * .google.firestore.v1.Target.DocumentsTarget documents = 3; */ + @java.lang.Override public com.google.firestore.v1.Target.DocumentsTargetOrBuilder getDocumentsOrBuilder() { if (targetTypeCase_ == 3) { return (com.google.firestore.v1.Target.DocumentsTarget) targetType_; @@ -2300,6 +2314,7 @@ public com.google.firestore.v1.Target.DocumentsTargetOrBuilder getDocumentsOrBui * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { if (resumeTypeCase_ == 4) { return (com.google.protobuf.ByteString) resumeType_; @@ -2320,6 +2335,7 @@ public com.google.protobuf.ByteString getResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return resumeTypeCase_ == 11; } @@ -2335,6 +2351,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (resumeTypeCase_ == 11) { return (com.google.protobuf.Timestamp) resumeType_; @@ -2351,6 +2368,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 11; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (resumeTypeCase_ == 11) { return (com.google.protobuf.Timestamp) resumeType_; @@ -2372,6 +2390,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -2389,6 +2408,7 @@ public int getTargetId() { * * @return The once. */ + @java.lang.Override public boolean getOnce() { return once_; } @@ -2903,6 +2923,7 @@ public Builder clearResumeType() { * * @return Whether the query field is set. */ + @java.lang.Override public boolean hasQuery() { return targetTypeCase_ == 2; } @@ -2917,6 +2938,7 @@ public boolean hasQuery() { * * @return The query. */ + @java.lang.Override public com.google.firestore.v1.Target.QueryTarget getQuery() { if (queryBuilder_ == null) { if (targetTypeCase_ == 2) { @@ -3048,6 +3070,7 @@ public com.google.firestore.v1.Target.QueryTarget.Builder getQueryBuilder() { * * .google.firestore.v1.Target.QueryTarget query = 2; */ + @java.lang.Override public com.google.firestore.v1.Target.QueryTargetOrBuilder getQueryOrBuilder() { if ((targetTypeCase_ == 2) && (queryBuilder_ != null)) { return queryBuilder_.getMessageOrBuilder(); @@ -3108,6 +3131,7 @@ public com.google.firestore.v1.Target.QueryTargetOrBuilder getQueryOrBuilder() { * * @return Whether the documents field is set. */ + @java.lang.Override public boolean hasDocuments() { return targetTypeCase_ == 3; } @@ -3122,6 +3146,7 @@ public boolean hasDocuments() { * * @return The documents. */ + @java.lang.Override public com.google.firestore.v1.Target.DocumentsTarget getDocuments() { if (documentsBuilder_ == null) { if (targetTypeCase_ == 3) { @@ -3254,6 +3279,7 @@ public com.google.firestore.v1.Target.DocumentsTarget.Builder getDocumentsBuilde * * .google.firestore.v1.Target.DocumentsTarget documents = 3; */ + @java.lang.Override public com.google.firestore.v1.Target.DocumentsTargetOrBuilder getDocumentsOrBuilder() { if ((targetTypeCase_ == 3) && (documentsBuilder_ != null)) { return documentsBuilder_.getMessageOrBuilder(); @@ -3376,6 +3402,7 @@ public Builder clearResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return resumeTypeCase_ == 11; } @@ -3391,6 +3418,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (resumeTypeCase_ == 11) { @@ -3527,6 +3555,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 11; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((resumeTypeCase_ == 11) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -3583,6 +3612,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -3636,6 +3666,7 @@ public Builder clearTargetId() { * * @return The once. */ + @java.lang.Override public boolean getOnce() { return once_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TargetChange.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TargetChange.java index 37c960fc8..1235999da 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TargetChange.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TargetChange.java @@ -356,6 +356,10 @@ public TargetChangeType findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -402,6 +406,7 @@ private TargetChangeType(int value) { * * @return The enum numeric value on the wire for targetChangeType. */ + @java.lang.Override public int getTargetChangeTypeValue() { return targetChangeType_; } @@ -416,6 +421,7 @@ public int getTargetChangeTypeValue() { * * @return The targetChangeType. */ + @java.lang.Override public com.google.firestore.v1.TargetChange.TargetChangeType getTargetChangeType() { @SuppressWarnings("deprecation") com.google.firestore.v1.TargetChange.TargetChangeType result = @@ -440,6 +446,7 @@ public com.google.firestore.v1.TargetChange.TargetChangeType getTargetChangeType * * @return A list containing the targetIds. */ + @java.lang.Override public java.util.List getTargetIdsList() { return targetIds_; } @@ -492,6 +499,7 @@ public int getTargetIds(int index) { * * @return Whether the cause field is set. */ + @java.lang.Override public boolean hasCause() { return cause_ != null; } @@ -506,6 +514,7 @@ public boolean hasCause() { * * @return The cause. */ + @java.lang.Override public com.google.rpc.Status getCause() { return cause_ == null ? com.google.rpc.Status.getDefaultInstance() : cause_; } @@ -518,6 +527,7 @@ public com.google.rpc.Status getCause() { * * .google.rpc.Status cause = 3; */ + @java.lang.Override public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { return getCause(); } @@ -537,6 +547,7 @@ public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { return resumeToken_; } @@ -561,6 +572,7 @@ public com.google.protobuf.ByteString getResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -582,6 +594,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -601,6 +614,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 6; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -1048,6 +1062,7 @@ public Builder mergeFrom( * * @return The enum numeric value on the wire for targetChangeType. */ + @java.lang.Override public int getTargetChangeTypeValue() { return targetChangeType_; } @@ -1064,6 +1079,7 @@ public int getTargetChangeTypeValue() { * @return This builder for chaining. */ public Builder setTargetChangeTypeValue(int value) { + targetChangeType_ = value; onChanged(); return this; @@ -1079,6 +1095,7 @@ public Builder setTargetChangeTypeValue(int value) { * * @return The targetChangeType. */ + @java.lang.Override public com.google.firestore.v1.TargetChange.TargetChangeType getTargetChangeType() { @SuppressWarnings("deprecation") com.google.firestore.v1.TargetChange.TargetChangeType result = @@ -1454,6 +1471,7 @@ public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { return resumeToken_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TransactionOptions.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TransactionOptions.java index f1e503a86..8dc0c2952 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TransactionOptions.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/TransactionOptions.java @@ -260,6 +260,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The retryTransaction. */ + @java.lang.Override public com.google.protobuf.ByteString getRetryTransaction() { return retryTransaction_; } @@ -599,6 +600,7 @@ public Builder mergeFrom( * * @return The retryTransaction. */ + @java.lang.Override public com.google.protobuf.ByteString getRetryTransaction() { return retryTransaction_; } @@ -895,6 +897,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 2; } @@ -910,6 +913,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 2) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -926,6 +930,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 2) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1316,6 +1321,7 @@ public Builder clearConsistencySelector() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 2; } @@ -1331,6 +1337,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 2) { @@ -1468,6 +1475,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 2) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -1624,6 +1632,7 @@ public ModeCase getModeCase() { * * @return Whether the readOnly field is set. */ + @java.lang.Override public boolean hasReadOnly() { return modeCase_ == 2; } @@ -1638,6 +1647,7 @@ public boolean hasReadOnly() { * * @return The readOnly. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadOnly getReadOnly() { if (modeCase_ == 2) { return (com.google.firestore.v1.TransactionOptions.ReadOnly) mode_; @@ -1653,6 +1663,7 @@ public com.google.firestore.v1.TransactionOptions.ReadOnly getReadOnly() { * * .google.firestore.v1.TransactionOptions.ReadOnly read_only = 2; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyOrBuilder() { if (modeCase_ == 2) { return (com.google.firestore.v1.TransactionOptions.ReadOnly) mode_; @@ -1672,6 +1683,7 @@ public com.google.firestore.v1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyO * * @return Whether the readWrite field is set. */ + @java.lang.Override public boolean hasReadWrite() { return modeCase_ == 3; } @@ -1686,6 +1698,7 @@ public boolean hasReadWrite() { * * @return The readWrite. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadWrite getReadWrite() { if (modeCase_ == 3) { return (com.google.firestore.v1.TransactionOptions.ReadWrite) mode_; @@ -1701,6 +1714,7 @@ public com.google.firestore.v1.TransactionOptions.ReadWrite getReadWrite() { * * .google.firestore.v1.TransactionOptions.ReadWrite read_write = 3; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadWriteOrBuilder getReadWriteOrBuilder() { if (modeCase_ == 3) { return (com.google.firestore.v1.TransactionOptions.ReadWrite) mode_; @@ -2110,6 +2124,7 @@ public Builder clearMode() { * * @return Whether the readOnly field is set. */ + @java.lang.Override public boolean hasReadOnly() { return modeCase_ == 2; } @@ -2124,6 +2139,7 @@ public boolean hasReadOnly() { * * @return The readOnly. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadOnly getReadOnly() { if (readOnlyBuilder_ == null) { if (modeCase_ == 2) { @@ -2256,6 +2272,7 @@ public com.google.firestore.v1.TransactionOptions.ReadOnly.Builder getReadOnlyBu * * .google.firestore.v1.TransactionOptions.ReadOnly read_only = 2; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyOrBuilder() { if ((modeCase_ == 2) && (readOnlyBuilder_ != null)) { return readOnlyBuilder_.getMessageOrBuilder(); @@ -2316,6 +2333,7 @@ public com.google.firestore.v1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyO * * @return Whether the readWrite field is set. */ + @java.lang.Override public boolean hasReadWrite() { return modeCase_ == 3; } @@ -2330,6 +2348,7 @@ public boolean hasReadWrite() { * * @return The readWrite. */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadWrite getReadWrite() { if (readWriteBuilder_ == null) { if (modeCase_ == 3) { @@ -2462,6 +2481,7 @@ public com.google.firestore.v1.TransactionOptions.ReadWrite.Builder getReadWrite * * .google.firestore.v1.TransactionOptions.ReadWrite read_write = 3; */ + @java.lang.Override public com.google.firestore.v1.TransactionOptions.ReadWriteOrBuilder getReadWriteOrBuilder() { if ((modeCase_ == 3) && (readWriteBuilder_ != null)) { return readWriteBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/UpdateDocumentRequest.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/UpdateDocumentRequest.java index 190aa6e59..f03cf378f 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/UpdateDocumentRequest.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/UpdateDocumentRequest.java @@ -180,6 +180,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -196,6 +197,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1.Document getDocument() { return document_ == null ? com.google.firestore.v1.Document.getDefaultInstance() : document_; } @@ -210,6 +212,7 @@ public com.google.firestore.v1.Document getDocument() { * .google.firestore.v1.Document document = 1 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -232,6 +235,7 @@ public com.google.firestore.v1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the updateMask field is set. */ + @java.lang.Override public boolean hasUpdateMask() { return updateMask_ != null; } @@ -251,6 +255,7 @@ public boolean hasUpdateMask() { * * @return The updateMask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getUpdateMask() { return updateMask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() @@ -270,6 +275,7 @@ public com.google.firestore.v1.DocumentMask getUpdateMask() { * * .google.firestore.v1.DocumentMask update_mask = 2; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { return getUpdateMask(); } @@ -289,6 +295,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -305,6 +312,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() : mask_; } @@ -319,6 +327,7 @@ public com.google.firestore.v1.DocumentMask getMask() { * * .google.firestore.v1.DocumentMask mask = 3; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -337,6 +346,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -352,6 +362,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1.Precondition.getDefaultInstance() @@ -367,6 +378,7 @@ public com.google.firestore.v1.Precondition getCurrentDocument() { * * .google.firestore.v1.Precondition current_document = 4; */ + @java.lang.Override public com.google.firestore.v1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Value.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Value.java index 74958b5f8..5965bdf11 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Value.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Value.java @@ -330,6 +330,7 @@ public com.google.protobuf.NullValue getNullValue() { * * @return The booleanValue. */ + @java.lang.Override public boolean getBooleanValue() { if (valueTypeCase_ == 1) { return (java.lang.Boolean) valueType_; @@ -349,6 +350,7 @@ public boolean getBooleanValue() { * * @return The integerValue. */ + @java.lang.Override public long getIntegerValue() { if (valueTypeCase_ == 2) { return (java.lang.Long) valueType_; @@ -368,6 +370,7 @@ public long getIntegerValue() { * * @return The doubleValue. */ + @java.lang.Override public double getDoubleValue() { if (valueTypeCase_ == 3) { return (java.lang.Double) valueType_; @@ -389,6 +392,7 @@ public double getDoubleValue() { * * @return Whether the timestampValue field is set. */ + @java.lang.Override public boolean hasTimestampValue() { return valueTypeCase_ == 10; } @@ -405,6 +409,7 @@ public boolean hasTimestampValue() { * * @return The timestampValue. */ + @java.lang.Override public com.google.protobuf.Timestamp getTimestampValue() { if (valueTypeCase_ == 10) { return (com.google.protobuf.Timestamp) valueType_; @@ -422,6 +427,7 @@ public com.google.protobuf.Timestamp getTimestampValue() { * * .google.protobuf.Timestamp timestamp_value = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { if (valueTypeCase_ == 10) { return (com.google.protobuf.Timestamp) valueType_; @@ -505,6 +511,7 @@ public com.google.protobuf.ByteString getStringValueBytes() { * * @return The bytesValue. */ + @java.lang.Override public com.google.protobuf.ByteString getBytesValue() { if (valueTypeCase_ == 18) { return (com.google.protobuf.ByteString) valueType_; @@ -582,6 +589,7 @@ public com.google.protobuf.ByteString getReferenceValueBytes() { * * @return Whether the geoPointValue field is set. */ + @java.lang.Override public boolean hasGeoPointValue() { return valueTypeCase_ == 8; } @@ -596,6 +604,7 @@ public boolean hasGeoPointValue() { * * @return The geoPointValue. */ + @java.lang.Override public com.google.type.LatLng getGeoPointValue() { if (valueTypeCase_ == 8) { return (com.google.type.LatLng) valueType_; @@ -611,6 +620,7 @@ public com.google.type.LatLng getGeoPointValue() { * * .google.type.LatLng geo_point_value = 8; */ + @java.lang.Override public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { if (valueTypeCase_ == 8) { return (com.google.type.LatLng) valueType_; @@ -632,6 +642,7 @@ public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { * * @return Whether the arrayValue field is set. */ + @java.lang.Override public boolean hasArrayValue() { return valueTypeCase_ == 9; } @@ -648,6 +659,7 @@ public boolean hasArrayValue() { * * @return The arrayValue. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getArrayValue() { if (valueTypeCase_ == 9) { return (com.google.firestore.v1.ArrayValue) valueType_; @@ -665,6 +677,7 @@ public com.google.firestore.v1.ArrayValue getArrayValue() { * * .google.firestore.v1.ArrayValue array_value = 9; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getArrayValueOrBuilder() { if (valueTypeCase_ == 9) { return (com.google.firestore.v1.ArrayValue) valueType_; @@ -684,6 +697,7 @@ public com.google.firestore.v1.ArrayValueOrBuilder getArrayValueOrBuilder() { * * @return Whether the mapValue field is set. */ + @java.lang.Override public boolean hasMapValue() { return valueTypeCase_ == 6; } @@ -698,6 +712,7 @@ public boolean hasMapValue() { * * @return The mapValue. */ + @java.lang.Override public com.google.firestore.v1.MapValue getMapValue() { if (valueTypeCase_ == 6) { return (com.google.firestore.v1.MapValue) valueType_; @@ -713,6 +728,7 @@ public com.google.firestore.v1.MapValue getMapValue() { * * .google.firestore.v1.MapValue map_value = 6; */ + @java.lang.Override public com.google.firestore.v1.MapValueOrBuilder getMapValueOrBuilder() { if (valueTypeCase_ == 6) { return (com.google.firestore.v1.MapValue) valueType_; @@ -1332,6 +1348,7 @@ public Builder clearValueType() { * * @return The enum numeric value on the wire for nullValue. */ + @java.lang.Override public int getNullValueValue() { if (valueTypeCase_ == 11) { return ((java.lang.Integer) valueType_).intValue(); @@ -1367,6 +1384,7 @@ public Builder setNullValueValue(int value) { * * @return The nullValue. */ + @java.lang.Override public com.google.protobuf.NullValue getNullValue() { if (valueTypeCase_ == 11) { @SuppressWarnings("deprecation") @@ -1600,6 +1618,7 @@ public Builder clearDoubleValue() { * * @return Whether the timestampValue field is set. */ + @java.lang.Override public boolean hasTimestampValue() { return valueTypeCase_ == 10; } @@ -1616,6 +1635,7 @@ public boolean hasTimestampValue() { * * @return The timestampValue. */ + @java.lang.Override public com.google.protobuf.Timestamp getTimestampValue() { if (timestampValueBuilder_ == null) { if (valueTypeCase_ == 10) { @@ -1758,6 +1778,7 @@ public com.google.protobuf.Timestamp.Builder getTimestampValueBuilder() { * * .google.protobuf.Timestamp timestamp_value = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { if ((valueTypeCase_ == 10) && (timestampValueBuilder_ != null)) { return timestampValueBuilder_.getMessageOrBuilder(); @@ -1816,6 +1837,7 @@ public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { * * @return The stringValue. */ + @java.lang.Override public java.lang.String getStringValue() { java.lang.Object ref = ""; if (valueTypeCase_ == 17) { @@ -1846,6 +1868,7 @@ public java.lang.String getStringValue() { * * @return The bytes for stringValue. */ + @java.lang.Override public com.google.protobuf.ByteString getStringValueBytes() { java.lang.Object ref = ""; if (valueTypeCase_ == 17) { @@ -2010,6 +2033,7 @@ public Builder clearBytesValue() { * * @return The referenceValue. */ + @java.lang.Override public java.lang.String getReferenceValue() { java.lang.Object ref = ""; if (valueTypeCase_ == 5) { @@ -2038,6 +2062,7 @@ public java.lang.String getReferenceValue() { * * @return The bytes for referenceValue. */ + @java.lang.Override public com.google.protobuf.ByteString getReferenceValueBytes() { java.lang.Object ref = ""; if (valueTypeCase_ == 5) { @@ -2134,6 +2159,7 @@ public Builder setReferenceValueBytes(com.google.protobuf.ByteString value) { * * @return Whether the geoPointValue field is set. */ + @java.lang.Override public boolean hasGeoPointValue() { return valueTypeCase_ == 8; } @@ -2148,6 +2174,7 @@ public boolean hasGeoPointValue() { * * @return The geoPointValue. */ + @java.lang.Override public com.google.type.LatLng getGeoPointValue() { if (geoPointValueBuilder_ == null) { if (valueTypeCase_ == 8) { @@ -2277,6 +2304,7 @@ public com.google.type.LatLng.Builder getGeoPointValueBuilder() { * * .google.type.LatLng geo_point_value = 8; */ + @java.lang.Override public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { if ((valueTypeCase_ == 8) && (geoPointValueBuilder_ != null)) { return geoPointValueBuilder_.getMessageOrBuilder(); @@ -2335,6 +2363,7 @@ public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { * * @return Whether the arrayValue field is set. */ + @java.lang.Override public boolean hasArrayValue() { return valueTypeCase_ == 9; } @@ -2351,6 +2380,7 @@ public boolean hasArrayValue() { * * @return The arrayValue. */ + @java.lang.Override public com.google.firestore.v1.ArrayValue getArrayValue() { if (arrayValueBuilder_ == null) { if (valueTypeCase_ == 9) { @@ -2494,6 +2524,7 @@ public com.google.firestore.v1.ArrayValue.Builder getArrayValueBuilder() { * * .google.firestore.v1.ArrayValue array_value = 9; */ + @java.lang.Override public com.google.firestore.v1.ArrayValueOrBuilder getArrayValueOrBuilder() { if ((valueTypeCase_ == 9) && (arrayValueBuilder_ != null)) { return arrayValueBuilder_.getMessageOrBuilder(); @@ -2554,6 +2585,7 @@ public com.google.firestore.v1.ArrayValueOrBuilder getArrayValueOrBuilder() { * * @return Whether the mapValue field is set. */ + @java.lang.Override public boolean hasMapValue() { return valueTypeCase_ == 6; } @@ -2568,6 +2600,7 @@ public boolean hasMapValue() { * * @return The mapValue. */ + @java.lang.Override public com.google.firestore.v1.MapValue getMapValue() { if (mapValueBuilder_ == null) { if (valueTypeCase_ == 6) { @@ -2699,6 +2732,7 @@ public com.google.firestore.v1.MapValue.Builder getMapValueBuilder() { * * .google.firestore.v1.MapValue map_value = 6; */ + @java.lang.Override public com.google.firestore.v1.MapValueOrBuilder getMapValueOrBuilder() { if ((valueTypeCase_ == 6) && (mapValueBuilder_ != null)) { return mapValueBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Write.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Write.java index d840d2b9b..9c59027a4 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Write.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/Write.java @@ -252,6 +252,7 @@ public OperationCase getOperationCase() { * * @return Whether the update field is set. */ + @java.lang.Override public boolean hasUpdate() { return operationCase_ == 1; } @@ -266,6 +267,7 @@ public boolean hasUpdate() { * * @return The update. */ + @java.lang.Override public com.google.firestore.v1.Document getUpdate() { if (operationCase_ == 1) { return (com.google.firestore.v1.Document) operation_; @@ -281,6 +283,7 @@ public com.google.firestore.v1.Document getUpdate() { * * .google.firestore.v1.Document update = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getUpdateOrBuilder() { if (operationCase_ == 1) { return (com.google.firestore.v1.Document) operation_; @@ -358,6 +361,7 @@ public com.google.protobuf.ByteString getDeleteBytes() { * * @return Whether the transform field is set. */ + @java.lang.Override public boolean hasTransform() { return operationCase_ == 6; } @@ -372,6 +376,7 @@ public boolean hasTransform() { * * @return The transform. */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform getTransform() { if (operationCase_ == 6) { return (com.google.firestore.v1.DocumentTransform) operation_; @@ -387,6 +392,7 @@ public com.google.firestore.v1.DocumentTransform getTransform() { * * .google.firestore.v1.DocumentTransform transform = 6; */ + @java.lang.Override public com.google.firestore.v1.DocumentTransformOrBuilder getTransformOrBuilder() { if (operationCase_ == 6) { return (com.google.firestore.v1.DocumentTransform) operation_; @@ -415,6 +421,7 @@ public com.google.firestore.v1.DocumentTransformOrBuilder getTransformOrBuilder( * * @return Whether the updateMask field is set. */ + @java.lang.Override public boolean hasUpdateMask() { return updateMask_ != null; } @@ -437,6 +444,7 @@ public boolean hasUpdateMask() { * * @return The updateMask. */ + @java.lang.Override public com.google.firestore.v1.DocumentMask getUpdateMask() { return updateMask_ == null ? com.google.firestore.v1.DocumentMask.getDefaultInstance() @@ -459,6 +467,7 @@ public com.google.firestore.v1.DocumentMask getUpdateMask() { * * .google.firestore.v1.DocumentMask update_mask = 3; */ + @java.lang.Override public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { return getUpdateMask(); } @@ -479,6 +488,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform update_transforms = 7; * */ + @java.lang.Override public java.util.List getUpdateTransformsList() { return updateTransforms_; @@ -496,6 +506,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform update_transforms = 7; * */ + @java.lang.Override public java.util.List getUpdateTransformsOrBuilderList() { return updateTransforms_; @@ -513,6 +524,7 @@ public com.google.firestore.v1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform update_transforms = 7; * */ + @java.lang.Override public int getUpdateTransformsCount() { return updateTransforms_.size(); } @@ -529,6 +541,7 @@ public int getUpdateTransformsCount() { * repeated .google.firestore.v1.DocumentTransform.FieldTransform update_transforms = 7; * */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform.FieldTransform getUpdateTransforms(int index) { return updateTransforms_.get(index); } @@ -545,6 +558,7 @@ public com.google.firestore.v1.DocumentTransform.FieldTransform getUpdateTransfo * repeated .google.firestore.v1.DocumentTransform.FieldTransform update_transforms = 7; * */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform.FieldTransformOrBuilder getUpdateTransformsOrBuilder(int index) { return updateTransforms_.get(index); @@ -564,6 +578,7 @@ public com.google.firestore.v1.DocumentTransform.FieldTransform getUpdateTransfo * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -579,6 +594,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1.Precondition.getDefaultInstance() @@ -594,6 +610,7 @@ public com.google.firestore.v1.Precondition getCurrentDocument() { * * .google.firestore.v1.Precondition current_document = 4; */ + @java.lang.Override public com.google.firestore.v1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } @@ -1133,6 +1150,7 @@ public Builder clearOperation() { * * @return Whether the update field is set. */ + @java.lang.Override public boolean hasUpdate() { return operationCase_ == 1; } @@ -1147,6 +1165,7 @@ public boolean hasUpdate() { * * @return The update. */ + @java.lang.Override public com.google.firestore.v1.Document getUpdate() { if (updateBuilder_ == null) { if (operationCase_ == 1) { @@ -1278,6 +1297,7 @@ public com.google.firestore.v1.Document.Builder getUpdateBuilder() { * * .google.firestore.v1.Document update = 1; */ + @java.lang.Override public com.google.firestore.v1.DocumentOrBuilder getUpdateOrBuilder() { if ((operationCase_ == 1) && (updateBuilder_ != null)) { return updateBuilder_.getMessageOrBuilder(); @@ -1332,6 +1352,7 @@ public com.google.firestore.v1.DocumentOrBuilder getUpdateOrBuilder() { * * @return The delete. */ + @java.lang.Override public java.lang.String getDelete() { java.lang.Object ref = ""; if (operationCase_ == 2) { @@ -1360,6 +1381,7 @@ public java.lang.String getDelete() { * * @return The bytes for delete. */ + @java.lang.Override public com.google.protobuf.ByteString getDeleteBytes() { java.lang.Object ref = ""; if (operationCase_ == 2) { @@ -1458,6 +1480,7 @@ public Builder setDeleteBytes(com.google.protobuf.ByteString value) { * * @return Whether the transform field is set. */ + @java.lang.Override public boolean hasTransform() { return operationCase_ == 6; } @@ -1472,6 +1495,7 @@ public boolean hasTransform() { * * @return The transform. */ + @java.lang.Override public com.google.firestore.v1.DocumentTransform getTransform() { if (transformBuilder_ == null) { if (operationCase_ == 6) { @@ -1603,6 +1627,7 @@ public com.google.firestore.v1.DocumentTransform.Builder getTransformBuilder() { * * .google.firestore.v1.DocumentTransform transform = 6; */ + @java.lang.Override public com.google.firestore.v1.DocumentTransformOrBuilder getTransformOrBuilder() { if ((operationCase_ == 6) && (transformBuilder_ != null)) { return transformBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteProto.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteProto.java index 49b3cc2e9..13d160298 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteProto.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteProto.java @@ -109,11 +109,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "document\030\001 \001(\t\022\032\n\022removed_target_ids\030\002 \003" + "(\005\022-\n\tread_time\030\004 \001(\0132\032.google.protobuf." + "Timestamp\"3\n\017ExistenceFilter\022\021\n\ttarget_i" - + "d\030\001 \001(\005\022\r\n\005count\030\002 \001(\005B\244\001\n\027com.google.fi" + + "d\030\001 \001(\005\022\r\n\005count\030\002 \001(\005B\303\001\n\027com.google.fi" + "restore.v1B\nWriteProtoP\001Zrepeated .google.firestore.v1.Write writes = 3; */ + @java.lang.Override public java.util.List getWritesList() { return writes_; } @@ -303,6 +308,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1.Write writes = 3; */ + @java.lang.Override public java.util.List getWritesOrBuilderList() { return writes_; } @@ -319,6 +325,7 @@ public java.util.List getWrite * * repeated .google.firestore.v1.Write writes = 3; */ + @java.lang.Override public int getWritesCount() { return writes_.size(); } @@ -335,6 +342,7 @@ public int getWritesCount() { * * repeated .google.firestore.v1.Write writes = 3; */ + @java.lang.Override public com.google.firestore.v1.Write getWrites(int index) { return writes_.get(index); } @@ -351,6 +359,7 @@ public com.google.firestore.v1.Write getWrites(int index) { * * repeated .google.firestore.v1.Write writes = 3; */ + @java.lang.Override public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { return writes_.get(index); } @@ -377,6 +386,7 @@ public com.google.firestore.v1.WriteOrBuilder getWritesOrBuilder(int index) { * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -415,6 +425,7 @@ public int getLabelsCount() { * * map<string, string> labels = 5; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -422,6 +433,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -435,6 +447,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -447,6 +460,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); @@ -463,6 +477,7 @@ public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.Strin * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1593,6 +1608,7 @@ public java.util.List getWritesBuilderLis * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -1687,6 +1703,7 @@ public int getLabelsCount() { * * map<string, string> labels = 5; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1694,6 +1711,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -1707,6 +1725,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -1719,6 +1738,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { @@ -1736,6 +1756,7 @@ public java.lang.String getLabelsOrDefault( * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResponse.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResponse.java index fa1fb8cf3..69ae28718 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResponse.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResponse.java @@ -162,6 +162,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The streamId. */ + @java.lang.Override public java.lang.String getStreamId() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -185,6 +186,7 @@ public java.lang.String getStreamId() { * * @return The bytes for streamId. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamIdBytes() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -212,6 +214,7 @@ public com.google.protobuf.ByteString getStreamIdBytes() { * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -229,6 +232,7 @@ public com.google.protobuf.ByteString getStreamToken() { * * repeated .google.firestore.v1.WriteResult write_results = 3; */ + @java.lang.Override public java.util.List getWriteResultsList() { return writeResults_; } @@ -243,6 +247,7 @@ public java.util.List getWriteResultsList() * * repeated .google.firestore.v1.WriteResult write_results = 3; */ + @java.lang.Override public java.util.List getWriteResultsOrBuilderList() { return writeResults_; @@ -258,6 +263,7 @@ public java.util.List getWriteResultsList() * * repeated .google.firestore.v1.WriteResult write_results = 3; */ + @java.lang.Override public int getWriteResultsCount() { return writeResults_.size(); } @@ -272,6 +278,7 @@ public int getWriteResultsCount() { * * repeated .google.firestore.v1.WriteResult write_results = 3; */ + @java.lang.Override public com.google.firestore.v1.WriteResult getWriteResults(int index) { return writeResults_.get(index); } @@ -286,6 +293,7 @@ public com.google.firestore.v1.WriteResult getWriteResults(int index) { * * repeated .google.firestore.v1.WriteResult write_results = 3; */ + @java.lang.Override public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { return writeResults_.get(index); } @@ -304,6 +312,7 @@ public com.google.firestore.v1.WriteResultOrBuilder getWriteResultsOrBuilder(int * * @return Whether the commitTime field is set. */ + @java.lang.Override public boolean hasCommitTime() { return commitTime_ != null; } @@ -319,6 +328,7 @@ public boolean hasCommitTime() { * * @return The commitTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCommitTime() { return commitTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : commitTime_; } @@ -332,6 +342,7 @@ public com.google.protobuf.Timestamp getCommitTime() { * * .google.protobuf.Timestamp commit_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCommitTimeOrBuilder() { return getCommitTime(); } @@ -876,6 +887,7 @@ public Builder setStreamIdBytes(com.google.protobuf.ByteString value) { * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } diff --git a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResult.java b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResult.java index 80f679139..060d0fa6e 100644 --- a/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResult.java +++ b/proto-google-cloud-firestore-v1/src/main/java/com/google/firestore/v1/WriteResult.java @@ -149,6 +149,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return updateTime_ != null; } @@ -166,6 +167,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } @@ -181,6 +183,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return getUpdateTime(); } @@ -197,6 +200,7 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { * * repeated .google.firestore.v1.Value transform_results = 2; */ + @java.lang.Override public java.util.List getTransformResultsList() { return transformResults_; } @@ -210,6 +214,7 @@ public java.util.List getTransformResultsList() { * * repeated .google.firestore.v1.Value transform_results = 2; */ + @java.lang.Override public java.util.List getTransformResultsOrBuilderList() { return transformResults_; @@ -224,6 +229,7 @@ public java.util.List getTransformResultsList() { * * repeated .google.firestore.v1.Value transform_results = 2; */ + @java.lang.Override public int getTransformResultsCount() { return transformResults_.size(); } @@ -237,6 +243,7 @@ public int getTransformResultsCount() { * * repeated .google.firestore.v1.Value transform_results = 2; */ + @java.lang.Override public com.google.firestore.v1.Value getTransformResults(int index) { return transformResults_.get(index); } @@ -250,6 +257,7 @@ public com.google.firestore.v1.Value getTransformResults(int index) { * * repeated .google.firestore.v1.Value transform_results = 2; */ + @java.lang.Override public com.google.firestore.v1.ValueOrBuilder getTransformResultsOrBuilder(int index) { return transformResults_.get(index); } diff --git a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/common.proto b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/common.proto index b6de070a5..4367f168d 100644 --- a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/common.proto +++ b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/common.proto @@ -26,6 +26,7 @@ option java_outer_classname = "CommonProto"; option java_package = "com.google.firestore.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1"; +option ruby_package = "Google::Cloud::Firestore::V1"; // A set of field paths on a document. // Used to restrict a get or update operation on a document to a subset of its diff --git a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/document.proto b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/document.proto index 43f69478e..148d2bddd 100644 --- a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/document.proto +++ b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/document.proto @@ -28,6 +28,7 @@ option java_outer_classname = "DocumentProto"; option java_package = "com.google.firestore.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1"; +option ruby_package = "Google::Cloud::Firestore::V1"; // A Firestore document. // diff --git a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/firestore.proto b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/firestore.proto index 5f9b6d732..ee32c410c 100644 --- a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/firestore.proto +++ b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/firestore.proto @@ -34,6 +34,7 @@ option java_outer_classname = "FirestoreProto"; option java_package = "com.google.firestore.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1"; +option ruby_package = "Google::Cloud::Firestore::V1"; // Specification of the Firestore API. @@ -132,6 +133,20 @@ service Firestore { }; } + // Partitions a query by returning partition cursors that can be used to run + // the query in parallel. The returned partition cursors are split points that + // can be used by RunQuery as starting/end points for the query results. + rpc PartitionQuery(PartitionQueryRequest) returns (PartitionQueryResponse) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/databases/*/documents}:partitionQuery" + body: "*" + additional_bindings { + post: "/v1/{parent=projects/*/databases/*/documents/*/**}:partitionQuery" + body: "*" + } + }; + } + // Streams batches of document updates and deletes, in order. rpc Write(stream WriteRequest) returns (stream WriteResponse) { option (google.api.http) = { @@ -161,6 +176,22 @@ service Firestore { option (google.api.method_signature) = "parent"; } + // Applies a batch of write operations. + // + // The BatchWrite method does not apply the write operations atomically + // and can apply them out of order. Method does not allow more than one write + // per document. Each write succeeds or fails independently. See the + // [BatchWriteResponse][google.firestore.v1.BatchWriteResponse] for the success status of each write. + // + // If you require an atomically applied set of writes, use + // [Commit][google.firestore.v1.Firestore.Commit] instead. + rpc BatchWrite(BatchWriteRequest) returns (BatchWriteResponse) { + option (google.api.http) = { + post: "/v1/{database=projects/*/databases/*}/documents:batchWrite" + body: "*" + }; + } + // Creates a new document. rpc CreateDocument(CreateDocumentRequest) returns (Document) { option (google.api.http) = { @@ -189,7 +220,7 @@ message GetDocumentRequest { bytes transaction = 3; // Reads the version of the document at the given time. - // This may not be older than 60 seconds. + // This may not be older than 270 seconds. google.protobuf.Timestamp read_time = 5; } } @@ -230,7 +261,7 @@ message ListDocumentsRequest { bytes transaction = 8; // Reads documents as they were at the given time. - // This may not be older than 60 seconds. + // This may not be older than 270 seconds. google.protobuf.Timestamp read_time = 10; } @@ -346,7 +377,7 @@ message BatchGetDocumentsRequest { TransactionOptions new_transaction = 5; // Reads documents as they were at the given time. - // This may not be older than 60 seconds. + // This may not be older than 270 seconds. google.protobuf.Timestamp read_time = 7; } } @@ -460,7 +491,7 @@ message RunQueryRequest { TransactionOptions new_transaction = 6; // Reads documents as they were at the given time. - // This may not be older than 60 seconds. + // This may not be older than 270 seconds. google.protobuf.Timestamp read_time = 7; } } @@ -491,6 +522,81 @@ message RunQueryResponse { int32 skipped_results = 4; } +// The request for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery]. +message PartitionQueryRequest { + // Required. The parent resource name. In the format: + // `projects/{project_id}/databases/{database_id}/documents`. + // Document resource names are not supported; only database resource names + // can be specified. + string parent = 1 [(google.api.field_behavior) = REQUIRED]; + + // The query to partition. + oneof query_type { + // A structured query. + // Filters, order bys, limits, offsets, and start/end cursors are not + // supported. + StructuredQuery structured_query = 2; + } + + // The desired maximum number of partition points. + // The partitions may be returned across multiple pages of results. + // The number must be strictly positive. The actual number of partitions + // returned may be fewer. + // + // For example, this may be set to one fewer than the number of parallel + // queries to be run, or in running a data pipeline job, one fewer than the + // number of workers or compute instances available. + int64 partition_count = 3; + + // The `next_page_token` value returned from a previous call to + // PartitionQuery that may be used to get an additional set of results. + // There are no ordering guarantees between sets of results. Thus, using + // multiple sets of results will require merging the different result sets. + // + // For example, two subsequent calls using a page_token may return: + // + // * cursor B, cursor M, cursor Q + // * cursor A, cursor U, cursor W + // + // To obtain a complete result set ordered with respect to the results of the + // query supplied to PartitionQuery, the results sets should be merged: + // cursor A, cursor B, cursor M, cursor Q, cursor U, cursor W + string page_token = 4; + + // The maximum number of partitions to return in this call, subject to + // `partition_count`. + // + // For example, if `partition_count` = 10 and `page_size` = 8, the first call + // to PartitionQuery will return up to 8 partitions and a `next_page_token` + // if more results exist. A second call to PartitionQuery will return up to + // 2 partitions, to complete the total of 10 specified in `partition_count`. + int32 page_size = 5; +} + +// The response for [Firestore.PartitionQuery][google.firestore.v1.Firestore.PartitionQuery]. +message PartitionQueryResponse { + // Partition results. + // Each partition is a split point that can be used by RunQuery as a starting + // or end point for the query results. The RunQuery requests must be made with + // the same query supplied to this PartitionQuery request. The partition + // cursors will be ordered according to same ordering as the results of the + // query supplied to PartitionQuery. + // + // For example, if a PartitionQuery request returns partition cursors A and B, + // running the following three queries will return the entire result set of + // the original query: + // + // * query, end_at A + // * query, start_at A, end_at B + // * query, start_at B + repeated Cursor partitions = 1; + + // A page token that may be used to request an additional set of results, up + // to the number specified by `partition_count` in the PartitionQuery request. + // If blank, there are no more results. + string next_page_token = 2; +} + // The request for [Firestore.Write][google.firestore.v1.Firestore.Write]. // // The first request creates a stream, or resumes an existing one from a token. @@ -756,3 +862,35 @@ message ListCollectionIdsResponse { // A page token that may be used to continue the list. string next_page_token = 2; } + +// The request for [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite]. +message BatchWriteRequest { + // Required. The database name. In the format: + // `projects/{project_id}/databases/{database_id}`. + string database = 1 [(google.api.field_behavior) = REQUIRED]; + + // The writes to apply. + // + // Method does not apply writes atomically and does not guarantee ordering. + // Each write succeeds or fails independently. You cannot write to the same + // document more than once per request. + repeated Write writes = 2; + + // Labels associated with this batch write. + map labels = 3; +} + +// The response from [Firestore.BatchWrite][google.firestore.v1.Firestore.BatchWrite]. +message BatchWriteResponse { + // The result of applying the writes. + // + // This i-th write result corresponds to the i-th write in the + // request. + repeated WriteResult write_results = 1; + + // The status of applying the writes. + // + // This i-th write status corresponds to the i-th write in the + // request. + repeated google.rpc.Status status = 2; +} diff --git a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/query.proto b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/query.proto index 226d32418..9c267fe68 100644 --- a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/query.proto +++ b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/query.proto @@ -27,6 +27,7 @@ option java_outer_classname = "QueryProto"; option java_package = "com.google.firestore.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1"; +option ruby_package = "Google::Cloud::Firestore::V1"; // A Firestore query. message StructuredQuery { @@ -83,31 +84,55 @@ message StructuredQuery { // Unspecified. This value must not be used. OPERATOR_UNSPECIFIED = 0; - // Less than. Requires that the field come first in `order_by`. + // The given `field` is less than the given `value`. + // + // Requires: + // + // * That `field` come first in `order_by`. LESS_THAN = 1; - // Less than or equal. Requires that the field come first in `order_by`. + // The given `field` is less than or equal to the given `value`. + // + // Requires: + // + // * That `field` come first in `order_by`. LESS_THAN_OR_EQUAL = 2; - // Greater than. Requires that the field come first in `order_by`. + // The given `field` is greater than the given `value`. + // + // Requires: + // + // * That `field` come first in `order_by`. GREATER_THAN = 3; - // Greater than or equal. Requires that the field come first in - // `order_by`. + // The given `field` is greater than or equal to the given `value`. + // + // Requires: + // + // * That `field` come first in `order_by`. GREATER_THAN_OR_EQUAL = 4; - // Equal. + // The given `field` is equal to the given `value`. EQUAL = 5; - // Contains. Requires that the field is an array. + // The given `field` is an array that contains the given `value`. ARRAY_CONTAINS = 7; - // In. Requires that `value` is a non-empty ArrayValue with at most 10 - // values. + // The given `field` is equal to at least one value in the given array. + // + // Requires: + // + // * That `value` is a non-empty `ArrayValue` with at most 10 values. + // * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`. IN = 8; - // Contains any. Requires that the field is an array and - // `value` is a non-empty ArrayValue with at most 10 values. + // The given `field` is an array that contains any of the values in the + // given array. + // + // Requires: + // + // * That `value` is a non-empty `ArrayValue` with at most 10 values. + // * No other `IN`, `ARRAY_CONTAINS_ANY`, or `NOT_IN`. ARRAY_CONTAINS_ANY = 9; } @@ -121,15 +146,6 @@ message StructuredQuery { Value value = 3; } - // The projection of document's fields to return. - message Projection { - // The fields to return. - // - // If empty, all fields are returned. To only return the name - // of the document, use `['__name__']`. - repeated FieldReference fields = 2; - } - // A filter with a single operand. message UnaryFilter { // A unary operator. @@ -137,10 +153,10 @@ message StructuredQuery { // Unspecified. This value must not be used. OPERATOR_UNSPECIFIED = 0; - // Test if a field is equal to NaN. + // The given `field` is equal to `NaN`. IS_NAN = 2; - // Test if an expression evaluates to Null. + // The given `field` is equal to `NULL`. IS_NULL = 3; } @@ -159,6 +175,15 @@ message StructuredQuery { string field_path = 2; } + // The projection of document's fields to return. + message Projection { + // The fields to return. + // + // If empty, all fields are returned. To only return the name + // of the document, use `['__name__']`. + repeated FieldReference fields = 2; + } + // An order on a field. message Order { // The field to order by. diff --git a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/write.proto b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/write.proto index 403c80f81..a6befb0e6 100644 --- a/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/write.proto +++ b/proto-google-cloud-firestore-v1/src/main/proto/google/firestore/v1/write.proto @@ -28,6 +28,7 @@ option java_outer_classname = "WriteProto"; option java_package = "com.google.firestore.v1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1"; +option ruby_package = "Google::Cloud::Firestore::V1"; // A write on a document. message Write { diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ArrayValue.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ArrayValue.java index 25a6db420..753ddff2f 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ArrayValue.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ArrayValue.java @@ -130,6 +130,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesList() { return values_; } @@ -142,6 +143,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesOrBuilderList() { return values_; @@ -155,6 +157,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public int getValuesCount() { return values_.size(); } @@ -167,6 +170,7 @@ public int getValuesCount() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getValues(int index) { return values_.get(index); } @@ -179,6 +183,7 @@ public com.google.firestore.v1beta1.Value getValues(int index) { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getValuesOrBuilder(int index) { return values_.get(index); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsRequest.java index 3c64d1eec..baf849e80 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsRequest.java @@ -246,6 +246,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -269,6 +270,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -369,6 +371,7 @@ public com.google.protobuf.ByteString getDocumentsBytes(int index) { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -385,6 +388,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() : mask_; } @@ -399,6 +403,7 @@ public com.google.firestore.v1beta1.DocumentMask getMask() { * * .google.firestore.v1beta1.DocumentMask mask = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -415,6 +420,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 4) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -437,6 +443,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 5; } @@ -454,6 +461,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { if (consistencySelectorCase_ == 5) { return (com.google.firestore.v1beta1.TransactionOptions) consistencySelector_; @@ -472,6 +480,7 @@ public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { * * .google.firestore.v1beta1.TransactionOptions new_transaction = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if (consistencySelectorCase_ == 5) { return (com.google.firestore.v1beta1.TransactionOptions) consistencySelector_; @@ -492,6 +501,7 @@ public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactio * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -507,6 +517,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -523,6 +534,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1609,6 +1621,7 @@ public Builder clearTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 5; } @@ -1626,6 +1639,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { if (newTransactionBuilder_ == null) { if (consistencySelectorCase_ == 5) { @@ -1777,6 +1791,7 @@ public com.google.firestore.v1beta1.TransactionOptions.Builder getNewTransaction * * .google.firestore.v1beta1.TransactionOptions new_transaction = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if ((consistencySelectorCase_ == 5) && (newTransactionBuilder_ != null)) { return newTransactionBuilder_.getMessageOrBuilder(); @@ -1842,6 +1857,7 @@ public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactio * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -1857,6 +1873,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 7) { @@ -1994,6 +2011,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 7) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsResponse.java index 72459005a..69becdaad 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BatchGetDocumentsResponse.java @@ -206,6 +206,7 @@ public ResultCase getResultCase() { * * @return Whether the found field is set. */ + @java.lang.Override public boolean hasFound() { return resultCase_ == 1; } @@ -220,6 +221,7 @@ public boolean hasFound() { * * @return The found. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getFound() { if (resultCase_ == 1) { return (com.google.firestore.v1beta1.Document) result_; @@ -235,6 +237,7 @@ public com.google.firestore.v1beta1.Document getFound() { * * .google.firestore.v1beta1.Document found = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getFoundOrBuilder() { if (resultCase_ == 1) { return (com.google.firestore.v1beta1.Document) result_; @@ -315,6 +318,7 @@ public com.google.protobuf.ByteString getMissingBytes() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -335,6 +339,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -352,6 +357,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -367,6 +373,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -815,6 +822,7 @@ public Builder clearResult() { * * @return Whether the found field is set. */ + @java.lang.Override public boolean hasFound() { return resultCase_ == 1; } @@ -829,6 +837,7 @@ public boolean hasFound() { * * @return The found. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getFound() { if (foundBuilder_ == null) { if (resultCase_ == 1) { @@ -960,6 +969,7 @@ public com.google.firestore.v1beta1.Document.Builder getFoundBuilder() { * * .google.firestore.v1beta1.Document found = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getFoundOrBuilder() { if ((resultCase_ == 1) && (foundBuilder_ != null)) { return foundBuilder_.getMessageOrBuilder(); @@ -1014,6 +1024,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getFoundOrBuilder() { * * @return The missing. */ + @java.lang.Override public java.lang.String getMissing() { java.lang.Object ref = ""; if (resultCase_ == 2) { @@ -1042,6 +1053,7 @@ public java.lang.String getMissing() { * * @return The bytes for missing. */ + @java.lang.Override public com.google.protobuf.ByteString getMissingBytes() { java.lang.Object ref = ""; if (resultCase_ == 2) { @@ -1138,6 +1150,7 @@ public Builder setMissingBytes(com.google.protobuf.ByteString value) { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionRequest.java index 2c59a07c1..c70efb1f4 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionRequest.java @@ -141,6 +141,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -164,6 +165,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return Whether the options field is set. */ + @java.lang.Override public boolean hasOptions() { return options_ != null; } @@ -205,6 +208,7 @@ public boolean hasOptions() { * * @return The options. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions getOptions() { return options_ == null ? com.google.firestore.v1beta1.TransactionOptions.getDefaultInstance() @@ -220,6 +224,7 @@ public com.google.firestore.v1beta1.TransactionOptions getOptions() { * * .google.firestore.v1beta1.TransactionOptions options = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getOptionsOrBuilder() { return getOptions(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionResponse.java index 47022a25b..0dbff539e 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/BeginTransactionResponse.java @@ -122,6 +122,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -456,6 +457,7 @@ public Builder mergeFrom( * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitRequest.java index dfcefbff1..76b4d3a6d 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitRequest.java @@ -147,6 +147,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -170,6 +171,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -194,6 +196,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * repeated .google.firestore.v1beta1.Write writes = 2; */ + @java.lang.Override public java.util.List getWritesList() { return writes_; } @@ -207,6 +210,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1beta1.Write writes = 2; */ + @java.lang.Override public java.util.List getWritesOrBuilderList() { return writes_; @@ -221,6 +225,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1beta1.Write writes = 2; */ + @java.lang.Override public int getWritesCount() { return writes_.size(); } @@ -234,6 +239,7 @@ public int getWritesCount() { * * repeated .google.firestore.v1beta1.Write writes = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Write getWrites(int index) { return writes_.get(index); } @@ -247,6 +253,7 @@ public com.google.firestore.v1beta1.Write getWrites(int index) { * * repeated .google.firestore.v1beta1.Write writes = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteOrBuilder getWritesOrBuilder(int index) { return writes_.get(index); } @@ -264,6 +271,7 @@ public com.google.firestore.v1beta1.WriteOrBuilder getWritesOrBuilder(int index) * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -1146,6 +1154,7 @@ public java.util.List getWritesBuild * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitResponse.java index a52993835..9a8046301 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommitResponse.java @@ -147,6 +147,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.WriteResult write_results = 1; */ + @java.lang.Override public java.util.List getWriteResultsList() { return writeResults_; } @@ -161,6 +162,7 @@ public java.util.List getWriteResultsL * * repeated .google.firestore.v1beta1.WriteResult write_results = 1; */ + @java.lang.Override public java.util.List getWriteResultsOrBuilderList() { return writeResults_; @@ -176,6 +178,7 @@ public java.util.List getWriteResultsL * * repeated .google.firestore.v1beta1.WriteResult write_results = 1; */ + @java.lang.Override public int getWriteResultsCount() { return writeResults_.size(); } @@ -190,6 +193,7 @@ public int getWriteResultsCount() { * * repeated .google.firestore.v1beta1.WriteResult write_results = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteResult getWriteResults(int index) { return writeResults_.get(index); } @@ -204,6 +208,7 @@ public com.google.firestore.v1beta1.WriteResult getWriteResults(int index) { * * repeated .google.firestore.v1beta1.WriteResult write_results = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { return writeResults_.get(index); } @@ -221,6 +226,7 @@ public com.google.firestore.v1beta1.WriteResultOrBuilder getWriteResultsOrBuilde * * @return Whether the commitTime field is set. */ + @java.lang.Override public boolean hasCommitTime() { return commitTime_ != null; } @@ -235,6 +241,7 @@ public boolean hasCommitTime() { * * @return The commitTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCommitTime() { return commitTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : commitTime_; } @@ -247,6 +254,7 @@ public com.google.protobuf.Timestamp getCommitTime() { * * .google.protobuf.Timestamp commit_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCommitTimeOrBuilder() { return getCommitTime(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommonProto.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommonProto.java index e2314b9ce..2924408d4 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommonProto.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CommonProto.java @@ -70,12 +70,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "iteH\000\032&\n\tReadWrite\022\031\n\021retry_transaction\030" + "\001 \001(\014\032S\n\010ReadOnly\022/\n\tread_time\030\002 \001(\0132\032.g" + "oogle.protobuf.TimestampH\000B\026\n\024consistenc" - + "y_selectorB\006\n\004modeB\271\001\n\034com.google.firest" + + "y_selectorB\006\n\004modeB\335\001\n\034com.google.firest" + "ore.v1beta1B\013CommonProtoP\001ZAgoogle.golan" + "g.org/genproto/googleapis/firestore/v1be" + "ta1;firestore\242\002\004GCFS\252\002\036Google.Cloud.Fire" + "store.V1Beta1\312\002\036Google\\Cloud\\Firestore\\V" - + "1beta1b\006proto3" + + "1beta1\352\002!Google::Cloud::Firestore::V1bet" + + "a1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CreateDocumentRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CreateDocumentRequest.java index be727d29c..154c9bc44 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CreateDocumentRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/CreateDocumentRequest.java @@ -174,6 +174,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -198,6 +199,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -223,6 +225,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The collectionId. */ + @java.lang.Override public java.lang.String getCollectionId() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -245,6 +248,7 @@ public java.lang.String getCollectionId() { * * @return The bytes for collectionId. */ + @java.lang.Override public com.google.protobuf.ByteString getCollectionIdBytes() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -271,6 +275,7 @@ public com.google.protobuf.ByteString getCollectionIdBytes() { * * @return The documentId. */ + @java.lang.Override public java.lang.String getDocumentId() { java.lang.Object ref = documentId_; if (ref instanceof java.lang.String) { @@ -294,6 +299,7 @@ public java.lang.String getDocumentId() { * * @return The bytes for documentId. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentIdBytes() { java.lang.Object ref = documentId_; if (ref instanceof java.lang.String) { @@ -321,6 +327,7 @@ public com.google.protobuf.ByteString getDocumentIdBytes() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -337,6 +344,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getDocument() { return document_ == null ? com.google.firestore.v1beta1.Document.getDefaultInstance() @@ -353,6 +361,7 @@ public com.google.firestore.v1beta1.Document getDocument() { * .google.firestore.v1beta1.Document document = 4 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -372,6 +381,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -388,6 +398,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() : mask_; } @@ -402,6 +413,7 @@ public com.google.firestore.v1beta1.DocumentMask getMask() { * * .google.firestore.v1beta1.DocumentMask mask = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Cursor.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Cursor.java index 7e51ee6a7..4c7f9e5b7 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Cursor.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Cursor.java @@ -137,6 +137,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesList() { return values_; } @@ -151,6 +152,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public java.util.List getValuesOrBuilderList() { return values_; @@ -166,6 +168,7 @@ public java.util.List getValuesList() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public int getValuesCount() { return values_.size(); } @@ -180,6 +183,7 @@ public int getValuesCount() { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getValues(int index) { return values_.get(index); } @@ -194,6 +198,7 @@ public com.google.firestore.v1beta1.Value getValues(int index) { * * repeated .google.firestore.v1beta1.Value values = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getValuesOrBuilder(int index) { return values_.get(index); } @@ -212,6 +217,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getValuesOrBuilder(int index) * * @return The before. */ + @java.lang.Override public boolean getBefore() { return before_; } @@ -983,6 +989,7 @@ public java.util.List getValuesBuild * * @return The before. */ + @java.lang.Override public boolean getBefore() { return before_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DeleteDocumentRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DeleteDocumentRequest.java index 32ccba2ac..ef5b3f452 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DeleteDocumentRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DeleteDocumentRequest.java @@ -141,6 +141,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -164,6 +165,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -205,6 +208,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1beta1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1beta1.Precondition.getDefaultInstance() @@ -220,6 +224,7 @@ public com.google.firestore.v1beta1.Precondition getCurrentDocument() { * * .google.firestore.v1beta1.Precondition current_document = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Document.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Document.java index 2b09f0048..f922e3e8d 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Document.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Document.java @@ -183,6 +183,7 @@ protected com.google.protobuf.MapField internalGetMapField(int number) { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -206,6 +207,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -274,6 +276,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -281,6 +284,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -312,6 +316,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -342,6 +347,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1beta1.Value defaultValue) { if (key == null) { @@ -378,6 +384,7 @@ public com.google.firestore.v1beta1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -406,6 +413,7 @@ public com.google.firestore.v1beta1.Value getFieldsOrThrow(java.lang.String key) * * @return Whether the createTime field is set. */ + @java.lang.Override public boolean hasCreateTime() { return createTime_ != null; } @@ -423,6 +431,7 @@ public boolean hasCreateTime() { * * @return The createTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } @@ -438,6 +447,7 @@ public com.google.protobuf.Timestamp getCreateTime() { * * .google.protobuf.Timestamp create_time = 3; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return getCreateTime(); } @@ -458,6 +468,7 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return updateTime_ != null; } @@ -475,6 +486,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } @@ -490,6 +502,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return getUpdateTime(); } @@ -1074,6 +1087,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1081,6 +1095,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -1112,6 +1127,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -1142,6 +1158,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1beta1.Value defaultValue) { if (key == null) { @@ -1178,6 +1195,7 @@ public com.google.firestore.v1beta1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1beta1.Value> fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentChange.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentChange.java index 092ea91d4..072ec2a11 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentChange.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentChange.java @@ -192,6 +192,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -207,6 +208,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getDocument() { return document_ == null ? com.google.firestore.v1beta1.Document.getDefaultInstance() @@ -222,6 +224,7 @@ public com.google.firestore.v1beta1.Document getDocument() { * * .google.firestore.v1beta1.Document document = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -239,6 +242,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { * * @return A list containing the targetIds. */ + @java.lang.Override public java.util.List getTargetIdsList() { return targetIds_; } @@ -287,6 +291,7 @@ public int getTargetIds(int index) { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentDelete.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentDelete.java index ead5773cf..443dd3600 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentDelete.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentDelete.java @@ -171,6 +171,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -193,6 +194,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -218,6 +220,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } @@ -267,6 +270,7 @@ public int getRemovedTargetIds(int index) { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -282,6 +286,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -295,6 +300,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentProto.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentProto.java index c2ff12a59..fcf2ea862 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentProto.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentProto.java @@ -87,12 +87,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "e\"\232\001\n\010MapValue\022>\n\006fields\030\001 \003(\0132..google." + "firestore.v1beta1.MapValue.FieldsEntry\032N" + "\n\013FieldsEntry\022\013\n\003key\030\001 \001(\t\022.\n\005value\030\002 \001(" - + "\0132\037.google.firestore.v1beta1.Value:\0028\001B\273" + + "\0132\037.google.firestore.v1beta1.Value:\0028\001B\337" + "\001\n\034com.google.firestore.v1beta1B\rDocumen" + "tProtoP\001ZAgoogle.golang.org/genproto/goo" + "gleapis/firestore/v1beta1;firestore\242\002\004GC" + "FS\252\002\036Google.Cloud.Firestore.V1Beta1\312\002\036Go" - + "ogle\\Cloud\\Firestore\\V1beta1b\006proto3" + + "ogle\\Cloud\\Firestore\\V1beta1\352\002!Google::C" + + "loud::Firestore::V1beta1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentRemove.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentRemove.java index e1651ba1d..ec498b973 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentRemove.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentRemove.java @@ -172,6 +172,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -194,6 +195,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -219,6 +221,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * * @return A list containing the removedTargetIds. */ + @java.lang.Override public java.util.List getRemovedTargetIdsList() { return removedTargetIds_; } @@ -268,6 +271,7 @@ public int getRemovedTargetIds(int index) { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -283,6 +287,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -296,6 +301,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentTransform.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentTransform.java index f4467a30a..27b7fd1cb 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentTransform.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/DocumentTransform.java @@ -784,6 +784,10 @@ public ServerValue findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -891,6 +895,7 @@ public TransformTypeCase getTransformTypeCase() { * * @return The fieldPath. */ + @java.lang.Override public java.lang.String getFieldPath() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -914,6 +919,7 @@ public java.lang.String getFieldPath() { * * @return The bytes for fieldPath. */ + @java.lang.Override public com.google.protobuf.ByteString getFieldPathBytes() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -994,6 +1000,7 @@ public int getSetToServerValueValue() { * * @return Whether the increment field is set. */ + @java.lang.Override public boolean hasIncrement() { return transformTypeCase_ == 3; } @@ -1016,6 +1023,7 @@ public boolean hasIncrement() { * * @return The increment. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getIncrement() { if (transformTypeCase_ == 3) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1039,6 +1047,7 @@ public com.google.firestore.v1beta1.Value getIncrement() { * * .google.firestore.v1beta1.Value increment = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getIncrementOrBuilder() { if (transformTypeCase_ == 3) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1068,6 +1077,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getIncrementOrBuilder() { * * @return Whether the maximum field is set. */ + @java.lang.Override public boolean hasMaximum() { return transformTypeCase_ == 4; } @@ -1092,6 +1102,7 @@ public boolean hasMaximum() { * * @return The maximum. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getMaximum() { if (transformTypeCase_ == 4) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1117,6 +1128,7 @@ public com.google.firestore.v1beta1.Value getMaximum() { * * .google.firestore.v1beta1.Value maximum = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getMaximumOrBuilder() { if (transformTypeCase_ == 4) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1146,6 +1158,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getMaximumOrBuilder() { * * @return Whether the minimum field is set. */ + @java.lang.Override public boolean hasMinimum() { return transformTypeCase_ == 5; } @@ -1170,6 +1183,7 @@ public boolean hasMinimum() { * * @return The minimum. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getMinimum() { if (transformTypeCase_ == 5) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1195,6 +1209,7 @@ public com.google.firestore.v1beta1.Value getMinimum() { * * .google.firestore.v1beta1.Value minimum = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getMinimumOrBuilder() { if (transformTypeCase_ == 5) { return (com.google.firestore.v1beta1.Value) transformType_; @@ -1223,6 +1238,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getMinimumOrBuilder() { * * @return Whether the appendMissingElements field is set. */ + @java.lang.Override public boolean hasAppendMissingElements() { return transformTypeCase_ == 6; } @@ -1246,6 +1262,7 @@ public boolean hasAppendMissingElements() { * * @return The appendMissingElements. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getAppendMissingElements() { if (transformTypeCase_ == 6) { return (com.google.firestore.v1beta1.ArrayValue) transformType_; @@ -1270,6 +1287,7 @@ public com.google.firestore.v1beta1.ArrayValue getAppendMissingElements() { * * .google.firestore.v1beta1.ArrayValue append_missing_elements = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getAppendMissingElementsOrBuilder() { if (transformTypeCase_ == 6) { return (com.google.firestore.v1beta1.ArrayValue) transformType_; @@ -1296,6 +1314,7 @@ public com.google.firestore.v1beta1.ArrayValueOrBuilder getAppendMissingElements * * @return Whether the removeAllFromArray field is set. */ + @java.lang.Override public boolean hasRemoveAllFromArray() { return transformTypeCase_ == 7; } @@ -1317,6 +1336,7 @@ public boolean hasRemoveAllFromArray() { * * @return The removeAllFromArray. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getRemoveAllFromArray() { if (transformTypeCase_ == 7) { return (com.google.firestore.v1beta1.ArrayValue) transformType_; @@ -1339,6 +1359,7 @@ public com.google.firestore.v1beta1.ArrayValue getRemoveAllFromArray() { * * .google.firestore.v1beta1.ArrayValue remove_all_from_array = 7; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getRemoveAllFromArrayOrBuilder() { if (transformTypeCase_ == 7) { return (com.google.firestore.v1beta1.ArrayValue) transformType_; @@ -1987,6 +2008,7 @@ public Builder setFieldPathBytes(com.google.protobuf.ByteString value) { * * @return The enum numeric value on the wire for setToServerValue. */ + @java.lang.Override public int getSetToServerValueValue() { if (transformTypeCase_ == 2) { return ((java.lang.Integer) transformType_).intValue(); @@ -2026,6 +2048,7 @@ public Builder setSetToServerValueValue(int value) { * * @return The setToServerValue. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransform.FieldTransform.ServerValue getSetToServerValue() { if (transformTypeCase_ == 2) { @@ -2111,6 +2134,7 @@ public Builder clearSetToServerValue() { * * @return Whether the increment field is set. */ + @java.lang.Override public boolean hasIncrement() { return transformTypeCase_ == 3; } @@ -2133,6 +2157,7 @@ public boolean hasIncrement() { * * @return The increment. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getIncrement() { if (incrementBuilder_ == null) { if (transformTypeCase_ == 3) { @@ -2312,6 +2337,7 @@ public com.google.firestore.v1beta1.Value.Builder getIncrementBuilder() { * * .google.firestore.v1beta1.Value increment = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getIncrementOrBuilder() { if ((transformTypeCase_ == 3) && (incrementBuilder_ != null)) { return incrementBuilder_.getMessageOrBuilder(); @@ -2390,6 +2416,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getIncrementOrBuilder() { * * @return Whether the maximum field is set. */ + @java.lang.Override public boolean hasMaximum() { return transformTypeCase_ == 4; } @@ -2414,6 +2441,7 @@ public boolean hasMaximum() { * * @return The maximum. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getMaximum() { if (maximumBuilder_ == null) { if (transformTypeCase_ == 4) { @@ -2605,6 +2633,7 @@ public com.google.firestore.v1beta1.Value.Builder getMaximumBuilder() { * * .google.firestore.v1beta1.Value maximum = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getMaximumOrBuilder() { if ((transformTypeCase_ == 4) && (maximumBuilder_ != null)) { return maximumBuilder_.getMessageOrBuilder(); @@ -2685,6 +2714,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getMaximumOrBuilder() { * * @return Whether the minimum field is set. */ + @java.lang.Override public boolean hasMinimum() { return transformTypeCase_ == 5; } @@ -2709,6 +2739,7 @@ public boolean hasMinimum() { * * @return The minimum. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getMinimum() { if (minimumBuilder_ == null) { if (transformTypeCase_ == 5) { @@ -2900,6 +2931,7 @@ public com.google.firestore.v1beta1.Value.Builder getMinimumBuilder() { * * .google.firestore.v1beta1.Value minimum = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getMinimumOrBuilder() { if ((transformTypeCase_ == 5) && (minimumBuilder_ != null)) { return minimumBuilder_.getMessageOrBuilder(); @@ -2979,6 +3011,7 @@ public com.google.firestore.v1beta1.ValueOrBuilder getMinimumOrBuilder() { * * @return Whether the appendMissingElements field is set. */ + @java.lang.Override public boolean hasAppendMissingElements() { return transformTypeCase_ == 6; } @@ -3002,6 +3035,7 @@ public boolean hasAppendMissingElements() { * * @return The appendMissingElements. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getAppendMissingElements() { if (appendMissingElementsBuilder_ == null) { if (transformTypeCase_ == 6) { @@ -3188,6 +3222,7 @@ public com.google.firestore.v1beta1.ArrayValue.Builder getAppendMissingElementsB * * .google.firestore.v1beta1.ArrayValue append_missing_elements = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getAppendMissingElementsOrBuilder() { if ((transformTypeCase_ == 6) && (appendMissingElementsBuilder_ != null)) { return appendMissingElementsBuilder_.getMessageOrBuilder(); @@ -3264,6 +3299,7 @@ public com.google.firestore.v1beta1.ArrayValueOrBuilder getAppendMissingElements * * @return Whether the removeAllFromArray field is set. */ + @java.lang.Override public boolean hasRemoveAllFromArray() { return transformTypeCase_ == 7; } @@ -3285,6 +3321,7 @@ public boolean hasRemoveAllFromArray() { * * @return The removeAllFromArray. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getRemoveAllFromArray() { if (removeAllFromArrayBuilder_ == null) { if (transformTypeCase_ == 7) { @@ -3459,6 +3496,7 @@ public com.google.firestore.v1beta1.ArrayValue.Builder getRemoveAllFromArrayBuil * * .google.firestore.v1beta1.ArrayValue remove_all_from_array = 7; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getRemoveAllFromArrayOrBuilder() { if ((transformTypeCase_ == 7) && (removeAllFromArrayBuilder_ != null)) { return removeAllFromArrayBuilder_.getMessageOrBuilder(); @@ -3578,6 +3616,7 @@ public com.google.protobuf.Parser getParserForType() { * * @return The document. */ + @java.lang.Override public java.lang.String getDocument() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -3600,6 +3639,7 @@ public java.lang.String getDocument() { * * @return The bytes for document. */ + @java.lang.Override public com.google.protobuf.ByteString getDocumentBytes() { java.lang.Object ref = document_; if (ref instanceof java.lang.String) { @@ -3627,6 +3667,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1beta1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public java.util.List getFieldTransformsList() { return fieldTransforms_; @@ -3643,6 +3684,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1beta1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public java.util.List< ? extends com.google.firestore.v1beta1.DocumentTransform.FieldTransformOrBuilder> getFieldTransformsOrBuilderList() { @@ -3660,6 +3702,7 @@ public com.google.protobuf.ByteString getDocumentBytes() { * repeated .google.firestore.v1beta1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public int getFieldTransformsCount() { return fieldTransforms_.size(); } @@ -3675,6 +3718,7 @@ public int getFieldTransformsCount() { * repeated .google.firestore.v1beta1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransform.FieldTransform getFieldTransforms( int index) { return fieldTransforms_.get(index); @@ -3691,6 +3735,7 @@ public com.google.firestore.v1beta1.DocumentTransform.FieldTransform getFieldTra * repeated .google.firestore.v1beta1.DocumentTransform.FieldTransform field_transforms = 2; * */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransform.FieldTransformOrBuilder getFieldTransformsOrBuilder(int index) { return fieldTransforms_.get(index); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ExistenceFilter.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ExistenceFilter.java index 3b509b13a..93b532597 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ExistenceFilter.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ExistenceFilter.java @@ -125,6 +125,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -144,6 +145,7 @@ public int getTargetId() { * * @return The count. */ + @java.lang.Override public int getCount() { return count_; } @@ -490,6 +492,7 @@ public Builder mergeFrom( * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -543,6 +546,7 @@ public Builder clearTargetId() { * * @return The count. */ + @java.lang.Override public int getCount() { return count_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/FirestoreProto.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/FirestoreProto.java index 88ffeaaad..1a30dd228 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/FirestoreProto.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/FirestoreProto.java @@ -335,12 +335,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ds:\001*\332A\006parent\032v\312A\030firestore.googleapis." + "com\322AXhttps://www.googleapis.com/auth/cl" + "oud-platform,https://www.googleapis.com/" - + "auth/datastoreB\274\001\n\034com.google.firestore." + + "auth/datastoreB\340\001\n\034com.google.firestore." + "v1beta1B\016FirestoreProtoP\001ZAgoogle.golang" + ".org/genproto/googleapis/firestore/v1bet" + "a1;firestore\242\002\004GCFS\252\002\036Google.Cloud.Fires" + "tore.V1Beta1\312\002\036Google\\Cloud\\Firestore\\V1" - + "beta1b\006proto3" + + "beta1\352\002!Google::Cloud::Firestore::V1beta" + + "1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/GetDocumentRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/GetDocumentRequest.java index 6a8bfa342..8f4124a53 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/GetDocumentRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/GetDocumentRequest.java @@ -209,6 +209,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The name. */ + @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -232,6 +233,7 @@ public java.lang.String getName() { * * @return The bytes for name. */ + @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { @@ -259,6 +261,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -275,6 +278,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() : mask_; } @@ -289,6 +293,7 @@ public com.google.firestore.v1beta1.DocumentMask getMask() { * * .google.firestore.v1beta1.DocumentMask mask = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -305,6 +310,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 3) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -325,6 +331,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 5; } @@ -340,6 +347,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -356,6 +364,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 5; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1179,6 +1188,7 @@ public Builder clearTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 5; } @@ -1194,6 +1204,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 5) { @@ -1331,6 +1342,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 5; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 5) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsRequest.java index 7331f9e9b..b5d0328a0 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsRequest.java @@ -140,6 +140,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -165,6 +166,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -190,6 +192,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -208,6 +211,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -231,6 +235,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -726,6 +731,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsResponse.java index 013812d92..05ce157e5 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListCollectionIdsResponse.java @@ -200,6 +200,7 @@ public com.google.protobuf.ByteString getCollectionIdsBytes(int index) { * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -222,6 +223,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsRequest.java index fc2136f84..beea3cf19 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsRequest.java @@ -247,6 +247,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -274,6 +275,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -300,6 +302,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return The collectionId. */ + @java.lang.Override public java.lang.String getCollectionId() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -323,6 +326,7 @@ public java.lang.String getCollectionId() { * * @return The bytes for collectionId. */ + @java.lang.Override public com.google.protobuf.ByteString getCollectionIdBytes() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -348,6 +352,7 @@ public com.google.protobuf.ByteString getCollectionIdBytes() { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -365,6 +370,7 @@ public int getPageSize() { * * @return The pageToken. */ + @java.lang.Override public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -387,6 +393,7 @@ public java.lang.String getPageToken() { * * @return The bytes for pageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { @@ -412,6 +419,7 @@ public com.google.protobuf.ByteString getPageTokenBytes() { * * @return The orderBy. */ + @java.lang.Override public java.lang.String getOrderBy() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { @@ -434,6 +442,7 @@ public java.lang.String getOrderBy() { * * @return The bytes for orderBy. */ + @java.lang.Override public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { @@ -461,6 +470,7 @@ public com.google.protobuf.ByteString getOrderByBytes() { * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -477,6 +487,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() : mask_; } @@ -491,6 +502,7 @@ public com.google.firestore.v1beta1.DocumentMask getMask() { * * .google.firestore.v1beta1.DocumentMask mask = 7; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -507,6 +519,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 8) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -527,6 +540,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 10; } @@ -542,6 +556,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 10) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -558,6 +573,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 10) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -583,6 +599,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The showMissing. */ + @java.lang.Override public boolean getShowMissing() { return showMissing_; } @@ -1347,6 +1364,7 @@ public Builder setCollectionIdBytes(com.google.protobuf.ByteString value) { * * @return The pageSize. */ + @java.lang.Override public int getPageSize() { return pageSize_; } @@ -1876,6 +1894,7 @@ public Builder clearTransaction() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 10; } @@ -1891,6 +1910,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 10) { @@ -2028,6 +2048,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 10) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -2090,6 +2111,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The showMissing. */ + @java.lang.Override public boolean getShowMissing() { return showMissing_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsResponse.java index 82ceb5636..a1babc8b2 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListDocumentsResponse.java @@ -138,6 +138,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.Document documents = 1; */ + @java.lang.Override public java.util.List getDocumentsList() { return documents_; } @@ -150,6 +151,7 @@ public java.util.List getDocumentsList() * * repeated .google.firestore.v1beta1.Document documents = 1; */ + @java.lang.Override public java.util.List getDocumentsOrBuilderList() { return documents_; @@ -163,6 +165,7 @@ public java.util.List getDocumentsList() * * repeated .google.firestore.v1beta1.Document documents = 1; */ + @java.lang.Override public int getDocumentsCount() { return documents_.size(); } @@ -175,6 +178,7 @@ public int getDocumentsCount() { * * repeated .google.firestore.v1beta1.Document documents = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Document getDocuments(int index) { return documents_.get(index); } @@ -187,6 +191,7 @@ public com.google.firestore.v1beta1.Document getDocuments(int index) { * * repeated .google.firestore.v1beta1.Document documents = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentsOrBuilder(int index) { return documents_.get(index); } @@ -204,6 +209,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentsOrBuilder(int * * @return The nextPageToken. */ + @java.lang.Override public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { @@ -226,6 +232,7 @@ public java.lang.String getNextPageToken() { * * @return The bytes for nextPageToken. */ + @java.lang.Override public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenRequest.java index b32e607f8..72b2b6abf 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenRequest.java @@ -219,6 +219,7 @@ public TargetChangeCase getTargetChangeCase() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -242,6 +243,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -266,6 +268,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return Whether the addTarget field is set. */ + @java.lang.Override public boolean hasAddTarget() { return targetChangeCase_ == 2; } @@ -280,6 +283,7 @@ public boolean hasAddTarget() { * * @return The addTarget. */ + @java.lang.Override public com.google.firestore.v1beta1.Target getAddTarget() { if (targetChangeCase_ == 2) { return (com.google.firestore.v1beta1.Target) targetChange_; @@ -295,6 +299,7 @@ public com.google.firestore.v1beta1.Target getAddTarget() { * * .google.firestore.v1beta1.Target add_target = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TargetOrBuilder getAddTargetOrBuilder() { if (targetChangeCase_ == 2) { return (com.google.firestore.v1beta1.Target) targetChange_; @@ -314,6 +319,7 @@ public com.google.firestore.v1beta1.TargetOrBuilder getAddTargetOrBuilder() { * * @return The removeTarget. */ + @java.lang.Override public int getRemoveTarget() { if (targetChangeCase_ == 3) { return (java.lang.Integer) targetChange_; @@ -355,6 +361,7 @@ public int getLabelsCount() { * * map<string, string> labels = 4; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -362,6 +369,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -375,6 +383,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -387,6 +396,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); @@ -403,6 +413,7 @@ public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.Strin * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -983,6 +994,7 @@ public Builder setDatabaseBytes(com.google.protobuf.ByteString value) { * * @return Whether the addTarget field is set. */ + @java.lang.Override public boolean hasAddTarget() { return targetChangeCase_ == 2; } @@ -997,6 +1009,7 @@ public boolean hasAddTarget() { * * @return The addTarget. */ + @java.lang.Override public com.google.firestore.v1beta1.Target getAddTarget() { if (addTargetBuilder_ == null) { if (targetChangeCase_ == 2) { @@ -1128,6 +1141,7 @@ public com.google.firestore.v1beta1.Target.Builder getAddTargetBuilder() { * * .google.firestore.v1beta1.Target add_target = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TargetOrBuilder getAddTargetOrBuilder() { if ((targetChangeCase_ == 2) && (addTargetBuilder_ != null)) { return addTargetBuilder_.getMessageOrBuilder(); @@ -1261,6 +1275,7 @@ public int getLabelsCount() { * * map<string, string> labels = 4; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1268,6 +1283,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -1281,6 +1297,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -1293,6 +1310,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { @@ -1310,6 +1328,7 @@ public java.lang.String getLabelsOrDefault( * * map<string, string> labels = 4; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenResponse.java index 6a7b16d8f..41d37f8aa 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/ListenResponse.java @@ -255,6 +255,7 @@ public ResponseTypeCase getResponseTypeCase() { * * @return Whether the targetChange field is set. */ + @java.lang.Override public boolean hasTargetChange() { return responseTypeCase_ == 2; } @@ -269,6 +270,7 @@ public boolean hasTargetChange() { * * @return The targetChange. */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChange getTargetChange() { if (responseTypeCase_ == 2) { return (com.google.firestore.v1beta1.TargetChange) responseType_; @@ -284,6 +286,7 @@ public com.google.firestore.v1beta1.TargetChange getTargetChange() { * * .google.firestore.v1beta1.TargetChange target_change = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChangeOrBuilder getTargetChangeOrBuilder() { if (responseTypeCase_ == 2) { return (com.google.firestore.v1beta1.TargetChange) responseType_; @@ -303,6 +306,7 @@ public com.google.firestore.v1beta1.TargetChangeOrBuilder getTargetChangeOrBuild * * @return Whether the documentChange field is set. */ + @java.lang.Override public boolean hasDocumentChange() { return responseTypeCase_ == 3; } @@ -317,6 +321,7 @@ public boolean hasDocumentChange() { * * @return The documentChange. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentChange getDocumentChange() { if (responseTypeCase_ == 3) { return (com.google.firestore.v1beta1.DocumentChange) responseType_; @@ -332,6 +337,7 @@ public com.google.firestore.v1beta1.DocumentChange getDocumentChange() { * * .google.firestore.v1beta1.DocumentChange document_change = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentChangeOrBuilder getDocumentChangeOrBuilder() { if (responseTypeCase_ == 3) { return (com.google.firestore.v1beta1.DocumentChange) responseType_; @@ -351,6 +357,7 @@ public com.google.firestore.v1beta1.DocumentChangeOrBuilder getDocumentChangeOrB * * @return Whether the documentDelete field is set. */ + @java.lang.Override public boolean hasDocumentDelete() { return responseTypeCase_ == 4; } @@ -365,6 +372,7 @@ public boolean hasDocumentDelete() { * * @return The documentDelete. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentDelete getDocumentDelete() { if (responseTypeCase_ == 4) { return (com.google.firestore.v1beta1.DocumentDelete) responseType_; @@ -380,6 +388,7 @@ public com.google.firestore.v1beta1.DocumentDelete getDocumentDelete() { * * .google.firestore.v1beta1.DocumentDelete document_delete = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilder() { if (responseTypeCase_ == 4) { return (com.google.firestore.v1beta1.DocumentDelete) responseType_; @@ -400,6 +409,7 @@ public com.google.firestore.v1beta1.DocumentDeleteOrBuilder getDocumentDeleteOrB * * @return Whether the documentRemove field is set. */ + @java.lang.Override public boolean hasDocumentRemove() { return responseTypeCase_ == 6; } @@ -415,6 +425,7 @@ public boolean hasDocumentRemove() { * * @return The documentRemove. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentRemove getDocumentRemove() { if (responseTypeCase_ == 6) { return (com.google.firestore.v1beta1.DocumentRemove) responseType_; @@ -431,6 +442,7 @@ public com.google.firestore.v1beta1.DocumentRemove getDocumentRemove() { * * .google.firestore.v1beta1.DocumentRemove document_remove = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilder() { if (responseTypeCase_ == 6) { return (com.google.firestore.v1beta1.DocumentRemove) responseType_; @@ -453,6 +465,7 @@ public com.google.firestore.v1beta1.DocumentRemoveOrBuilder getDocumentRemoveOrB * * @return Whether the filter field is set. */ + @java.lang.Override public boolean hasFilter() { return responseTypeCase_ == 5; } @@ -470,6 +483,7 @@ public boolean hasFilter() { * * @return The filter. */ + @java.lang.Override public com.google.firestore.v1beta1.ExistenceFilter getFilter() { if (responseTypeCase_ == 5) { return (com.google.firestore.v1beta1.ExistenceFilter) responseType_; @@ -488,6 +502,7 @@ public com.google.firestore.v1beta1.ExistenceFilter getFilter() { * * .google.firestore.v1beta1.ExistenceFilter filter = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.ExistenceFilterOrBuilder getFilterOrBuilder() { if (responseTypeCase_ == 5) { return (com.google.firestore.v1beta1.ExistenceFilter) responseType_; @@ -978,6 +993,7 @@ public Builder clearResponseType() { * * @return Whether the targetChange field is set. */ + @java.lang.Override public boolean hasTargetChange() { return responseTypeCase_ == 2; } @@ -992,6 +1008,7 @@ public boolean hasTargetChange() { * * @return The targetChange. */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChange getTargetChange() { if (targetChangeBuilder_ == null) { if (responseTypeCase_ == 2) { @@ -1124,6 +1141,7 @@ public com.google.firestore.v1beta1.TargetChange.Builder getTargetChangeBuilder( * * .google.firestore.v1beta1.TargetChange target_change = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChangeOrBuilder getTargetChangeOrBuilder() { if ((responseTypeCase_ == 2) && (targetChangeBuilder_ != null)) { return targetChangeBuilder_.getMessageOrBuilder(); @@ -1184,6 +1202,7 @@ public com.google.firestore.v1beta1.TargetChangeOrBuilder getTargetChangeOrBuild * * @return Whether the documentChange field is set. */ + @java.lang.Override public boolean hasDocumentChange() { return responseTypeCase_ == 3; } @@ -1198,6 +1217,7 @@ public boolean hasDocumentChange() { * * @return The documentChange. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentChange getDocumentChange() { if (documentChangeBuilder_ == null) { if (responseTypeCase_ == 3) { @@ -1330,6 +1350,7 @@ public com.google.firestore.v1beta1.DocumentChange.Builder getDocumentChangeBuil * * .google.firestore.v1beta1.DocumentChange document_change = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentChangeOrBuilder getDocumentChangeOrBuilder() { if ((responseTypeCase_ == 3) && (documentChangeBuilder_ != null)) { return documentChangeBuilder_.getMessageOrBuilder(); @@ -1390,6 +1411,7 @@ public com.google.firestore.v1beta1.DocumentChangeOrBuilder getDocumentChangeOrB * * @return Whether the documentDelete field is set. */ + @java.lang.Override public boolean hasDocumentDelete() { return responseTypeCase_ == 4; } @@ -1404,6 +1426,7 @@ public boolean hasDocumentDelete() { * * @return The documentDelete. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentDelete getDocumentDelete() { if (documentDeleteBuilder_ == null) { if (responseTypeCase_ == 4) { @@ -1536,6 +1559,7 @@ public com.google.firestore.v1beta1.DocumentDelete.Builder getDocumentDeleteBuil * * .google.firestore.v1beta1.DocumentDelete document_delete = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentDeleteOrBuilder getDocumentDeleteOrBuilder() { if ((responseTypeCase_ == 4) && (documentDeleteBuilder_ != null)) { return documentDeleteBuilder_.getMessageOrBuilder(); @@ -1597,6 +1621,7 @@ public com.google.firestore.v1beta1.DocumentDeleteOrBuilder getDocumentDeleteOrB * * @return Whether the documentRemove field is set. */ + @java.lang.Override public boolean hasDocumentRemove() { return responseTypeCase_ == 6; } @@ -1612,6 +1637,7 @@ public boolean hasDocumentRemove() { * * @return The documentRemove. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentRemove getDocumentRemove() { if (documentRemoveBuilder_ == null) { if (responseTypeCase_ == 6) { @@ -1750,6 +1776,7 @@ public com.google.firestore.v1beta1.DocumentRemove.Builder getDocumentRemoveBuil * * .google.firestore.v1beta1.DocumentRemove document_remove = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentRemoveOrBuilder getDocumentRemoveOrBuilder() { if ((responseTypeCase_ == 6) && (documentRemoveBuilder_ != null)) { return documentRemoveBuilder_.getMessageOrBuilder(); @@ -1814,6 +1841,7 @@ public com.google.firestore.v1beta1.DocumentRemoveOrBuilder getDocumentRemoveOrB * * @return Whether the filter field is set. */ + @java.lang.Override public boolean hasFilter() { return responseTypeCase_ == 5; } @@ -1831,6 +1859,7 @@ public boolean hasFilter() { * * @return The filter. */ + @java.lang.Override public com.google.firestore.v1beta1.ExistenceFilter getFilter() { if (filterBuilder_ == null) { if (responseTypeCase_ == 5) { @@ -1980,6 +2009,7 @@ public com.google.firestore.v1beta1.ExistenceFilter.Builder getFilterBuilder() { * * .google.firestore.v1beta1.ExistenceFilter filter = 5; */ + @java.lang.Override public com.google.firestore.v1beta1.ExistenceFilterOrBuilder getFilterOrBuilder() { if ((responseTypeCase_ == 5) && (filterBuilder_ != null)) { return filterBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/MapValue.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/MapValue.java index 037af7c60..5b30ab064 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/MapValue.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/MapValue.java @@ -171,6 +171,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -178,6 +179,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -195,6 +197,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -211,6 +214,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1beta1.Value defaultValue) { if (key == null) { @@ -233,6 +237,7 @@ public com.google.firestore.v1beta1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -627,6 +632,7 @@ public int getFieldsCount() { * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public boolean containsFields(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -634,6 +640,7 @@ public boolean containsFields(java.lang.String key) { return internalGetFields().getMap().containsKey(key); } /** Use {@link #getFieldsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getFields() { return getFieldsMap(); @@ -651,6 +658,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public java.util.Map getFieldsMap() { return internalGetFields().getMap(); } @@ -667,6 +675,7 @@ public java.util.Map getFi * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrDefault( java.lang.String key, com.google.firestore.v1beta1.Value defaultValue) { if (key == null) { @@ -689,6 +698,7 @@ public com.google.firestore.v1beta1.Value getFieldsOrDefault( * * map<string, .google.firestore.v1beta1.Value> fields = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getFieldsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Precondition.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Precondition.java index 4693a722c..5dc8429ce 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Precondition.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Precondition.java @@ -183,6 +183,7 @@ public ConditionTypeCase getConditionTypeCase() { * * @return The exists. */ + @java.lang.Override public boolean getExists() { if (conditionTypeCase_ == 1) { return (java.lang.Boolean) conditionType_; @@ -203,6 +204,7 @@ public boolean getExists() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return conditionTypeCase_ == 2; } @@ -218,6 +220,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { if (conditionTypeCase_ == 2) { return (com.google.protobuf.Timestamp) conditionType_; @@ -234,6 +237,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (conditionTypeCase_ == 2) { return (com.google.protobuf.Timestamp) conditionType_; @@ -698,6 +702,7 @@ public Builder clearExists() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return conditionTypeCase_ == 2; } @@ -713,6 +718,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { if (conditionTypeCase_ == 2) { @@ -850,6 +856,7 @@ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { * * .google.protobuf.Timestamp update_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if ((conditionTypeCase_ == 2) && (updateTimeBuilder_ != null)) { return updateTimeBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/QueryProto.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/QueryProto.java index 79a2d6947..0f0a564c7 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/QueryProto.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/QueryProto.java @@ -132,12 +132,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "n\022\031\n\025DIRECTION_UNSPECIFIED\020\000\022\r\n\tASCENDIN" + "G\020\001\022\016\n\nDESCENDING\020\002\"I\n\006Cursor\022/\n\006values\030" + "\001 \003(\0132\037.google.firestore.v1beta1.Value\022\016" - + "\n\006before\030\002 \001(\010B\270\001\n\034com.google.firestore." + + "\n\006before\030\002 \001(\010B\334\001\n\034com.google.firestore." + "v1beta1B\nQueryProtoP\001ZAgoogle.golang.org" + "/genproto/googleapis/firestore/v1beta1;f" + "irestore\242\002\004GCFS\252\002\036Google.Cloud.Firestore" + ".V1Beta1\312\002\036Google\\Cloud\\Firestore\\V1beta" - + "1b\006proto3" + + "1\352\002!Google::Cloud::Firestore::V1beta1b\006p" + + "roto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RollbackRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RollbackRequest.java index a1eb2e3ed..cadbdf9ad 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RollbackRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RollbackRequest.java @@ -131,6 +131,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -154,6 +155,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -179,6 +181,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -637,6 +640,7 @@ public Builder setDatabaseBytes(com.google.protobuf.ByteString value) { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryRequest.java index 8937d9dbb..0621d2f42 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryRequest.java @@ -280,6 +280,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -307,6 +308,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -331,6 +333,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -345,6 +348,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery) queryType_; @@ -360,6 +364,7 @@ public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { * * .google.firestore.v1beta1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery) queryType_; @@ -379,6 +384,7 @@ public com.google.firestore.v1beta1.StructuredQueryOrBuilder getStructuredQueryO * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { if (consistencySelectorCase_ == 5) { return (com.google.protobuf.ByteString) consistencySelector_; @@ -401,6 +407,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 6; } @@ -418,6 +425,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { if (consistencySelectorCase_ == 6) { return (com.google.firestore.v1beta1.TransactionOptions) consistencySelector_; @@ -436,6 +444,7 @@ public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { * * .google.firestore.v1beta1.TransactionOptions new_transaction = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if (consistencySelectorCase_ == 6) { return (com.google.firestore.v1beta1.TransactionOptions) consistencySelector_; @@ -456,6 +465,7 @@ public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactio * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -471,6 +481,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -487,6 +498,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 7) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1126,6 +1138,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1140,6 +1153,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { if (structuredQueryBuilder_ == null) { if (queryTypeCase_ == 2) { @@ -1272,6 +1286,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Builder getStructuredQueryBu * * .google.firestore.v1beta1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if ((queryTypeCase_ == 2) && (structuredQueryBuilder_ != null)) { return structuredQueryBuilder_.getMessageOrBuilder(); @@ -1393,6 +1408,7 @@ public Builder clearTransaction() { * * @return Whether the newTransaction field is set. */ + @java.lang.Override public boolean hasNewTransaction() { return consistencySelectorCase_ == 6; } @@ -1410,6 +1426,7 @@ public boolean hasNewTransaction() { * * @return The newTransaction. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions getNewTransaction() { if (newTransactionBuilder_ == null) { if (consistencySelectorCase_ == 6) { @@ -1561,6 +1578,7 @@ public com.google.firestore.v1beta1.TransactionOptions.Builder getNewTransaction * * .google.firestore.v1beta1.TransactionOptions new_transaction = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactionOrBuilder() { if ((consistencySelectorCase_ == 6) && (newTransactionBuilder_ != null)) { return newTransactionBuilder_.getMessageOrBuilder(); @@ -1626,6 +1644,7 @@ public com.google.firestore.v1beta1.TransactionOptionsOrBuilder getNewTransactio * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 7; } @@ -1641,6 +1660,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 7) { @@ -1778,6 +1798,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 7; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 7) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryResponse.java index 802f15b88..968a53a4e 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/RunQueryResponse.java @@ -161,6 +161,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -179,6 +180,7 @@ public com.google.protobuf.ByteString getTransaction() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -194,6 +196,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getDocument() { return document_ == null ? com.google.firestore.v1beta1.Document.getDefaultInstance() @@ -209,6 +212,7 @@ public com.google.firestore.v1beta1.Document getDocument() { * * .google.firestore.v1beta1.Document document = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -231,6 +235,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -250,6 +255,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -267,6 +273,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 3; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -285,6 +292,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The skippedResults. */ + @java.lang.Override public int getSkippedResults() { return skippedResults_; } @@ -690,6 +698,7 @@ public Builder mergeFrom( * * @return The transaction. */ + @java.lang.Override public com.google.protobuf.ByteString getTransaction() { return transaction_; } @@ -1169,6 +1178,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The skippedResults. */ + @java.lang.Override public int getSkippedResults() { return skippedResults_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/StructuredQuery.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/StructuredQuery.java index 6c0bdec35..373131db4 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/StructuredQuery.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/StructuredQuery.java @@ -346,6 +346,10 @@ public Direction findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -537,6 +541,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The collectionId. */ + @java.lang.Override public java.lang.String getCollectionId() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -560,6 +565,7 @@ public java.lang.String getCollectionId() { * * @return The bytes for collectionId. */ + @java.lang.Override public com.google.protobuf.ByteString getCollectionIdBytes() { java.lang.Object ref = collectionId_; if (ref instanceof java.lang.String) { @@ -587,6 +593,7 @@ public com.google.protobuf.ByteString getCollectionIdBytes() { * * @return The allDescendants. */ + @java.lang.Override public boolean getAllDescendants() { return allDescendants_; } @@ -1060,6 +1067,7 @@ public Builder setCollectionIdBytes(com.google.protobuf.ByteString value) { * * @return The allDescendants. */ + @java.lang.Override public boolean getAllDescendants() { return allDescendants_; } @@ -1478,6 +1486,7 @@ public FilterTypeCase getFilterTypeCase() { * * @return Whether the compositeFilter field is set. */ + @java.lang.Override public boolean hasCompositeFilter() { return filterTypeCase_ == 1; } @@ -1492,6 +1501,7 @@ public boolean hasCompositeFilter() { * * @return The compositeFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter getCompositeFilter() { if (filterTypeCase_ == 1) { return (com.google.firestore.v1beta1.StructuredQuery.CompositeFilter) filterType_; @@ -1507,6 +1517,7 @@ public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter getComposite * * .google.firestore.v1beta1.StructuredQuery.CompositeFilter composite_filter = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilterOrBuilder getCompositeFilterOrBuilder() { if (filterTypeCase_ == 1) { @@ -1527,6 +1538,7 @@ public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter getComposite * * @return Whether the fieldFilter field is set. */ + @java.lang.Override public boolean hasFieldFilter() { return filterTypeCase_ == 2; } @@ -1541,6 +1553,7 @@ public boolean hasFieldFilter() { * * @return The fieldFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilter getFieldFilter() { if (filterTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery.FieldFilter) filterType_; @@ -1556,6 +1569,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldFilter getFieldFilter() * * .google.firestore.v1beta1.StructuredQuery.FieldFilter field_filter = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilterOrBuilder getFieldFilterOrBuilder() { if (filterTypeCase_ == 2) { @@ -1576,6 +1590,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldFilter getFieldFilter() * * @return Whether the unaryFilter field is set. */ + @java.lang.Override public boolean hasUnaryFilter() { return filterTypeCase_ == 3; } @@ -1590,6 +1605,7 @@ public boolean hasUnaryFilter() { * * @return The unaryFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter getUnaryFilter() { if (filterTypeCase_ == 3) { return (com.google.firestore.v1beta1.StructuredQuery.UnaryFilter) filterType_; @@ -1605,6 +1621,7 @@ public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter getUnaryFilter() * * .google.firestore.v1beta1.StructuredQuery.UnaryFilter unary_filter = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilterOrBuilder getUnaryFilterOrBuilder() { if (filterTypeCase_ == 3) { @@ -2053,6 +2070,7 @@ public Builder clearFilterType() { * * @return Whether the compositeFilter field is set. */ + @java.lang.Override public boolean hasCompositeFilter() { return filterTypeCase_ == 1; } @@ -2068,6 +2086,7 @@ public boolean hasCompositeFilter() { * * @return The compositeFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter getCompositeFilter() { if (compositeFilterBuilder_ == null) { if (filterTypeCase_ == 1) { @@ -2211,6 +2230,7 @@ public Builder clearCompositeFilter() { * .google.firestore.v1beta1.StructuredQuery.CompositeFilter composite_filter = 1; * */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilterOrBuilder getCompositeFilterOrBuilder() { if ((filterTypeCase_ == 1) && (compositeFilterBuilder_ != null)) { @@ -2274,6 +2294,7 @@ public Builder clearCompositeFilter() { * * @return Whether the fieldFilter field is set. */ + @java.lang.Override public boolean hasFieldFilter() { return filterTypeCase_ == 2; } @@ -2288,6 +2309,7 @@ public boolean hasFieldFilter() { * * @return The fieldFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilter getFieldFilter() { if (fieldFilterBuilder_ == null) { if (filterTypeCase_ == 2) { @@ -2425,6 +2447,7 @@ public Builder clearFieldFilter() { * * .google.firestore.v1beta1.StructuredQuery.FieldFilter field_filter = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilterOrBuilder getFieldFilterOrBuilder() { if ((filterTypeCase_ == 2) && (fieldFilterBuilder_ != null)) { @@ -2487,6 +2510,7 @@ public Builder clearFieldFilter() { * * @return Whether the unaryFilter field is set. */ + @java.lang.Override public boolean hasUnaryFilter() { return filterTypeCase_ == 3; } @@ -2501,6 +2525,7 @@ public boolean hasUnaryFilter() { * * @return The unaryFilter. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter getUnaryFilter() { if (unaryFilterBuilder_ == null) { if (filterTypeCase_ == 3) { @@ -2638,6 +2663,7 @@ public Builder clearUnaryFilter() { * * .google.firestore.v1beta1.StructuredQuery.UnaryFilter unary_filter = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilterOrBuilder getUnaryFilterOrBuilder() { if ((filterTypeCase_ == 3) && (unaryFilterBuilder_ != null)) { @@ -3034,6 +3060,10 @@ public Operator findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -3081,6 +3111,7 @@ private Operator(int value) { * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -3095,6 +3126,7 @@ public int getOpValue() { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.CompositeFilter.Operator result = @@ -3116,6 +3148,7 @@ public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter.Operator get * * repeated .google.firestore.v1beta1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public java.util.List getFiltersList() { return filters_; } @@ -3129,6 +3162,7 @@ public java.util.List getFi * * repeated .google.firestore.v1beta1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public java.util.List getFiltersOrBuilderList() { return filters_; @@ -3143,6 +3177,7 @@ public java.util.List getFi * * repeated .google.firestore.v1beta1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public int getFiltersCount() { return filters_.size(); } @@ -3156,6 +3191,7 @@ public int getFiltersCount() { * * repeated .google.firestore.v1beta1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Filter getFilters(int index) { return filters_.get(index); } @@ -3169,6 +3205,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Filter getFilters(int index) * * repeated .google.firestore.v1beta1.StructuredQuery.Filter filters = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FilterOrBuilder getFiltersOrBuilder( int index) { return filters_.get(index); @@ -3575,6 +3612,7 @@ public Builder mergeFrom( * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -3591,6 +3629,7 @@ public int getOpValue() { * @return This builder for chaining. */ public Builder setOpValue(int value) { + op_ = value; onChanged(); return this; @@ -3606,6 +3645,7 @@ public Builder setOpValue(int value) { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CompositeFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.CompositeFilter.Operator result = @@ -4572,6 +4612,10 @@ public Operator findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -4619,6 +4663,7 @@ private Operator(int value) { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return field_ != null; } @@ -4633,6 +4678,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { return field_ == null ? com.google.firestore.v1beta1.StructuredQuery.FieldReference.getDefaultInstance() @@ -4647,6 +4693,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { * * .google.firestore.v1beta1.StructuredQuery.FieldReference field = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { return getField(); @@ -4665,6 +4712,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -4679,6 +4727,7 @@ public int getOpValue() { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.FieldFilter.Operator result = @@ -4701,6 +4750,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldFilter.Operator getOp() * * @return Whether the value field is set. */ + @java.lang.Override public boolean hasValue() { return value_ != null; } @@ -4715,6 +4765,7 @@ public boolean hasValue() { * * @return The value. */ + @java.lang.Override public com.google.firestore.v1beta1.Value getValue() { return value_ == null ? com.google.firestore.v1beta1.Value.getDefaultInstance() : value_; } @@ -4727,6 +4778,7 @@ public com.google.firestore.v1beta1.Value getValue() { * * .google.firestore.v1beta1.Value value = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getValueOrBuilder() { return getValue(); } @@ -5312,6 +5364,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference.Builder getFi * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -5328,6 +5381,7 @@ public int getOpValue() { * @return This builder for chaining. */ public Builder setOpValue(int value) { + op_ = value; onChanged(); return this; @@ -5343,6 +5397,7 @@ public Builder setOpValue(int value) { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.FieldFilter.Operator result = @@ -5927,6 +5982,10 @@ public Operator findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -6018,6 +6077,7 @@ public OperandTypeCase getOperandTypeCase() { * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -6032,6 +6092,7 @@ public int getOpValue() { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.UnaryFilter.Operator result = @@ -6053,6 +6114,7 @@ public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter.Operator getOp() * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return operandTypeCase_ == 2; } @@ -6067,6 +6129,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { if (operandTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery.FieldReference) operandType_; @@ -6082,6 +6145,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { * * .google.firestore.v1beta1.StructuredQuery.FieldReference field = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { if (operandTypeCase_ == 2) { @@ -6488,6 +6552,7 @@ public Builder clearOperandType() { * * @return The enum numeric value on the wire for op. */ + @java.lang.Override public int getOpValue() { return op_; } @@ -6504,6 +6569,7 @@ public int getOpValue() { * @return This builder for chaining. */ public Builder setOpValue(int value) { + op_ = value; onChanged(); return this; @@ -6519,6 +6585,7 @@ public Builder setOpValue(int value) { * * @return The op. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.UnaryFilter.Operator getOp() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.UnaryFilter.Operator result = @@ -6583,6 +6650,7 @@ public Builder clearOp() { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return operandTypeCase_ == 2; } @@ -6597,6 +6665,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { if (fieldBuilder_ == null) { if (operandTypeCase_ == 2) { @@ -6731,6 +6800,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference.Builder getFi * * .google.firestore.v1beta1.StructuredQuery.FieldReference field = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { if ((operandTypeCase_ == 2) && (fieldBuilder_ != null)) { @@ -7018,6 +7088,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the field field is set. */ + @java.lang.Override public boolean hasField() { return field_ != null; } @@ -7032,6 +7103,7 @@ public boolean hasField() { * * @return The field. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { return field_ == null ? com.google.firestore.v1beta1.StructuredQuery.FieldReference.getDefaultInstance() @@ -7046,6 +7118,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { * * .google.firestore.v1beta1.StructuredQuery.FieldReference field = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder getFieldOrBuilder() { return getField(); @@ -7064,6 +7137,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getField() { * * @return The enum numeric value on the wire for direction. */ + @java.lang.Override public int getDirectionValue() { return direction_; } @@ -7078,6 +7152,7 @@ public int getDirectionValue() { * * @return The direction. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Direction getDirection() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.Direction result = @@ -7639,6 +7714,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference.Builder getFi * * @return The enum numeric value on the wire for direction. */ + @java.lang.Override public int getDirectionValue() { return direction_; } @@ -7655,6 +7731,7 @@ public int getDirectionValue() { * @return This builder for chaining. */ public Builder setDirectionValue(int value) { + direction_ = value; onChanged(); return this; @@ -7670,6 +7747,7 @@ public Builder setDirectionValue(int value) { * * @return The direction. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Direction getDirection() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.StructuredQuery.Direction result = @@ -7887,6 +7965,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The fieldPath. */ + @java.lang.Override public java.lang.String getFieldPath() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -7903,6 +7982,7 @@ public java.lang.String getFieldPath() { * * @return The bytes for fieldPath. */ + @java.lang.Override public com.google.protobuf.ByteString getFieldPathBytes() { java.lang.Object ref = fieldPath_; if (ref instanceof java.lang.String) { @@ -8555,6 +8635,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.StructuredQuery.FieldReference fields = 2; */ + @java.lang.Override public java.util.List getFieldsList() { return fields_; @@ -8570,6 +8651,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.StructuredQuery.FieldReference fields = 2; */ + @java.lang.Override public java.util.List< ? extends com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder> getFieldsOrBuilderList() { @@ -8586,6 +8668,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * repeated .google.firestore.v1beta1.StructuredQuery.FieldReference fields = 2; */ + @java.lang.Override public int getFieldsCount() { return fields_.size(); } @@ -8600,6 +8683,7 @@ public int getFieldsCount() { * * repeated .google.firestore.v1beta1.StructuredQuery.FieldReference fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReference getFields(int index) { return fields_.get(index); } @@ -8614,6 +8698,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FieldReference getFields(int * * repeated .google.firestore.v1beta1.StructuredQuery.FieldReference fields = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FieldReferenceOrBuilder getFieldsOrBuilder( int index) { return fields_.get(index); @@ -9451,6 +9536,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Projection getDefaultInstanc * * @return Whether the select field is set. */ + @java.lang.Override public boolean hasSelect() { return select_ != null; } @@ -9465,6 +9551,7 @@ public boolean hasSelect() { * * @return The select. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Projection getSelect() { return select_ == null ? com.google.firestore.v1beta1.StructuredQuery.Projection.getDefaultInstance() @@ -9479,6 +9566,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Projection getSelect() { * * .google.firestore.v1beta1.StructuredQuery.Projection select = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.ProjectionOrBuilder getSelectOrBuilder() { return getSelect(); } @@ -9494,6 +9582,7 @@ public com.google.firestore.v1beta1.StructuredQuery.ProjectionOrBuilder getSelec * * repeated .google.firestore.v1beta1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public java.util.List getFromList() { return from_; @@ -9507,6 +9596,7 @@ public com.google.firestore.v1beta1.StructuredQuery.ProjectionOrBuilder getSelec * * repeated .google.firestore.v1beta1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public java.util.List< ? extends com.google.firestore.v1beta1.StructuredQuery.CollectionSelectorOrBuilder> getFromOrBuilderList() { @@ -9521,6 +9611,7 @@ public com.google.firestore.v1beta1.StructuredQuery.ProjectionOrBuilder getSelec * * repeated .google.firestore.v1beta1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public int getFromCount() { return from_.size(); } @@ -9533,6 +9624,7 @@ public int getFromCount() { * * repeated .google.firestore.v1beta1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CollectionSelector getFrom(int index) { return from_.get(index); } @@ -9545,6 +9637,7 @@ public com.google.firestore.v1beta1.StructuredQuery.CollectionSelector getFrom(i * * repeated .google.firestore.v1beta1.StructuredQuery.CollectionSelector from = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.CollectionSelectorOrBuilder getFromOrBuilder( int index) { return from_.get(index); @@ -9563,6 +9656,7 @@ public com.google.firestore.v1beta1.StructuredQuery.CollectionSelectorOrBuilder * * @return Whether the where field is set. */ + @java.lang.Override public boolean hasWhere() { return where_ != null; } @@ -9577,6 +9671,7 @@ public boolean hasWhere() { * * @return The where. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Filter getWhere() { return where_ == null ? com.google.firestore.v1beta1.StructuredQuery.Filter.getDefaultInstance() @@ -9591,6 +9686,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Filter getWhere() { * * .google.firestore.v1beta1.StructuredQuery.Filter where = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.FilterOrBuilder getWhereOrBuilder() { return getWhere(); } @@ -9619,6 +9715,7 @@ public com.google.firestore.v1beta1.StructuredQuery.FilterOrBuilder getWhereOrBu * * repeated .google.firestore.v1beta1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public java.util.List getOrderByList() { return orderBy_; } @@ -9644,6 +9741,7 @@ public java.util.List getOrd * * repeated .google.firestore.v1beta1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public java.util.List getOrderByOrBuilderList() { return orderBy_; @@ -9670,6 +9768,7 @@ public java.util.List getOrd * * repeated .google.firestore.v1beta1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public int getOrderByCount() { return orderBy_.size(); } @@ -9695,6 +9794,7 @@ public int getOrderByCount() { * * repeated .google.firestore.v1beta1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.Order getOrderBy(int index) { return orderBy_.get(index); } @@ -9720,6 +9820,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Order getOrderBy(int index) * * repeated .google.firestore.v1beta1.StructuredQuery.Order order_by = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery.OrderOrBuilder getOrderByOrBuilder( int index) { return orderBy_.get(index); @@ -9738,6 +9839,7 @@ public com.google.firestore.v1beta1.StructuredQuery.OrderOrBuilder getOrderByOrB * * @return Whether the startAt field is set. */ + @java.lang.Override public boolean hasStartAt() { return startAt_ != null; } @@ -9752,6 +9854,7 @@ public boolean hasStartAt() { * * @return The startAt. */ + @java.lang.Override public com.google.firestore.v1beta1.Cursor getStartAt() { return startAt_ == null ? com.google.firestore.v1beta1.Cursor.getDefaultInstance() : startAt_; } @@ -9764,6 +9867,7 @@ public com.google.firestore.v1beta1.Cursor getStartAt() { * * .google.firestore.v1beta1.Cursor start_at = 7; */ + @java.lang.Override public com.google.firestore.v1beta1.CursorOrBuilder getStartAtOrBuilder() { return getStartAt(); } @@ -9781,6 +9885,7 @@ public com.google.firestore.v1beta1.CursorOrBuilder getStartAtOrBuilder() { * * @return Whether the endAt field is set. */ + @java.lang.Override public boolean hasEndAt() { return endAt_ != null; } @@ -9795,6 +9900,7 @@ public boolean hasEndAt() { * * @return The endAt. */ + @java.lang.Override public com.google.firestore.v1beta1.Cursor getEndAt() { return endAt_ == null ? com.google.firestore.v1beta1.Cursor.getDefaultInstance() : endAt_; } @@ -9807,6 +9913,7 @@ public com.google.firestore.v1beta1.Cursor getEndAt() { * * .google.firestore.v1beta1.Cursor end_at = 8; */ + @java.lang.Override public com.google.firestore.v1beta1.CursorOrBuilder getEndAtOrBuilder() { return getEndAt(); } @@ -9826,6 +9933,7 @@ public com.google.firestore.v1beta1.CursorOrBuilder getEndAtOrBuilder() { * * @return The offset. */ + @java.lang.Override public int getOffset() { return offset_; } @@ -9845,6 +9953,7 @@ public int getOffset() { * * @return Whether the limit field is set. */ + @java.lang.Override public boolean hasLimit() { return limit_ != null; } @@ -9861,6 +9970,7 @@ public boolean hasLimit() { * * @return The limit. */ + @java.lang.Override public com.google.protobuf.Int32Value getLimit() { return limit_ == null ? com.google.protobuf.Int32Value.getDefaultInstance() : limit_; } @@ -9875,6 +9985,7 @@ public com.google.protobuf.Int32Value getLimit() { * * .google.protobuf.Int32Value limit = 5; */ + @java.lang.Override public com.google.protobuf.Int32ValueOrBuilder getLimitOrBuilder() { return getLimit(); } @@ -12152,6 +12263,7 @@ public com.google.firestore.v1beta1.CursorOrBuilder getEndAtOrBuilder() { * * @return The offset. */ + @java.lang.Override public int getOffset() { return offset_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Target.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Target.java index 4bc9af089..f5b0eb6a2 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Target.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Target.java @@ -1249,6 +1249,7 @@ public QueryTypeCase getQueryTypeCase() { * * @return The parent. */ + @java.lang.Override public java.lang.String getParent() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -1276,6 +1277,7 @@ public java.lang.String getParent() { * * @return The bytes for parent. */ + @java.lang.Override public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { @@ -1300,6 +1302,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1314,6 +1317,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery) queryType_; @@ -1329,6 +1333,7 @@ public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { * * .google.firestore.v1beta1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if (queryTypeCase_ == 2) { return (com.google.firestore.v1beta1.StructuredQuery) queryType_; @@ -1864,6 +1869,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * @return Whether the structuredQuery field is set. */ + @java.lang.Override public boolean hasStructuredQuery() { return queryTypeCase_ == 2; } @@ -1878,6 +1884,7 @@ public boolean hasStructuredQuery() { * * @return The structuredQuery. */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQuery getStructuredQuery() { if (structuredQueryBuilder_ == null) { if (queryTypeCase_ == 2) { @@ -2010,6 +2017,7 @@ public com.google.firestore.v1beta1.StructuredQuery.Builder getStructuredQueryBu * * .google.firestore.v1beta1.StructuredQuery structured_query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.StructuredQueryOrBuilder getStructuredQueryOrBuilder() { if ((queryTypeCase_ == 2) && (structuredQueryBuilder_ != null)) { return structuredQueryBuilder_.getMessageOrBuilder(); @@ -2212,6 +2220,7 @@ public ResumeTypeCase getResumeTypeCase() { * * @return Whether the query field is set. */ + @java.lang.Override public boolean hasQuery() { return targetTypeCase_ == 2; } @@ -2226,6 +2235,7 @@ public boolean hasQuery() { * * @return The query. */ + @java.lang.Override public com.google.firestore.v1beta1.Target.QueryTarget getQuery() { if (targetTypeCase_ == 2) { return (com.google.firestore.v1beta1.Target.QueryTarget) targetType_; @@ -2241,6 +2251,7 @@ public com.google.firestore.v1beta1.Target.QueryTarget getQuery() { * * .google.firestore.v1beta1.Target.QueryTarget query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Target.QueryTargetOrBuilder getQueryOrBuilder() { if (targetTypeCase_ == 2) { return (com.google.firestore.v1beta1.Target.QueryTarget) targetType_; @@ -2260,6 +2271,7 @@ public com.google.firestore.v1beta1.Target.QueryTargetOrBuilder getQueryOrBuilde * * @return Whether the documents field is set. */ + @java.lang.Override public boolean hasDocuments() { return targetTypeCase_ == 3; } @@ -2274,6 +2286,7 @@ public boolean hasDocuments() { * * @return The documents. */ + @java.lang.Override public com.google.firestore.v1beta1.Target.DocumentsTarget getDocuments() { if (targetTypeCase_ == 3) { return (com.google.firestore.v1beta1.Target.DocumentsTarget) targetType_; @@ -2289,6 +2302,7 @@ public com.google.firestore.v1beta1.Target.DocumentsTarget getDocuments() { * * .google.firestore.v1beta1.Target.DocumentsTarget documents = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.Target.DocumentsTargetOrBuilder getDocumentsOrBuilder() { if (targetTypeCase_ == 3) { return (com.google.firestore.v1beta1.Target.DocumentsTarget) targetType_; @@ -2309,6 +2323,7 @@ public com.google.firestore.v1beta1.Target.DocumentsTargetOrBuilder getDocuments * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { if (resumeTypeCase_ == 4) { return (com.google.protobuf.ByteString) resumeType_; @@ -2329,6 +2344,7 @@ public com.google.protobuf.ByteString getResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return resumeTypeCase_ == 11; } @@ -2344,6 +2360,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (resumeTypeCase_ == 11) { return (com.google.protobuf.Timestamp) resumeType_; @@ -2360,6 +2377,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 11; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (resumeTypeCase_ == 11) { return (com.google.protobuf.Timestamp) resumeType_; @@ -2381,6 +2399,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -2398,6 +2417,7 @@ public int getTargetId() { * * @return The once. */ + @java.lang.Override public boolean getOnce() { return once_; } @@ -2913,6 +2933,7 @@ public Builder clearResumeType() { * * @return Whether the query field is set. */ + @java.lang.Override public boolean hasQuery() { return targetTypeCase_ == 2; } @@ -2927,6 +2948,7 @@ public boolean hasQuery() { * * @return The query. */ + @java.lang.Override public com.google.firestore.v1beta1.Target.QueryTarget getQuery() { if (queryBuilder_ == null) { if (targetTypeCase_ == 2) { @@ -3060,6 +3082,7 @@ public com.google.firestore.v1beta1.Target.QueryTarget.Builder getQueryBuilder() * * .google.firestore.v1beta1.Target.QueryTarget query = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Target.QueryTargetOrBuilder getQueryOrBuilder() { if ((targetTypeCase_ == 2) && (queryBuilder_ != null)) { return queryBuilder_.getMessageOrBuilder(); @@ -3120,6 +3143,7 @@ public com.google.firestore.v1beta1.Target.QueryTargetOrBuilder getQueryOrBuilde * * @return Whether the documents field is set. */ + @java.lang.Override public boolean hasDocuments() { return targetTypeCase_ == 3; } @@ -3134,6 +3158,7 @@ public boolean hasDocuments() { * * @return The documents. */ + @java.lang.Override public com.google.firestore.v1beta1.Target.DocumentsTarget getDocuments() { if (documentsBuilder_ == null) { if (targetTypeCase_ == 3) { @@ -3267,6 +3292,7 @@ public com.google.firestore.v1beta1.Target.DocumentsTarget.Builder getDocumentsB * * .google.firestore.v1beta1.Target.DocumentsTarget documents = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.Target.DocumentsTargetOrBuilder getDocumentsOrBuilder() { if ((targetTypeCase_ == 3) && (documentsBuilder_ != null)) { return documentsBuilder_.getMessageOrBuilder(); @@ -3389,6 +3415,7 @@ public Builder clearResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return resumeTypeCase_ == 11; } @@ -3404,6 +3431,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (resumeTypeCase_ == 11) { @@ -3540,6 +3568,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 11; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((resumeTypeCase_ == 11) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -3596,6 +3625,7 @@ public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { * * @return The targetId. */ + @java.lang.Override public int getTargetId() { return targetId_; } @@ -3649,6 +3679,7 @@ public Builder clearTargetId() { * * @return The once. */ + @java.lang.Override public boolean getOnce() { return once_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TargetChange.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TargetChange.java index cd1953e49..c2d9b5978 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TargetChange.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TargetChange.java @@ -356,6 +356,10 @@ public TargetChangeType findValueByNumber(int number) { }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } return getDescriptor().getValues().get(ordinal()); } @@ -402,6 +406,7 @@ private TargetChangeType(int value) { * * @return The enum numeric value on the wire for targetChangeType. */ + @java.lang.Override public int getTargetChangeTypeValue() { return targetChangeType_; } @@ -416,6 +421,7 @@ public int getTargetChangeTypeValue() { * * @return The targetChangeType. */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChange.TargetChangeType getTargetChangeType() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.TargetChange.TargetChangeType result = @@ -440,6 +446,7 @@ public com.google.firestore.v1beta1.TargetChange.TargetChangeType getTargetChang * * @return A list containing the targetIds. */ + @java.lang.Override public java.util.List getTargetIdsList() { return targetIds_; } @@ -492,6 +499,7 @@ public int getTargetIds(int index) { * * @return Whether the cause field is set. */ + @java.lang.Override public boolean hasCause() { return cause_ != null; } @@ -506,6 +514,7 @@ public boolean hasCause() { * * @return The cause. */ + @java.lang.Override public com.google.rpc.Status getCause() { return cause_ == null ? com.google.rpc.Status.getDefaultInstance() : cause_; } @@ -518,6 +527,7 @@ public com.google.rpc.Status getCause() { * * .google.rpc.Status cause = 3; */ + @java.lang.Override public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { return getCause(); } @@ -537,6 +547,7 @@ public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { return resumeToken_; } @@ -561,6 +572,7 @@ public com.google.protobuf.ByteString getResumeToken() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return readTime_ != null; } @@ -582,6 +594,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { return readTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readTime_; } @@ -601,6 +614,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 6; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { return getReadTime(); } @@ -1051,6 +1065,7 @@ public Builder mergeFrom( * * @return The enum numeric value on the wire for targetChangeType. */ + @java.lang.Override public int getTargetChangeTypeValue() { return targetChangeType_; } @@ -1067,6 +1082,7 @@ public int getTargetChangeTypeValue() { * @return This builder for chaining. */ public Builder setTargetChangeTypeValue(int value) { + targetChangeType_ = value; onChanged(); return this; @@ -1082,6 +1098,7 @@ public Builder setTargetChangeTypeValue(int value) { * * @return The targetChangeType. */ + @java.lang.Override public com.google.firestore.v1beta1.TargetChange.TargetChangeType getTargetChangeType() { @SuppressWarnings("deprecation") com.google.firestore.v1beta1.TargetChange.TargetChangeType result = @@ -1457,6 +1474,7 @@ public com.google.rpc.StatusOrBuilder getCauseOrBuilder() { * * @return The resumeToken. */ + @java.lang.Override public com.google.protobuf.ByteString getResumeToken() { return resumeToken_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TransactionOptions.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TransactionOptions.java index f05973b37..0aeb1a3b7 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TransactionOptions.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/TransactionOptions.java @@ -262,6 +262,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The retryTransaction. */ + @java.lang.Override public com.google.protobuf.ByteString getRetryTransaction() { return retryTransaction_; } @@ -601,6 +602,7 @@ public Builder mergeFrom( * * @return The retryTransaction. */ + @java.lang.Override public com.google.protobuf.ByteString getRetryTransaction() { return retryTransaction_; } @@ -897,6 +899,7 @@ public ConsistencySelectorCase getConsistencySelectorCase() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 2; } @@ -912,6 +915,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (consistencySelectorCase_ == 2) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -928,6 +932,7 @@ public com.google.protobuf.Timestamp getReadTime() { * * .google.protobuf.Timestamp read_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if (consistencySelectorCase_ == 2) { return (com.google.protobuf.Timestamp) consistencySelector_; @@ -1318,6 +1323,7 @@ public Builder clearConsistencySelector() { * * @return Whether the readTime field is set. */ + @java.lang.Override public boolean hasReadTime() { return consistencySelectorCase_ == 2; } @@ -1333,6 +1339,7 @@ public boolean hasReadTime() { * * @return The readTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getReadTime() { if (readTimeBuilder_ == null) { if (consistencySelectorCase_ == 2) { @@ -1470,6 +1477,7 @@ public com.google.protobuf.Timestamp.Builder getReadTimeBuilder() { * * .google.protobuf.Timestamp read_time = 2; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getReadTimeOrBuilder() { if ((consistencySelectorCase_ == 2) && (readTimeBuilder_ != null)) { return readTimeBuilder_.getMessageOrBuilder(); @@ -1626,6 +1634,7 @@ public ModeCase getModeCase() { * * @return Whether the readOnly field is set. */ + @java.lang.Override public boolean hasReadOnly() { return modeCase_ == 2; } @@ -1640,6 +1649,7 @@ public boolean hasReadOnly() { * * @return The readOnly. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadOnly getReadOnly() { if (modeCase_ == 2) { return (com.google.firestore.v1beta1.TransactionOptions.ReadOnly) mode_; @@ -1655,6 +1665,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadOnly getReadOnly() { * * .google.firestore.v1beta1.TransactionOptions.ReadOnly read_only = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyOrBuilder() { if (modeCase_ == 2) { return (com.google.firestore.v1beta1.TransactionOptions.ReadOnly) mode_; @@ -1674,6 +1685,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadOnlyOrBuilder getRead * * @return Whether the readWrite field is set. */ + @java.lang.Override public boolean hasReadWrite() { return modeCase_ == 3; } @@ -1688,6 +1700,7 @@ public boolean hasReadWrite() { * * @return The readWrite. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadWrite getReadWrite() { if (modeCase_ == 3) { return (com.google.firestore.v1beta1.TransactionOptions.ReadWrite) mode_; @@ -1703,6 +1716,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadWrite getReadWrite() * * .google.firestore.v1beta1.TransactionOptions.ReadWrite read_write = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadWriteOrBuilder getReadWriteOrBuilder() { if (modeCase_ == 3) { @@ -2114,6 +2128,7 @@ public Builder clearMode() { * * @return Whether the readOnly field is set. */ + @java.lang.Override public boolean hasReadOnly() { return modeCase_ == 2; } @@ -2128,6 +2143,7 @@ public boolean hasReadOnly() { * * @return The readOnly. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadOnly getReadOnly() { if (readOnlyBuilder_ == null) { if (modeCase_ == 2) { @@ -2261,6 +2277,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadOnly.Builder getReadO * * .google.firestore.v1beta1.TransactionOptions.ReadOnly read_only = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadOnlyOrBuilder getReadOnlyOrBuilder() { if ((modeCase_ == 2) && (readOnlyBuilder_ != null)) { @@ -2322,6 +2339,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadOnly.Builder getReadO * * @return Whether the readWrite field is set. */ + @java.lang.Override public boolean hasReadWrite() { return modeCase_ == 3; } @@ -2336,6 +2354,7 @@ public boolean hasReadWrite() { * * @return The readWrite. */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadWrite getReadWrite() { if (readWriteBuilder_ == null) { if (modeCase_ == 3) { @@ -2469,6 +2488,7 @@ public com.google.firestore.v1beta1.TransactionOptions.ReadWrite.Builder getRead * * .google.firestore.v1beta1.TransactionOptions.ReadWrite read_write = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.TransactionOptions.ReadWriteOrBuilder getReadWriteOrBuilder() { if ((modeCase_ == 3) && (readWriteBuilder_ != null)) { diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/UpdateDocumentRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/UpdateDocumentRequest.java index ba01c4418..0011d4cf1 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/UpdateDocumentRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/UpdateDocumentRequest.java @@ -182,6 +182,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the document field is set. */ + @java.lang.Override public boolean hasDocument() { return document_ != null; } @@ -199,6 +200,7 @@ public boolean hasDocument() { * * @return The document. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getDocument() { return document_ == null ? com.google.firestore.v1beta1.Document.getDefaultInstance() @@ -216,6 +218,7 @@ public com.google.firestore.v1beta1.Document getDocument() { * .google.firestore.v1beta1.Document document = 1 [(.google.api.field_behavior) = REQUIRED]; * */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { return getDocument(); } @@ -238,6 +241,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getDocumentOrBuilder() { * * @return Whether the updateMask field is set. */ + @java.lang.Override public boolean hasUpdateMask() { return updateMask_ != null; } @@ -257,6 +261,7 @@ public boolean hasUpdateMask() { * * @return The updateMask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getUpdateMask() { return updateMask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() @@ -276,6 +281,7 @@ public com.google.firestore.v1beta1.DocumentMask getUpdateMask() { * * .google.firestore.v1beta1.DocumentMask update_mask = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { return getUpdateMask(); } @@ -295,6 +301,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getUpdateMaskOrBuilder * * @return Whether the mask field is set. */ + @java.lang.Override public boolean hasMask() { return mask_ != null; } @@ -311,6 +318,7 @@ public boolean hasMask() { * * @return The mask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getMask() { return mask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() : mask_; } @@ -325,6 +333,7 @@ public com.google.firestore.v1beta1.DocumentMask getMask() { * * .google.firestore.v1beta1.DocumentMask mask = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { return getMask(); } @@ -343,6 +352,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getMaskOrBuilder() { * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -358,6 +368,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1beta1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1beta1.Precondition.getDefaultInstance() @@ -373,6 +384,7 @@ public com.google.firestore.v1beta1.Precondition getCurrentDocument() { * * .google.firestore.v1beta1.Precondition current_document = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Value.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Value.java index 2e7eb260c..03560472d 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Value.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Value.java @@ -333,6 +333,7 @@ public com.google.protobuf.NullValue getNullValue() { * * @return The booleanValue. */ + @java.lang.Override public boolean getBooleanValue() { if (valueTypeCase_ == 1) { return (java.lang.Boolean) valueType_; @@ -352,6 +353,7 @@ public boolean getBooleanValue() { * * @return The integerValue. */ + @java.lang.Override public long getIntegerValue() { if (valueTypeCase_ == 2) { return (java.lang.Long) valueType_; @@ -371,6 +373,7 @@ public long getIntegerValue() { * * @return The doubleValue. */ + @java.lang.Override public double getDoubleValue() { if (valueTypeCase_ == 3) { return (java.lang.Double) valueType_; @@ -392,6 +395,7 @@ public double getDoubleValue() { * * @return Whether the timestampValue field is set. */ + @java.lang.Override public boolean hasTimestampValue() { return valueTypeCase_ == 10; } @@ -408,6 +412,7 @@ public boolean hasTimestampValue() { * * @return The timestampValue. */ + @java.lang.Override public com.google.protobuf.Timestamp getTimestampValue() { if (valueTypeCase_ == 10) { return (com.google.protobuf.Timestamp) valueType_; @@ -425,6 +430,7 @@ public com.google.protobuf.Timestamp getTimestampValue() { * * .google.protobuf.Timestamp timestamp_value = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { if (valueTypeCase_ == 10) { return (com.google.protobuf.Timestamp) valueType_; @@ -508,6 +514,7 @@ public com.google.protobuf.ByteString getStringValueBytes() { * * @return The bytesValue. */ + @java.lang.Override public com.google.protobuf.ByteString getBytesValue() { if (valueTypeCase_ == 18) { return (com.google.protobuf.ByteString) valueType_; @@ -585,6 +592,7 @@ public com.google.protobuf.ByteString getReferenceValueBytes() { * * @return Whether the geoPointValue field is set. */ + @java.lang.Override public boolean hasGeoPointValue() { return valueTypeCase_ == 8; } @@ -599,6 +607,7 @@ public boolean hasGeoPointValue() { * * @return The geoPointValue. */ + @java.lang.Override public com.google.type.LatLng getGeoPointValue() { if (valueTypeCase_ == 8) { return (com.google.type.LatLng) valueType_; @@ -614,6 +623,7 @@ public com.google.type.LatLng getGeoPointValue() { * * .google.type.LatLng geo_point_value = 8; */ + @java.lang.Override public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { if (valueTypeCase_ == 8) { return (com.google.type.LatLng) valueType_; @@ -635,6 +645,7 @@ public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { * * @return Whether the arrayValue field is set. */ + @java.lang.Override public boolean hasArrayValue() { return valueTypeCase_ == 9; } @@ -651,6 +662,7 @@ public boolean hasArrayValue() { * * @return The arrayValue. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getArrayValue() { if (valueTypeCase_ == 9) { return (com.google.firestore.v1beta1.ArrayValue) valueType_; @@ -668,6 +680,7 @@ public com.google.firestore.v1beta1.ArrayValue getArrayValue() { * * .google.firestore.v1beta1.ArrayValue array_value = 9; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getArrayValueOrBuilder() { if (valueTypeCase_ == 9) { return (com.google.firestore.v1beta1.ArrayValue) valueType_; @@ -687,6 +700,7 @@ public com.google.firestore.v1beta1.ArrayValueOrBuilder getArrayValueOrBuilder() * * @return Whether the mapValue field is set. */ + @java.lang.Override public boolean hasMapValue() { return valueTypeCase_ == 6; } @@ -701,6 +715,7 @@ public boolean hasMapValue() { * * @return The mapValue. */ + @java.lang.Override public com.google.firestore.v1beta1.MapValue getMapValue() { if (valueTypeCase_ == 6) { return (com.google.firestore.v1beta1.MapValue) valueType_; @@ -716,6 +731,7 @@ public com.google.firestore.v1beta1.MapValue getMapValue() { * * .google.firestore.v1beta1.MapValue map_value = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.MapValueOrBuilder getMapValueOrBuilder() { if (valueTypeCase_ == 6) { return (com.google.firestore.v1beta1.MapValue) valueType_; @@ -1336,6 +1352,7 @@ public Builder clearValueType() { * * @return The enum numeric value on the wire for nullValue. */ + @java.lang.Override public int getNullValueValue() { if (valueTypeCase_ == 11) { return ((java.lang.Integer) valueType_).intValue(); @@ -1371,6 +1388,7 @@ public Builder setNullValueValue(int value) { * * @return The nullValue. */ + @java.lang.Override public com.google.protobuf.NullValue getNullValue() { if (valueTypeCase_ == 11) { @SuppressWarnings("deprecation") @@ -1604,6 +1622,7 @@ public Builder clearDoubleValue() { * * @return Whether the timestampValue field is set. */ + @java.lang.Override public boolean hasTimestampValue() { return valueTypeCase_ == 10; } @@ -1620,6 +1639,7 @@ public boolean hasTimestampValue() { * * @return The timestampValue. */ + @java.lang.Override public com.google.protobuf.Timestamp getTimestampValue() { if (timestampValueBuilder_ == null) { if (valueTypeCase_ == 10) { @@ -1762,6 +1782,7 @@ public com.google.protobuf.Timestamp.Builder getTimestampValueBuilder() { * * .google.protobuf.Timestamp timestamp_value = 10; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { if ((valueTypeCase_ == 10) && (timestampValueBuilder_ != null)) { return timestampValueBuilder_.getMessageOrBuilder(); @@ -1820,6 +1841,7 @@ public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { * * @return The stringValue. */ + @java.lang.Override public java.lang.String getStringValue() { java.lang.Object ref = ""; if (valueTypeCase_ == 17) { @@ -1850,6 +1872,7 @@ public java.lang.String getStringValue() { * * @return The bytes for stringValue. */ + @java.lang.Override public com.google.protobuf.ByteString getStringValueBytes() { java.lang.Object ref = ""; if (valueTypeCase_ == 17) { @@ -2014,6 +2037,7 @@ public Builder clearBytesValue() { * * @return The referenceValue. */ + @java.lang.Override public java.lang.String getReferenceValue() { java.lang.Object ref = ""; if (valueTypeCase_ == 5) { @@ -2042,6 +2066,7 @@ public java.lang.String getReferenceValue() { * * @return The bytes for referenceValue. */ + @java.lang.Override public com.google.protobuf.ByteString getReferenceValueBytes() { java.lang.Object ref = ""; if (valueTypeCase_ == 5) { @@ -2138,6 +2163,7 @@ public Builder setReferenceValueBytes(com.google.protobuf.ByteString value) { * * @return Whether the geoPointValue field is set. */ + @java.lang.Override public boolean hasGeoPointValue() { return valueTypeCase_ == 8; } @@ -2152,6 +2178,7 @@ public boolean hasGeoPointValue() { * * @return The geoPointValue. */ + @java.lang.Override public com.google.type.LatLng getGeoPointValue() { if (geoPointValueBuilder_ == null) { if (valueTypeCase_ == 8) { @@ -2281,6 +2308,7 @@ public com.google.type.LatLng.Builder getGeoPointValueBuilder() { * * .google.type.LatLng geo_point_value = 8; */ + @java.lang.Override public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { if ((valueTypeCase_ == 8) && (geoPointValueBuilder_ != null)) { return geoPointValueBuilder_.getMessageOrBuilder(); @@ -2339,6 +2367,7 @@ public com.google.type.LatLngOrBuilder getGeoPointValueOrBuilder() { * * @return Whether the arrayValue field is set. */ + @java.lang.Override public boolean hasArrayValue() { return valueTypeCase_ == 9; } @@ -2355,6 +2384,7 @@ public boolean hasArrayValue() { * * @return The arrayValue. */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValue getArrayValue() { if (arrayValueBuilder_ == null) { if (valueTypeCase_ == 9) { @@ -2498,6 +2528,7 @@ public com.google.firestore.v1beta1.ArrayValue.Builder getArrayValueBuilder() { * * .google.firestore.v1beta1.ArrayValue array_value = 9; */ + @java.lang.Override public com.google.firestore.v1beta1.ArrayValueOrBuilder getArrayValueOrBuilder() { if ((valueTypeCase_ == 9) && (arrayValueBuilder_ != null)) { return arrayValueBuilder_.getMessageOrBuilder(); @@ -2560,6 +2591,7 @@ public com.google.firestore.v1beta1.ArrayValueOrBuilder getArrayValueOrBuilder() * * @return Whether the mapValue field is set. */ + @java.lang.Override public boolean hasMapValue() { return valueTypeCase_ == 6; } @@ -2574,6 +2606,7 @@ public boolean hasMapValue() { * * @return The mapValue. */ + @java.lang.Override public com.google.firestore.v1beta1.MapValue getMapValue() { if (mapValueBuilder_ == null) { if (valueTypeCase_ == 6) { @@ -2705,6 +2738,7 @@ public com.google.firestore.v1beta1.MapValue.Builder getMapValueBuilder() { * * .google.firestore.v1beta1.MapValue map_value = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.MapValueOrBuilder getMapValueOrBuilder() { if ((valueTypeCase_ == 6) && (mapValueBuilder_ != null)) { return mapValueBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Write.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Write.java index 735c1cb9b..ead5643d3 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Write.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/Write.java @@ -236,6 +236,7 @@ public OperationCase getOperationCase() { * * @return Whether the update field is set. */ + @java.lang.Override public boolean hasUpdate() { return operationCase_ == 1; } @@ -250,6 +251,7 @@ public boolean hasUpdate() { * * @return The update. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getUpdate() { if (operationCase_ == 1) { return (com.google.firestore.v1beta1.Document) operation_; @@ -265,6 +267,7 @@ public com.google.firestore.v1beta1.Document getUpdate() { * * .google.firestore.v1beta1.Document update = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getUpdateOrBuilder() { if (operationCase_ == 1) { return (com.google.firestore.v1beta1.Document) operation_; @@ -345,6 +348,7 @@ public com.google.protobuf.ByteString getDeleteBytes() { * * @return Whether the transform field is set. */ + @java.lang.Override public boolean hasTransform() { return operationCase_ == 6; } @@ -362,6 +366,7 @@ public boolean hasTransform() { * * @return The transform. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransform getTransform() { if (operationCase_ == 6) { return (com.google.firestore.v1beta1.DocumentTransform) operation_; @@ -380,6 +385,7 @@ public com.google.firestore.v1beta1.DocumentTransform getTransform() { * * .google.firestore.v1beta1.DocumentTransform transform = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransformOrBuilder getTransformOrBuilder() { if (operationCase_ == 6) { return (com.google.firestore.v1beta1.DocumentTransform) operation_; @@ -408,6 +414,7 @@ public com.google.firestore.v1beta1.DocumentTransformOrBuilder getTransformOrBui * * @return Whether the updateMask field is set. */ + @java.lang.Override public boolean hasUpdateMask() { return updateMask_ != null; } @@ -430,6 +437,7 @@ public boolean hasUpdateMask() { * * @return The updateMask. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMask getUpdateMask() { return updateMask_ == null ? com.google.firestore.v1beta1.DocumentMask.getDefaultInstance() @@ -452,6 +460,7 @@ public com.google.firestore.v1beta1.DocumentMask getUpdateMask() { * * .google.firestore.v1beta1.DocumentMask update_mask = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentMaskOrBuilder getUpdateMaskOrBuilder() { return getUpdateMask(); } @@ -470,6 +479,7 @@ public com.google.firestore.v1beta1.DocumentMaskOrBuilder getUpdateMaskOrBuilder * * @return Whether the currentDocument field is set. */ + @java.lang.Override public boolean hasCurrentDocument() { return currentDocument_ != null; } @@ -485,6 +495,7 @@ public boolean hasCurrentDocument() { * * @return The currentDocument. */ + @java.lang.Override public com.google.firestore.v1beta1.Precondition getCurrentDocument() { return currentDocument_ == null ? com.google.firestore.v1beta1.Precondition.getDefaultInstance() @@ -500,6 +511,7 @@ public com.google.firestore.v1beta1.Precondition getCurrentDocument() { * * .google.firestore.v1beta1.Precondition current_document = 4; */ + @java.lang.Override public com.google.firestore.v1beta1.PreconditionOrBuilder getCurrentDocumentOrBuilder() { return getCurrentDocument(); } @@ -982,6 +994,7 @@ public Builder clearOperation() { * * @return Whether the update field is set. */ + @java.lang.Override public boolean hasUpdate() { return operationCase_ == 1; } @@ -996,6 +1009,7 @@ public boolean hasUpdate() { * * @return The update. */ + @java.lang.Override public com.google.firestore.v1beta1.Document getUpdate() { if (updateBuilder_ == null) { if (operationCase_ == 1) { @@ -1127,6 +1141,7 @@ public com.google.firestore.v1beta1.Document.Builder getUpdateBuilder() { * * .google.firestore.v1beta1.Document update = 1; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentOrBuilder getUpdateOrBuilder() { if ((operationCase_ == 1) && (updateBuilder_ != null)) { return updateBuilder_.getMessageOrBuilder(); @@ -1183,6 +1198,7 @@ public com.google.firestore.v1beta1.DocumentOrBuilder getUpdateOrBuilder() { * * @return The delete. */ + @java.lang.Override public java.lang.String getDelete() { java.lang.Object ref = ""; if (operationCase_ == 2) { @@ -1211,6 +1227,7 @@ public java.lang.String getDelete() { * * @return The bytes for delete. */ + @java.lang.Override public com.google.protobuf.ByteString getDeleteBytes() { java.lang.Object ref = ""; if (operationCase_ == 2) { @@ -1312,6 +1329,7 @@ public Builder setDeleteBytes(com.google.protobuf.ByteString value) { * * @return Whether the transform field is set. */ + @java.lang.Override public boolean hasTransform() { return operationCase_ == 6; } @@ -1329,6 +1347,7 @@ public boolean hasTransform() { * * @return The transform. */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransform getTransform() { if (transformBuilder_ == null) { if (operationCase_ == 6) { @@ -1479,6 +1498,7 @@ public com.google.firestore.v1beta1.DocumentTransform.Builder getTransformBuilde * * .google.firestore.v1beta1.DocumentTransform transform = 6; */ + @java.lang.Override public com.google.firestore.v1beta1.DocumentTransformOrBuilder getTransformOrBuilder() { if ((operationCase_ == 6) && (transformBuilder_ != null)) { return transformBuilder_.getMessageOrBuilder(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteProto.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteProto.java index 3c3b9afdc..670abe3b1 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteProto.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteProto.java @@ -109,12 +109,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020\n\010document\030\001 \001(\t\022\032\n\022removed_target_ids\030" + "\002 \003(\005\022-\n\tread_time\030\004 \001(\0132\032.google.protob" + "uf.Timestamp\"3\n\017ExistenceFilter\022\021\n\ttarge" - + "t_id\030\001 \001(\005\022\r\n\005count\030\002 \001(\005B\270\001\n\034com.google" + + "t_id\030\001 \001(\005\022\r\n\005count\030\002 \001(\005B\334\001\n\034com.google" + ".firestore.v1beta1B\nWriteProtoP\001ZAgoogle" + ".golang.org/genproto/googleapis/firestor" + "e/v1beta1;firestore\242\002\004GCFS\252\002\036Google.Clou" + "d.Firestore.V1Beta1\312\002\036Google\\Cloud\\Fires" - + "tore\\V1beta1b\006proto3" + + "tore\\V1beta1\352\002!Google::Cloud::Firestore:" + + ":V1beta1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteRequest.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteRequest.java index 60ddd6634..7c4d7fcea 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteRequest.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteRequest.java @@ -186,6 +186,7 @@ protected com.google.protobuf.MapField internalGetMapField(int number) { * * @return The database. */ + @java.lang.Override public java.lang.String getDatabase() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -210,6 +211,7 @@ public java.lang.String getDatabase() { * * @return The bytes for database. */ + @java.lang.Override public com.google.protobuf.ByteString getDatabaseBytes() { java.lang.Object ref = database_; if (ref instanceof java.lang.String) { @@ -237,6 +239,7 @@ public com.google.protobuf.ByteString getDatabaseBytes() { * * @return The streamId. */ + @java.lang.Override public java.lang.String getStreamId() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -261,6 +264,7 @@ public java.lang.String getStreamId() { * * @return The bytes for streamId. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamIdBytes() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -288,6 +292,7 @@ public com.google.protobuf.ByteString getStreamIdBytes() { * * repeated .google.firestore.v1beta1.Write writes = 3; */ + @java.lang.Override public java.util.List getWritesList() { return writes_; } @@ -304,6 +309,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1beta1.Write writes = 3; */ + @java.lang.Override public java.util.List getWritesOrBuilderList() { return writes_; @@ -321,6 +327,7 @@ public java.util.List getWritesList() { * * repeated .google.firestore.v1beta1.Write writes = 3; */ + @java.lang.Override public int getWritesCount() { return writes_.size(); } @@ -337,6 +344,7 @@ public int getWritesCount() { * * repeated .google.firestore.v1beta1.Write writes = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.Write getWrites(int index) { return writes_.get(index); } @@ -353,6 +361,7 @@ public com.google.firestore.v1beta1.Write getWrites(int index) { * * repeated .google.firestore.v1beta1.Write writes = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteOrBuilder getWritesOrBuilder(int index) { return writes_.get(index); } @@ -379,6 +388,7 @@ public com.google.firestore.v1beta1.WriteOrBuilder getWritesOrBuilder(int index) * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -417,6 +427,7 @@ public int getLabelsCount() { * * map<string, string> labels = 5; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -424,6 +435,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -437,6 +449,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -449,6 +462,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { if (key == null) { throw new java.lang.NullPointerException(); @@ -465,6 +479,7 @@ public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.Strin * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1601,6 +1616,7 @@ public java.util.List getWritesBuild * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -1695,6 +1711,7 @@ public int getLabelsCount() { * * map<string, string> labels = 5; */ + @java.lang.Override public boolean containsLabels(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); @@ -1702,6 +1719,7 @@ public boolean containsLabels(java.lang.String key) { return internalGetLabels().getMap().containsKey(key); } /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); @@ -1715,6 +1733,7 @@ public java.util.Map getLabels() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } @@ -1727,6 +1746,7 @@ public java.util.Map getLabelsMap() { * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue) { if (key == null) { @@ -1744,6 +1764,7 @@ public java.lang.String getLabelsOrDefault( * * map<string, string> labels = 5; */ + @java.lang.Override public java.lang.String getLabelsOrThrow(java.lang.String key) { if (key == null) { throw new java.lang.NullPointerException(); diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResponse.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResponse.java index 4f3cf6dff..b41cca0b1 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResponse.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResponse.java @@ -162,6 +162,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return The streamId. */ + @java.lang.Override public java.lang.String getStreamId() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -185,6 +186,7 @@ public java.lang.String getStreamId() { * * @return The bytes for streamId. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamIdBytes() { java.lang.Object ref = streamId_; if (ref instanceof java.lang.String) { @@ -212,6 +214,7 @@ public com.google.protobuf.ByteString getStreamIdBytes() { * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } @@ -229,6 +232,7 @@ public com.google.protobuf.ByteString getStreamToken() { * * repeated .google.firestore.v1beta1.WriteResult write_results = 3; */ + @java.lang.Override public java.util.List getWriteResultsList() { return writeResults_; } @@ -243,6 +247,7 @@ public java.util.List getWriteResultsL * * repeated .google.firestore.v1beta1.WriteResult write_results = 3; */ + @java.lang.Override public java.util.List getWriteResultsOrBuilderList() { return writeResults_; @@ -258,6 +263,7 @@ public java.util.List getWriteResultsL * * repeated .google.firestore.v1beta1.WriteResult write_results = 3; */ + @java.lang.Override public int getWriteResultsCount() { return writeResults_.size(); } @@ -272,6 +278,7 @@ public int getWriteResultsCount() { * * repeated .google.firestore.v1beta1.WriteResult write_results = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteResult getWriteResults(int index) { return writeResults_.get(index); } @@ -286,6 +293,7 @@ public com.google.firestore.v1beta1.WriteResult getWriteResults(int index) { * * repeated .google.firestore.v1beta1.WriteResult write_results = 3; */ + @java.lang.Override public com.google.firestore.v1beta1.WriteResultOrBuilder getWriteResultsOrBuilder(int index) { return writeResults_.get(index); } @@ -303,6 +311,7 @@ public com.google.firestore.v1beta1.WriteResultOrBuilder getWriteResultsOrBuilde * * @return Whether the commitTime field is set. */ + @java.lang.Override public boolean hasCommitTime() { return commitTime_ != null; } @@ -317,6 +326,7 @@ public boolean hasCommitTime() { * * @return The commitTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getCommitTime() { return commitTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : commitTime_; } @@ -329,6 +339,7 @@ public com.google.protobuf.Timestamp getCommitTime() { * * .google.protobuf.Timestamp commit_time = 4; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCommitTimeOrBuilder() { return getCommitTime(); } @@ -875,6 +886,7 @@ public Builder setStreamIdBytes(com.google.protobuf.ByteString value) { * * @return The streamToken. */ + @java.lang.Override public com.google.protobuf.ByteString getStreamToken() { return streamToken_; } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResult.java b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResult.java index 61db7ea7b..662912c7e 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResult.java +++ b/proto-google-cloud-firestore-v1beta1/src/main/java/com/google/firestore/v1beta1/WriteResult.java @@ -150,6 +150,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * @return Whether the updateTime field is set. */ + @java.lang.Override public boolean hasUpdateTime() { return updateTime_ != null; } @@ -167,6 +168,7 @@ public boolean hasUpdateTime() { * * @return The updateTime. */ + @java.lang.Override public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } @@ -182,6 +184,7 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * .google.protobuf.Timestamp update_time = 1; */ + @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return getUpdateTime(); } @@ -198,6 +201,7 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { * * repeated .google.firestore.v1beta1.Value transform_results = 2; */ + @java.lang.Override public java.util.List getTransformResultsList() { return transformResults_; } @@ -211,6 +215,7 @@ public java.util.List getTransformResultsLis * * repeated .google.firestore.v1beta1.Value transform_results = 2; */ + @java.lang.Override public java.util.List getTransformResultsOrBuilderList() { return transformResults_; @@ -225,6 +230,7 @@ public java.util.List getTransformResultsLis * * repeated .google.firestore.v1beta1.Value transform_results = 2; */ + @java.lang.Override public int getTransformResultsCount() { return transformResults_.size(); } @@ -238,6 +244,7 @@ public int getTransformResultsCount() { * * repeated .google.firestore.v1beta1.Value transform_results = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.Value getTransformResults(int index) { return transformResults_.get(index); } @@ -251,6 +258,7 @@ public com.google.firestore.v1beta1.Value getTransformResults(int index) { * * repeated .google.firestore.v1beta1.Value transform_results = 2; */ + @java.lang.Override public com.google.firestore.v1beta1.ValueOrBuilder getTransformResultsOrBuilder(int index) { return transformResults_.get(index); } diff --git a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/common.proto b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/common.proto index 2eaa18347..b71a2e32e 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/common.proto +++ b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/common.proto @@ -27,6 +27,7 @@ option java_outer_classname = "CommonProto"; option java_package = "com.google.firestore.v1beta1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1beta1"; +option ruby_package = "Google::Cloud::Firestore::V1beta1"; // A set of field paths on a document. // Used to restrict a get or update operation on a document to a subset of its diff --git a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/document.proto b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/document.proto index 7caae4688..38d81af96 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/document.proto +++ b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/document.proto @@ -29,6 +29,7 @@ option java_outer_classname = "DocumentProto"; option java_package = "com.google.firestore.v1beta1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1beta1"; +option ruby_package = "Google::Cloud::Firestore::V1beta1"; // A Firestore document. // diff --git a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/firestore.proto b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/firestore.proto index c2b15b048..5cdccb7ea 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/firestore.proto +++ b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/firestore.proto @@ -35,6 +35,7 @@ option java_outer_classname = "FirestoreProto"; option java_package = "com.google.firestore.v1beta1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1beta1"; +option ruby_package = "Google::Cloud::Firestore::V1beta1"; // Specification of the Firestore API. diff --git a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/query.proto b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/query.proto index 4f515fabe..5f9c3ab93 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/query.proto +++ b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/query.proto @@ -28,6 +28,7 @@ option java_outer_classname = "QueryProto"; option java_package = "com.google.firestore.v1beta1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1beta1"; +option ruby_package = "Google::Cloud::Firestore::V1beta1"; // A Firestore query. message StructuredQuery { diff --git a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/write.proto b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/write.proto index c02a2a8a1..ba75b42a0 100644 --- a/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/write.proto +++ b/proto-google-cloud-firestore-v1beta1/src/main/proto/google/firestore/v1beta1/write.proto @@ -29,6 +29,7 @@ option java_outer_classname = "WriteProto"; option java_package = "com.google.firestore.v1beta1"; option objc_class_prefix = "GCFS"; option php_namespace = "Google\\Cloud\\Firestore\\V1beta1"; +option ruby_package = "Google::Cloud::Firestore::V1beta1"; // A write on a document. message Write { diff --git a/renovate.json b/renovate.json index 337706ab9..a6328c2a7 100644 --- a/renovate.json +++ b/renovate.json @@ -76,5 +76,6 @@ "groupName": "jackson dependencies" } ], - "semanticCommits": true + "semanticCommits": true, + "masterIssue": true } \ No newline at end of file diff --git a/synth.metadata b/synth.metadata index e967bfa0a..d9e737218 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,22 +4,22 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-firestore.git", - "sha": "495f7f97405fcd2bff4d09e67ddbeb51615ea843" + "sha": "03b37056e1ae8f80373e0acc6bff82b9161f2182" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "d741cd976975c745d0199987aff0e908b8352992", - "internalRef": "305561906" + "sha": "cbd6f1d28bc0c461c234f9848bcbc1563126daf9", + "internalRef": "319105199" } }, { "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "52638600f387deb98efb5f9c85fec39e82aa9052" + "sha": "303271797a360f8a439203413f13a160f2f5b3b4" } } ], @@ -52,4 +52,4 @@ } } ] -} +} \ No newline at end of file diff --git a/synth.py b/synth.py index 07e0afb3b..a4f743aa5 100644 --- a/synth.py +++ b/synth.py @@ -126,7 +126,9 @@ def generate_client(service, version, proto_path=None, bazel_target=None, packag # firestore uses a different project for its integration tests # due to the default project running datastore '.kokoro/presubmit/integration.cfg', - '.kokoro/nightly/integration.cfg' + '.kokoro/presubmit/samples.cfg', + '.kokoro/nightly/integration.cfg', + '.kokoro/nightly/samples.cfg' ]) # Mark v1beta1 as deprecated