# frozen_string_literal: true # 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 # # 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. # Auto-generated by gapic-generator-ruby. DO NOT EDIT! module Google module Cloud module Firestore module V1 # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#get_document Firestore.GetDocument}. # @!attribute [rw] name # @return [::String] # Required. The resource name of the Document to get. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # @!attribute [rw] mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to return. If not set, returns all fields. # # If the document has a field that is not present in this mask, that field # will not be returned in the response. # @!attribute [rw] transaction # @return [::String] # Reads the document in a transaction. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # Reads the version of the document at the given time. # This may not be older than 270 seconds. class GetDocumentRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#list_documents Firestore.ListDocuments}. # @!attribute [rw] parent # @return [::String] # Required. The parent resource name. In the format: # `projects/{project_id}/databases/{database_id}/documents` or # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # For example: # `projects/my-project/databases/my-database/documents` or # `projects/my-project/databases/my-database/documents/chatrooms/my-chatroom` # @!attribute [rw] collection_id # @return [::String] # Required. The collection ID, relative to `parent`, to list. For example: `chatrooms` # or `messages`. # @!attribute [rw] page_size # @return [::Integer] # The maximum number of documents to return. # @!attribute [rw] page_token # @return [::String] # The `next_page_token` value returned from a previous List request, if any. # @!attribute [rw] order_by # @return [::String] # The order to sort results by. For example: `priority desc, name`. # @!attribute [rw] mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to return. If not set, returns all fields. # # If a document has a field that is not present in this mask, that field # will not be returned in the response. # @!attribute [rw] transaction # @return [::String] # Reads documents in a transaction. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # Reads documents as they were at the given time. # This may not be older than 270 seconds. # @!attribute [rw] show_missing # @return [::Boolean] # If the list should show missing documents. A missing document is a # document that does not exist but has sub-documents. These documents will # be returned with a key but will not have fields, {::Google::Cloud::Firestore::V1::Document#create_time Document.create_time}, # or {::Google::Cloud::Firestore::V1::Document#update_time Document.update_time} set. # # Requests with `show_missing` may not specify `where` or # `order_by`. class ListDocumentsRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#list_documents Firestore.ListDocuments}. # @!attribute [rw] documents # @return [::Array<::Google::Cloud::Firestore::V1::Document>] # The Documents found. # @!attribute [rw] next_page_token # @return [::String] # The next page token. class ListDocumentsResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#create_document Firestore.CreateDocument}. # @!attribute [rw] parent # @return [::String] # Required. The parent resource. For example: # `projects/{project_id}/databases/{database_id}/documents` or # `projects/{project_id}/databases/{database_id}/documents/chatrooms/{chatroom_id}` # @!attribute [rw] collection_id # @return [::String] # Required. The collection ID, relative to `parent`, to list. For example: `chatrooms`. # @!attribute [rw] document_id # @return [::String] # The client-assigned document ID to use for this document. # # Optional. If not specified, an ID will be assigned by the service. # @!attribute [rw] document # @return [::Google::Cloud::Firestore::V1::Document] # Required. The document to create. `name` must not be set. # @!attribute [rw] mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to return. If not set, returns all fields. # # If the document has a field that is not present in this mask, that field # will not be returned in the response. class CreateDocumentRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#update_document Firestore.UpdateDocument}. # @!attribute [rw] document # @return [::Google::Cloud::Firestore::V1::Document] # Required. The updated document. # Creates the document if it does not already exist. # @!attribute [rw] update_mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to update. # None of the field paths in the mask may contain a reserved name. # # If the document exists on the server and has fields not referenced in the # mask, they are left unchanged. # Fields referenced in the mask, but not present in the input document, are # deleted from the document on the server. # @!attribute [rw] mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to return. If not set, returns all fields. # # If the document has a field that is not present in this mask, that field # will not be returned in the response. # @!attribute [rw] current_document # @return [::Google::Cloud::Firestore::V1::Precondition] # An optional precondition on the document. # The request will fail if this is set and not met by the target document. class UpdateDocumentRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#delete_document Firestore.DeleteDocument}. # @!attribute [rw] name # @return [::String] # Required. The resource name of the Document to delete. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # @!attribute [rw] current_document # @return [::Google::Cloud::Firestore::V1::Precondition] # An optional precondition on the document. # The request will fail if this is set and not met by the target document. class DeleteDocumentRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#batch_get_documents Firestore.BatchGetDocuments}. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] documents # @return [::Array<::String>] # The names of the documents to retrieve. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # The request will fail if any of the document is not a child resource of the # given `database`. Duplicate names will be elided. # @!attribute [rw] mask # @return [::Google::Cloud::Firestore::V1::DocumentMask] # The fields to return. If not set, returns all fields. # # If a document has a field that is not present in this mask, that field will # not be returned in the response. # @!attribute [rw] transaction # @return [::String] # Reads documents in a transaction. # @!attribute [rw] new_transaction # @return [::Google::Cloud::Firestore::V1::TransactionOptions] # Starts a new transaction and reads the documents. # Defaults to a read-only transaction. # The new transaction ID will be returned as the first response in the # stream. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # Reads documents as they were at the given time. # This may not be older than 270 seconds. class BatchGetDocumentsRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The streamed response for {::Google::Cloud::Firestore::V1::Firestore::Client#batch_get_documents Firestore.BatchGetDocuments}. # @!attribute [rw] found # @return [::Google::Cloud::Firestore::V1::Document] # A document that was requested. # @!attribute [rw] missing # @return [::String] # A document name that was requested but does not exist. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # @!attribute [rw] transaction # @return [::String] # The transaction that was started as part of this request. # Will only be set in the first response, and only if # {::Google::Cloud::Firestore::V1::BatchGetDocumentsRequest#new_transaction BatchGetDocumentsRequest.new_transaction} was set in the request. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # The time at which the document was read. # This may be monotically increasing, in this case the previous documents in # the result stream are guaranteed not to have changed between their # read_time and this one. class BatchGetDocumentsResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#begin_transaction Firestore.BeginTransaction}. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] options # @return [::Google::Cloud::Firestore::V1::TransactionOptions] # The options for the transaction. # Defaults to a read-write transaction. class BeginTransactionRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#begin_transaction Firestore.BeginTransaction}. # @!attribute [rw] transaction # @return [::String] # The transaction that was started. class BeginTransactionResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#commit Firestore.Commit}. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] writes # @return [::Array<::Google::Cloud::Firestore::V1::Write>] # The writes to apply. # # Always executed atomically and in order. # @!attribute [rw] transaction # @return [::String] # If set, applies all writes in this transaction, and commits it. class CommitRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#commit Firestore.Commit}. # @!attribute [rw] write_results # @return [::Array<::Google::Cloud::Firestore::V1::WriteResult>] # The result of applying the writes. # # This i-th write result corresponds to the i-th write in the # request. # @!attribute [rw] commit_time # @return [::Google::Protobuf::Timestamp] # The time at which the commit occurred. Any read with an equal or greater # `read_time` is guaranteed to see the effects of the commit. class CommitResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#rollback Firestore.Rollback}. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] transaction # @return [::String] # Required. The transaction to roll back. class RollbackRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#run_query Firestore.RunQuery}. # @!attribute [rw] parent # @return [::String] # Required. The parent resource name. In the format: # `projects/{project_id}/databases/{database_id}/documents` or # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # For example: # `projects/my-project/databases/my-database/documents` or # `projects/my-project/databases/my-database/documents/chatrooms/my-chatroom` # @!attribute [rw] structured_query # @return [::Google::Cloud::Firestore::V1::StructuredQuery] # A structured query. # @!attribute [rw] transaction # @return [::String] # Reads documents in a transaction. # @!attribute [rw] new_transaction # @return [::Google::Cloud::Firestore::V1::TransactionOptions] # Starts a new transaction and reads the documents. # Defaults to a read-only transaction. # The new transaction ID will be returned as the first response in the # stream. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # Reads documents as they were at the given time. # This may not be older than 270 seconds. class RunQueryRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#run_query Firestore.RunQuery}. # @!attribute [rw] transaction # @return [::String] # The transaction that was started as part of this request. # Can only be set in the first response, and only if # {::Google::Cloud::Firestore::V1::RunQueryRequest#new_transaction RunQueryRequest.new_transaction} was set in the request. # If set, no other fields will be set in this response. # @!attribute [rw] document # @return [::Google::Cloud::Firestore::V1::Document] # A query result. # Not set when reporting partial progress. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # The time at which the document was read. This may be monotonically # increasing; in this case, the previous documents in the result stream are # guaranteed not to have changed between their `read_time` and this one. # # If the query returns no results, a response with `read_time` and no # `document` will be sent, and this represents the time at which the query # was run. # @!attribute [rw] skipped_results # @return [::Integer] # The number of results that have been skipped due to an offset between # the last response and the current response. class RunQueryResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#partition_query Firestore.PartitionQuery}. # @!attribute [rw] parent # @return [::String] # 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. # @!attribute [rw] structured_query # @return [::Google::Cloud::Firestore::V1::StructuredQuery] # A structured query. # Query must specify collection with all descendants and be ordered by name # ascending. Other filters, order bys, limits, offsets, and start/end # cursors are not supported. # @!attribute [rw] partition_count # @return [::Integer] # The desired maximum number of partition points. # The partitions may be returned across multiple pages of results. # The number must be 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. # @!attribute [rw] page_token # @return [::String] # 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 # @!attribute [rw] page_size # @return [::Integer] # 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`. class PartitionQueryRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#partition_query Firestore.PartitionQuery}. # @!attribute [rw] partitions # @return [::Array<::Google::Cloud::Firestore::V1::Cursor>] # 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 # # An empty result may indicate that the query has too few results to be # partitioned. # @!attribute [rw] next_page_token # @return [::String] # 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. class PartitionQueryResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#write Firestore.Write}. # # The first request creates a stream, or resumes an existing one from a token. # # When creating a new stream, the server replies with a response containing # only an ID and a token, to use in the next request. # # When resuming a stream, the server first streams any responses later than the # given token, then a response containing only an up-to-date token, to use in # the next request. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # This is only required in the first message. # @!attribute [rw] stream_id # @return [::String] # The ID of the write stream to resume. # This may only be set in the first message. When left empty, a new write # stream will be created. # @!attribute [rw] writes # @return [::Array<::Google::Cloud::Firestore::V1::Write>] # The writes to apply. # # Always executed atomically and in order. # This must be empty on the first request. # This may be empty on the last request. # This must not be empty on all other requests. # @!attribute [rw] stream_token # @return [::String] # A stream token that was previously sent by the server. # # The client should set this field to the token from the most recent # {::Google::Cloud::Firestore::V1::WriteResponse WriteResponse} it has received. This acknowledges that the client has # received responses up to this token. After sending this token, earlier # tokens may not be used anymore. # # The server may close the stream if there are too many unacknowledged # responses. # # Leave this field unset when creating a new stream. To resume a stream at # a specific point, set this field and the `stream_id` field. # # Leave this field unset when creating a new stream. # @!attribute [rw] labels # @return [::Google::Protobuf::Map{::String => ::String}] # Labels associated with this write request. class WriteRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#write Firestore.Write}. # @!attribute [rw] stream_id # @return [::String] # The ID of the stream. # Only set on the first message, when a new stream was created. # @!attribute [rw] stream_token # @return [::String] # A token that represents the position of this response in the stream. # This can be used by a client to resume the stream at this point. # # This field is always set. # @!attribute [rw] write_results # @return [::Array<::Google::Cloud::Firestore::V1::WriteResult>] # The result of applying the writes. # # This i-th write result corresponds to the i-th write in the # request. # @!attribute [rw] commit_time # @return [::Google::Protobuf::Timestamp] # The time at which the commit occurred. Any read with an equal or greater # `read_time` is guaranteed to see the effects of the write. class WriteResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # A request for {::Google::Cloud::Firestore::V1::Firestore::Client#listen Firestore.Listen} # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] add_target # @return [::Google::Cloud::Firestore::V1::Target] # A target to add to this stream. # @!attribute [rw] remove_target # @return [::Integer] # The ID of a target to remove from this stream. # @!attribute [rw] labels # @return [::Google::Protobuf::Map{::String => ::String}] # Labels associated with this target change. class ListenRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # The response for {::Google::Cloud::Firestore::V1::Firestore::Client#listen Firestore.Listen}. # @!attribute [rw] target_change # @return [::Google::Cloud::Firestore::V1::TargetChange] # Targets have changed. # @!attribute [rw] document_change # @return [::Google::Cloud::Firestore::V1::DocumentChange] # A {::Google::Cloud::Firestore::V1::Document Document} has changed. # @!attribute [rw] document_delete # @return [::Google::Cloud::Firestore::V1::DocumentDelete] # A {::Google::Cloud::Firestore::V1::Document Document} has been deleted. # @!attribute [rw] document_remove # @return [::Google::Cloud::Firestore::V1::DocumentRemove] # A {::Google::Cloud::Firestore::V1::Document Document} has been removed from a target (because it is no longer # relevant to that target). # @!attribute [rw] filter # @return [::Google::Cloud::Firestore::V1::ExistenceFilter] # A filter to apply to the set of documents previously returned for the # given target. # # Returned when documents may have been removed from the given target, but # the exact documents are unknown. class ListenResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # A specification of a set of documents to listen to. # @!attribute [rw] query # @return [::Google::Cloud::Firestore::V1::Target::QueryTarget] # A target specified by a query. # @!attribute [rw] documents # @return [::Google::Cloud::Firestore::V1::Target::DocumentsTarget] # A target specified by a set of document names. # @!attribute [rw] resume_token # @return [::String] # A resume token from a prior {::Google::Cloud::Firestore::V1::TargetChange TargetChange} for an identical target. # # Using a resume token with a different target is unsupported and may fail. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # Start listening after a specific `read_time`. # # The client must know the state of matching documents at this time. # @!attribute [rw] target_id # @return [::Integer] # The target ID that identifies the target on the stream. Must be a positive # number and non-zero. # @!attribute [rw] once # @return [::Boolean] # If the target should be removed once it is current and consistent. class Target include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # A target specified by a set of documents names. # @!attribute [rw] documents # @return [::Array<::String>] # The names of the documents to retrieve. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # The request will fail if any of the document is not a child resource of # the given `database`. Duplicate names will be elided. class DocumentsTarget include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # A target specified by a query. # @!attribute [rw] parent # @return [::String] # The parent resource name. In the format: # `projects/{project_id}/databases/{database_id}/documents` or # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # For example: # `projects/my-project/databases/my-database/documents` or # `projects/my-project/databases/my-database/documents/chatrooms/my-chatroom` # @!attribute [rw] structured_query # @return [::Google::Cloud::Firestore::V1::StructuredQuery] # A structured query. class QueryTarget include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Targets being watched have changed. # @!attribute [rw] target_change_type # @return [::Google::Cloud::Firestore::V1::TargetChange::TargetChangeType] # The type of change that occurred. # @!attribute [rw] target_ids # @return [::Array<::Integer>] # The target IDs of targets that have changed. # # If empty, the change applies to all targets. # # The order of the target IDs is not defined. # @!attribute [rw] cause # @return [::Google::Rpc::Status] # The error that resulted in this change, if applicable. # @!attribute [rw] resume_token # @return [::String] # A token that can be used to resume the stream for the given `target_ids`, # or all targets if `target_ids` is empty. # # Not set on every target change. # @!attribute [rw] read_time # @return [::Google::Protobuf::Timestamp] # The consistent `read_time` for the given `target_ids` (omitted when the # target_ids are not at a consistent snapshot). # # The stream is guaranteed to send a `read_time` with `target_ids` empty # whenever the entire stream reaches a new consistent snapshot. ADD, # CURRENT, and RESET messages are guaranteed to (eventually) result in a # new consistent snapshot (while NO_CHANGE and REMOVE messages are not). # # For a given stream, `read_time` is guaranteed to be monotonically # increasing. class TargetChange include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The type of change. module TargetChangeType # No change has occurred. Used only to send an updated `resume_token`. NO_CHANGE = 0 # The targets have been added. ADD = 1 # The targets have been removed. REMOVE = 2 # The targets reflect all changes committed before the targets were added # to the stream. # # This will be sent after or with a `read_time` that is greater than or # equal to the time at which the targets were added. # # Listeners can wait for this change if read-after-write semantics # are desired. CURRENT = 3 # The targets have been reset, and a new initial state for the targets # will be returned in subsequent changes. # # After the initial state is complete, `CURRENT` will be returned even # if the target was previously indicated to be `CURRENT`. RESET = 4 end end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#list_collection_ids Firestore.ListCollectionIds}. # @!attribute [rw] parent # @return [::String] # Required. The parent document. In the format: # `projects/{project_id}/databases/{database_id}/documents/{document_path}`. # For example: # `projects/my-project/databases/my-database/documents/chatrooms/my-chatroom` # @!attribute [rw] page_size # @return [::Integer] # The maximum number of results to return. # @!attribute [rw] page_token # @return [::String] # A page token. Must be a value from # {::Google::Cloud::Firestore::V1::ListCollectionIdsResponse ListCollectionIdsResponse}. class ListCollectionIdsRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The response from {::Google::Cloud::Firestore::V1::Firestore::Client#list_collection_ids Firestore.ListCollectionIds}. # @!attribute [rw] collection_ids # @return [::Array<::String>] # The collection ids. # @!attribute [rw] next_page_token # @return [::String] # A page token that may be used to continue the list. class ListCollectionIdsResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The request for {::Google::Cloud::Firestore::V1::Firestore::Client#batch_write Firestore.BatchWrite}. # @!attribute [rw] database # @return [::String] # Required. The database name. In the format: # `projects/{project_id}/databases/{database_id}`. # @!attribute [rw] writes # @return [::Array<::Google::Cloud::Firestore::V1::Write>] # 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. # @!attribute [rw] labels # @return [::Google::Protobuf::Map{::String => ::String}] # Labels associated with this batch write. class BatchWriteRequest include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] key # @return [::String] # @!attribute [rw] value # @return [::String] class LabelsEntry include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # The response from {::Google::Cloud::Firestore::V1::Firestore::Client#batch_write Firestore.BatchWrite}. # @!attribute [rw] write_results # @return [::Array<::Google::Cloud::Firestore::V1::WriteResult>] # The result of applying the writes. # # This i-th write result corresponds to the i-th write in the # request. # @!attribute [rw] status # @return [::Array<::Google::Rpc::Status>] # The status of applying the writes. # # This i-th write status corresponds to the i-th write in the # request. class BatchWriteResponse include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end end