/* * Copyright 2018 Google * * 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. */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/firestore/v1/write.proto #include "google/firestore/v1/write.pb.h" #include #include #include #include #include #include #include #include #include #include // This is a temporary google only hack #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS #include "third_party/protobuf/version.h" #endif // @@protoc_insertion_point(includes) namespace google { namespace firestore { namespace v1 { class WriteDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; const ::google::firestore::v1::Document* update_; ::google::protobuf::internal::ArenaStringPtr delete__; const ::google::firestore::v1::DocumentTransform* transform_; } _Write_default_instance_; class DocumentTransform_FieldTransformDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; int set_to_server_value_; const ::google::firestore::v1::Value* increment_; const ::google::firestore::v1::Value* maximum_; const ::google::firestore::v1::Value* minimum_; const ::google::firestore::v1::ArrayValue* append_missing_elements_; const ::google::firestore::v1::ArrayValue* remove_all_from_array_; } _DocumentTransform_FieldTransform_default_instance_; class DocumentTransformDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _DocumentTransform_default_instance_; class WriteResultDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _WriteResult_default_instance_; class DocumentChangeDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _DocumentChange_default_instance_; class DocumentDeleteDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _DocumentDelete_default_instance_; class DocumentRemoveDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _DocumentRemove_default_instance_; class ExistenceFilterDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _ExistenceFilter_default_instance_; } // namespace v1 } // namespace firestore } // namespace google namespace protobuf_google_2ffirestore_2fv1_2fwrite_2eproto { void InitDefaultsWriteImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2ffirestore_2fv1_2fdocument_2eproto::InitDefaultsDocument(); protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform(); protobuf_google_2ffirestore_2fv1_2fcommon_2eproto::InitDefaultsDocumentMask(); protobuf_google_2ffirestore_2fv1_2fcommon_2eproto::InitDefaultsPrecondition(); { void* ptr = &::google::firestore::v1::_Write_default_instance_; new (ptr) ::google::firestore::v1::Write(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::Write::InitAsDefaultInstance(); } void InitDefaultsWrite() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsWriteImpl); } void InitDefaultsDocumentTransform_FieldTransformImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2ffirestore_2fv1_2fdocument_2eproto::InitDefaultsArrayValue(); { void* ptr = &::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_; new (ptr) ::google::firestore::v1::DocumentTransform_FieldTransform(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::DocumentTransform_FieldTransform::InitAsDefaultInstance(); } void InitDefaultsDocumentTransform_FieldTransform() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDocumentTransform_FieldTransformImpl); } void InitDefaultsDocumentTransformImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform_FieldTransform(); { void* ptr = &::google::firestore::v1::_DocumentTransform_default_instance_; new (ptr) ::google::firestore::v1::DocumentTransform(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::DocumentTransform::InitAsDefaultInstance(); } void InitDefaultsDocumentTransform() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDocumentTransformImpl); } void InitDefaultsWriteResultImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); protobuf_google_2ffirestore_2fv1_2fdocument_2eproto::InitDefaultsArrayValue(); { void* ptr = &::google::firestore::v1::_WriteResult_default_instance_; new (ptr) ::google::firestore::v1::WriteResult(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::WriteResult::InitAsDefaultInstance(); } void InitDefaultsWriteResult() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsWriteResultImpl); } void InitDefaultsDocumentChangeImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2ffirestore_2fv1_2fdocument_2eproto::InitDefaultsDocument(); { void* ptr = &::google::firestore::v1::_DocumentChange_default_instance_; new (ptr) ::google::firestore::v1::DocumentChange(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::DocumentChange::InitAsDefaultInstance(); } void InitDefaultsDocumentChange() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDocumentChangeImpl); } void InitDefaultsDocumentDeleteImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); { void* ptr = &::google::firestore::v1::_DocumentDelete_default_instance_; new (ptr) ::google::firestore::v1::DocumentDelete(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::DocumentDelete::InitAsDefaultInstance(); } void InitDefaultsDocumentDelete() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDocumentDeleteImpl); } void InitDefaultsDocumentRemoveImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); { void* ptr = &::google::firestore::v1::_DocumentRemove_default_instance_; new (ptr) ::google::firestore::v1::DocumentRemove(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::DocumentRemove::InitAsDefaultInstance(); } void InitDefaultsDocumentRemove() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDocumentRemoveImpl); } void InitDefaultsExistenceFilterImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; #ifdef GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS ::google::protobuf::internal::InitProtobufDefaultsForceUnique(); #else ::google::protobuf::internal::InitProtobufDefaults(); #endif // GOOGLE_PROTOBUF_ENFORCE_UNIQUENESS { void* ptr = &::google::firestore::v1::_ExistenceFilter_default_instance_; new (ptr) ::google::firestore::v1::ExistenceFilter(); ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); } ::google::firestore::v1::ExistenceFilter::InitAsDefaultInstance(); } void InitDefaultsExistenceFilter() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsExistenceFilterImpl); } ::google::protobuf::Metadata file_level_metadata[8]; const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1]; const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::Write, _internal_metadata_), ~0u, // no _extensions_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::Write, _oneof_case_[0]), ~0u, // no _weak_field_map_ offsetof(::google::firestore::v1::WriteDefaultTypeInternal, update_), offsetof(::google::firestore::v1::WriteDefaultTypeInternal, delete__), offsetof(::google::firestore::v1::WriteDefaultTypeInternal, transform_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::Write, update_mask_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::Write, current_document_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::Write, operation_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform_FieldTransform, _internal_metadata_), ~0u, // no _extensions_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform_FieldTransform, _oneof_case_[0]), ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform_FieldTransform, field_path_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, set_to_server_value_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, increment_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, maximum_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, minimum_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, append_missing_elements_), offsetof(::google::firestore::v1::DocumentTransform_FieldTransformDefaultTypeInternal, remove_all_from_array_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform_FieldTransform, transform_type_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform, document_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentTransform, field_transforms_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::WriteResult, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::WriteResult, update_time_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::WriteResult, transform_results_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentChange, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentChange, document_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentChange, target_ids_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentChange, removed_target_ids_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentDelete, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentDelete, document_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentDelete, removed_target_ids_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentDelete, read_time_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentRemove, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentRemove, document_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentRemove, removed_target_ids_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::DocumentRemove, read_time_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::ExistenceFilter, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::ExistenceFilter, target_id_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::firestore::v1::ExistenceFilter, count_), }; static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { { 0, -1, sizeof(::google::firestore::v1::Write)}, { 11, -1, sizeof(::google::firestore::v1::DocumentTransform_FieldTransform)}, { 24, -1, sizeof(::google::firestore::v1::DocumentTransform)}, { 31, -1, sizeof(::google::firestore::v1::WriteResult)}, { 38, -1, sizeof(::google::firestore::v1::DocumentChange)}, { 46, -1, sizeof(::google::firestore::v1::DocumentDelete)}, { 54, -1, sizeof(::google::firestore::v1::DocumentRemove)}, { 62, -1, sizeof(::google::firestore::v1::ExistenceFilter)}, }; static ::google::protobuf::Message const * const file_default_instances[] = { reinterpret_cast(&::google::firestore::v1::_Write_default_instance_), reinterpret_cast(&::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_), reinterpret_cast(&::google::firestore::v1::_DocumentTransform_default_instance_), reinterpret_cast(&::google::firestore::v1::_WriteResult_default_instance_), reinterpret_cast(&::google::firestore::v1::_DocumentChange_default_instance_), reinterpret_cast(&::google::firestore::v1::_DocumentDelete_default_instance_), reinterpret_cast(&::google::firestore::v1::_DocumentRemove_default_instance_), reinterpret_cast(&::google::firestore::v1::_ExistenceFilter_default_instance_), }; void protobuf_AssignDescriptors() { AddDescriptors(); ::google::protobuf::MessageFactory* factory = NULL; AssignDescriptors( "google/firestore/v1/write.proto", schemas, file_default_instances, TableStruct::offsets, factory, file_level_metadata, file_level_enum_descriptors, NULL); } void protobuf_AssignDescriptorsOnce() { static GOOGLE_PROTOBUF_DECLARE_ONCE(once); ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors); } void protobuf_RegisterTypes(const ::std::string&) GOOGLE_PROTOBUF_ATTRIBUTE_COLD; void protobuf_RegisterTypes(const ::std::string&) { protobuf_AssignDescriptorsOnce(); ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 8); } void AddDescriptorsImpl() { InitDefaults(); static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { "\n\037google/firestore/v1/write.proto\022\023googl" "e.firestore.v1\032\034google/api/annotations.p" "roto\032 google/firestore/v1/common.proto\032\"" "google/firestore/v1/document.proto\032\037goog" "le/protobuf/timestamp.proto\"\211\002\n\005Write\022/\n" "\006update\030\001 \001(\0132\035.google.firestore.v1.Docu" "mentH\000\022\020\n\006delete\030\002 \001(\tH\000\022;\n\ttransform\030\006 " "\001(\0132&.google.firestore.v1.DocumentTransf" "ormH\000\0226\n\013update_mask\030\003 \001(\0132!.google.fire" "store.v1.DocumentMask\022;\n\020current_documen" "t\030\004 \001(\0132!.google.firestore.v1.Preconditi" "onB\013\n\toperation\"\345\004\n\021DocumentTransform\022\020\n" "\010document\030\001 \001(\t\022O\n\020field_transforms\030\002 \003(" "\01325.google.firestore.v1.DocumentTransfor" "m.FieldTransform\032\354\003\n\016FieldTransform\022\022\n\nf" "ield_path\030\001 \001(\t\022`\n\023set_to_server_value\030\002" " \001(\0162A.google.firestore.v1.DocumentTrans" "form.FieldTransform.ServerValueH\000\022/\n\tinc" "rement\030\003 \001(\0132\032.google.firestore.v1.Value" "H\000\022-\n\007maximum\030\004 \001(\0132\032.google.firestore.v" "1.ValueH\000\022-\n\007minimum\030\005 \001(\0132\032.google.fire" "store.v1.ValueH\000\022B\n\027append_missing_eleme" "nts\030\006 \001(\0132\037.google.firestore.v1.ArrayVal" "ueH\000\022@\n\025remove_all_from_array\030\007 \001(\0132\037.go" "ogle.firestore.v1.ArrayValueH\000\"=\n\013Server" "Value\022\034\n\030SERVER_VALUE_UNSPECIFIED\020\000\022\020\n\014R" "EQUEST_TIME\020\001B\020\n\016transform_type\"u\n\013Write" "Result\022/\n\013update_time\030\001 \001(\0132\032.google.pro" "tobuf.Timestamp\0225\n\021transform_results\030\002 \003" "(\0132\032.google.firestore.v1.Value\"q\n\016Docume" "ntChange\022/\n\010document\030\001 \001(\0132\035.google.fire" "store.v1.Document\022\022\n\ntarget_ids\030\005 \003(\005\022\032\n" "\022removed_target_ids\030\006 \003(\005\"m\n\016DocumentDel" "ete\022\020\n\010document\030\001 \001(\t\022\032\n\022removed_target_" "ids\030\006 \003(\005\022-\n\tread_time\030\004 \001(\0132\032.google.pr" "otobuf.Timestamp\"m\n\016DocumentRemove\022\020\n\010do" "cument\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.Ti" "mestamp\"3\n\017ExistenceFilter\022\021\n\ttarget_id\030" "\001 \001(\005\022\r\n\005count\030\002 \001(\005B\256\001\n\027com.google.fire" "store.v1B\nWriteProtoP\001Z= 1900 const DocumentTransform_FieldTransform_ServerValue DocumentTransform_FieldTransform::SERVER_VALUE_UNSPECIFIED; const DocumentTransform_FieldTransform_ServerValue DocumentTransform_FieldTransform::REQUEST_TIME; const DocumentTransform_FieldTransform_ServerValue DocumentTransform_FieldTransform::ServerValue_MIN; const DocumentTransform_FieldTransform_ServerValue DocumentTransform_FieldTransform::ServerValue_MAX; const int DocumentTransform_FieldTransform::ServerValue_ARRAYSIZE; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 // =================================================================== void Write::InitAsDefaultInstance() { ::google::firestore::v1::_Write_default_instance_.update_ = const_cast< ::google::firestore::v1::Document*>( ::google::firestore::v1::Document::internal_default_instance()); ::google::firestore::v1::_Write_default_instance_.delete__.UnsafeSetDefault( &::google::protobuf::internal::GetEmptyStringAlreadyInited()); ::google::firestore::v1::_Write_default_instance_.transform_ = const_cast< ::google::firestore::v1::DocumentTransform*>( ::google::firestore::v1::DocumentTransform::internal_default_instance()); ::google::firestore::v1::_Write_default_instance_._instance.get_mutable()->update_mask_ = const_cast< ::google::firestore::v1::DocumentMask*>( ::google::firestore::v1::DocumentMask::internal_default_instance()); ::google::firestore::v1::_Write_default_instance_._instance.get_mutable()->current_document_ = const_cast< ::google::firestore::v1::Precondition*>( ::google::firestore::v1::Precondition::internal_default_instance()); } void Write::set_allocated_update(::google::firestore::v1::Document* update) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_operation(); if (update) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { update = ::google::protobuf::internal::GetOwnedMessage( message_arena, update, submessage_arena); } set_has_update(); operation_.update_ = update; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.Write.update) } void Write::clear_update() { if (has_update()) { delete operation_.update_; clear_has_operation(); } } void Write::set_allocated_transform(::google::firestore::v1::DocumentTransform* transform) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_operation(); if (transform) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { transform = ::google::protobuf::internal::GetOwnedMessage( message_arena, transform, submessage_arena); } set_has_transform(); operation_.transform_ = transform; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.Write.transform) } void Write::clear_update_mask() { if (GetArenaNoVirtual() == NULL && update_mask_ != NULL) { delete update_mask_; } update_mask_ = NULL; } void Write::clear_current_document() { if (GetArenaNoVirtual() == NULL && current_document_ != NULL) { delete current_document_; } current_document_ = NULL; } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int Write::kUpdateFieldNumber; const int Write::kDeleteFieldNumber; const int Write::kTransformFieldNumber; const int Write::kUpdateMaskFieldNumber; const int Write::kCurrentDocumentFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 Write::Write() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsWrite(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.Write) } Write::Write(const Write& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); if (from.has_update_mask()) { update_mask_ = new ::google::firestore::v1::DocumentMask(*from.update_mask_); } else { update_mask_ = NULL; } if (from.has_current_document()) { current_document_ = new ::google::firestore::v1::Precondition(*from.current_document_); } else { current_document_ = NULL; } clear_has_operation(); switch (from.operation_case()) { case kUpdate: { mutable_update()->::google::firestore::v1::Document::MergeFrom(from.update()); break; } case kDelete: { set_delete_(from.delete_()); break; } case kTransform: { mutable_transform()->::google::firestore::v1::DocumentTransform::MergeFrom(from.transform()); break; } case OPERATION_NOT_SET: { break; } } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.Write) } void Write::SharedCtor() { ::memset(&update_mask_, 0, static_cast( reinterpret_cast(¤t_document_) - reinterpret_cast(&update_mask_)) + sizeof(current_document_)); clear_has_operation(); _cached_size_ = 0; } Write::~Write() { // @@protoc_insertion_point(destructor:google.firestore.v1.Write) SharedDtor(); } void Write::SharedDtor() { if (this != internal_default_instance()) delete update_mask_; if (this != internal_default_instance()) delete current_document_; if (has_operation()) { clear_operation(); } } void Write::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* Write::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const Write& Write::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsWrite(); return *internal_default_instance(); } Write* Write::New(::google::protobuf::Arena* arena) const { Write* n = new Write; if (arena != NULL) { arena->Own(n); } return n; } void Write::clear_operation() { // @@protoc_insertion_point(one_of_clear_start:google.firestore.v1.Write) switch (operation_case()) { case kUpdate: { delete operation_.update_; break; } case kDelete: { operation_.delete__.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); break; } case kTransform: { delete operation_.transform_; break; } case OPERATION_NOT_SET: { break; } } _oneof_case_[0] = OPERATION_NOT_SET; } void Write::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.Write) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; if (GetArenaNoVirtual() == NULL && update_mask_ != NULL) { delete update_mask_; } update_mask_ = NULL; if (GetArenaNoVirtual() == NULL && current_document_ != NULL) { delete current_document_; } current_document_ = NULL; clear_operation(); _internal_metadata_.Clear(); } bool Write::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.Write) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // .google.firestore.v1.Document update = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_update())); } else { goto handle_unusual; } break; } // string delete = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_delete_())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->delete_().data(), static_cast(this->delete_().length()), ::google::protobuf::internal::WireFormatLite::PARSE, "google.firestore.v1.Write.delete")); } else { goto handle_unusual; } break; } // .google.firestore.v1.DocumentMask update_mask = 3; case 3: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_update_mask())); } else { goto handle_unusual; } break; } // .google.firestore.v1.Precondition current_document = 4; case 4: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_current_document())); } else { goto handle_unusual; } break; } // .google.firestore.v1.DocumentTransform transform = 6; case 6: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_transform())); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.Write) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.Write) return false; #undef DO_ } void Write::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.Write) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.firestore.v1.Document update = 1; if (has_update()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 1, *operation_.update_, output); } // string delete = 2; if (has_delete_()) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->delete_().data(), static_cast(this->delete_().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.Write.delete"); ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( 2, this->delete_(), output); } // .google.firestore.v1.DocumentMask update_mask = 3; if (this->has_update_mask()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 3, *this->update_mask_, output); } // .google.firestore.v1.Precondition current_document = 4; if (this->has_current_document()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 4, *this->current_document_, output); } // .google.firestore.v1.DocumentTransform transform = 6; if (has_transform()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 6, *operation_.transform_, output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.Write) } ::google::protobuf::uint8* Write::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.Write) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.firestore.v1.Document update = 1; if (has_update()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 1, *operation_.update_, deterministic, target); } // string delete = 2; if (has_delete_()) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->delete_().data(), static_cast(this->delete_().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.Write.delete"); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 2, this->delete_(), target); } // .google.firestore.v1.DocumentMask update_mask = 3; if (this->has_update_mask()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 3, *this->update_mask_, deterministic, target); } // .google.firestore.v1.Precondition current_document = 4; if (this->has_current_document()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 4, *this->current_document_, deterministic, target); } // .google.firestore.v1.DocumentTransform transform = 6; if (has_transform()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 6, *operation_.transform_, deterministic, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.Write) return target; } size_t Write::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.Write) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // .google.firestore.v1.DocumentMask update_mask = 3; if (this->has_update_mask()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->update_mask_); } // .google.firestore.v1.Precondition current_document = 4; if (this->has_current_document()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->current_document_); } switch (operation_case()) { // .google.firestore.v1.Document update = 1; case kUpdate: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *operation_.update_); break; } // string delete = 2; case kDelete: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->delete_()); break; } // .google.firestore.v1.DocumentTransform transform = 6; case kTransform: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *operation_.transform_); break; } case OPERATION_NOT_SET: { break; } } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void Write::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.Write) GOOGLE_DCHECK_NE(&from, this); const Write* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.Write) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.Write) MergeFrom(*source); } } void Write::MergeFrom(const Write& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.Write) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.has_update_mask()) { mutable_update_mask()->::google::firestore::v1::DocumentMask::MergeFrom(from.update_mask()); } if (from.has_current_document()) { mutable_current_document()->::google::firestore::v1::Precondition::MergeFrom(from.current_document()); } switch (from.operation_case()) { case kUpdate: { mutable_update()->::google::firestore::v1::Document::MergeFrom(from.update()); break; } case kDelete: { set_delete_(from.delete_()); break; } case kTransform: { mutable_transform()->::google::firestore::v1::DocumentTransform::MergeFrom(from.transform()); break; } case OPERATION_NOT_SET: { break; } } } void Write::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.Write) if (&from == this) return; Clear(); MergeFrom(from); } void Write::CopyFrom(const Write& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.Write) if (&from == this) return; Clear(); MergeFrom(from); } bool Write::IsInitialized() const { return true; } void Write::Swap(Write* other) { if (other == this) return; InternalSwap(other); } void Write::InternalSwap(Write* other) { using std::swap; swap(update_mask_, other->update_mask_); swap(current_document_, other->current_document_); swap(operation_, other->operation_); swap(_oneof_case_[0], other->_oneof_case_[0]); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata Write::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void DocumentTransform_FieldTransform::InitAsDefaultInstance() { ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.set_to_server_value_ = 0; ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.increment_ = const_cast< ::google::firestore::v1::Value*>( ::google::firestore::v1::Value::internal_default_instance()); ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.maximum_ = const_cast< ::google::firestore::v1::Value*>( ::google::firestore::v1::Value::internal_default_instance()); ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.minimum_ = const_cast< ::google::firestore::v1::Value*>( ::google::firestore::v1::Value::internal_default_instance()); ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.append_missing_elements_ = const_cast< ::google::firestore::v1::ArrayValue*>( ::google::firestore::v1::ArrayValue::internal_default_instance()); ::google::firestore::v1::_DocumentTransform_FieldTransform_default_instance_.remove_all_from_array_ = const_cast< ::google::firestore::v1::ArrayValue*>( ::google::firestore::v1::ArrayValue::internal_default_instance()); } void DocumentTransform_FieldTransform::set_allocated_increment(::google::firestore::v1::Value* increment) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_transform_type(); if (increment) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { increment = ::google::protobuf::internal::GetOwnedMessage( message_arena, increment, submessage_arena); } set_has_increment(); transform_type_.increment_ = increment; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.DocumentTransform.FieldTransform.increment) } void DocumentTransform_FieldTransform::clear_increment() { if (has_increment()) { delete transform_type_.increment_; clear_has_transform_type(); } } void DocumentTransform_FieldTransform::set_allocated_maximum(::google::firestore::v1::Value* maximum) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_transform_type(); if (maximum) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { maximum = ::google::protobuf::internal::GetOwnedMessage( message_arena, maximum, submessage_arena); } set_has_maximum(); transform_type_.maximum_ = maximum; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.DocumentTransform.FieldTransform.maximum) } void DocumentTransform_FieldTransform::clear_maximum() { if (has_maximum()) { delete transform_type_.maximum_; clear_has_transform_type(); } } void DocumentTransform_FieldTransform::set_allocated_minimum(::google::firestore::v1::Value* minimum) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_transform_type(); if (minimum) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { minimum = ::google::protobuf::internal::GetOwnedMessage( message_arena, minimum, submessage_arena); } set_has_minimum(); transform_type_.minimum_ = minimum; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.DocumentTransform.FieldTransform.minimum) } void DocumentTransform_FieldTransform::clear_minimum() { if (has_minimum()) { delete transform_type_.minimum_; clear_has_transform_type(); } } void DocumentTransform_FieldTransform::set_allocated_append_missing_elements(::google::firestore::v1::ArrayValue* append_missing_elements) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_transform_type(); if (append_missing_elements) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { append_missing_elements = ::google::protobuf::internal::GetOwnedMessage( message_arena, append_missing_elements, submessage_arena); } set_has_append_missing_elements(); transform_type_.append_missing_elements_ = append_missing_elements; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.DocumentTransform.FieldTransform.append_missing_elements) } void DocumentTransform_FieldTransform::clear_append_missing_elements() { if (has_append_missing_elements()) { delete transform_type_.append_missing_elements_; clear_has_transform_type(); } } void DocumentTransform_FieldTransform::set_allocated_remove_all_from_array(::google::firestore::v1::ArrayValue* remove_all_from_array) { ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); clear_transform_type(); if (remove_all_from_array) { ::google::protobuf::Arena* submessage_arena = NULL; if (message_arena != submessage_arena) { remove_all_from_array = ::google::protobuf::internal::GetOwnedMessage( message_arena, remove_all_from_array, submessage_arena); } set_has_remove_all_from_array(); transform_type_.remove_all_from_array_ = remove_all_from_array; } // @@protoc_insertion_point(field_set_allocated:google.firestore.v1.DocumentTransform.FieldTransform.remove_all_from_array) } void DocumentTransform_FieldTransform::clear_remove_all_from_array() { if (has_remove_all_from_array()) { delete transform_type_.remove_all_from_array_; clear_has_transform_type(); } } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int DocumentTransform_FieldTransform::kFieldPathFieldNumber; const int DocumentTransform_FieldTransform::kSetToServerValueFieldNumber; const int DocumentTransform_FieldTransform::kIncrementFieldNumber; const int DocumentTransform_FieldTransform::kMaximumFieldNumber; const int DocumentTransform_FieldTransform::kMinimumFieldNumber; const int DocumentTransform_FieldTransform::kAppendMissingElementsFieldNumber; const int DocumentTransform_FieldTransform::kRemoveAllFromArrayFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 DocumentTransform_FieldTransform::DocumentTransform_FieldTransform() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform_FieldTransform(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.DocumentTransform.FieldTransform) } DocumentTransform_FieldTransform::DocumentTransform_FieldTransform(const DocumentTransform_FieldTransform& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); field_path_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (from.field_path().size() > 0) { field_path_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.field_path_); } clear_has_transform_type(); switch (from.transform_type_case()) { case kSetToServerValue: { set_set_to_server_value(from.set_to_server_value()); break; } case kIncrement: { mutable_increment()->::google::firestore::v1::Value::MergeFrom(from.increment()); break; } case kMaximum: { mutable_maximum()->::google::firestore::v1::Value::MergeFrom(from.maximum()); break; } case kMinimum: { mutable_minimum()->::google::firestore::v1::Value::MergeFrom(from.minimum()); break; } case kAppendMissingElements: { mutable_append_missing_elements()->::google::firestore::v1::ArrayValue::MergeFrom(from.append_missing_elements()); break; } case kRemoveAllFromArray: { mutable_remove_all_from_array()->::google::firestore::v1::ArrayValue::MergeFrom(from.remove_all_from_array()); break; } case TRANSFORM_TYPE_NOT_SET: { break; } } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.DocumentTransform.FieldTransform) } void DocumentTransform_FieldTransform::SharedCtor() { field_path_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); clear_has_transform_type(); _cached_size_ = 0; } DocumentTransform_FieldTransform::~DocumentTransform_FieldTransform() { // @@protoc_insertion_point(destructor:google.firestore.v1.DocumentTransform.FieldTransform) SharedDtor(); } void DocumentTransform_FieldTransform::SharedDtor() { field_path_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (has_transform_type()) { clear_transform_type(); } } void DocumentTransform_FieldTransform::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* DocumentTransform_FieldTransform::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const DocumentTransform_FieldTransform& DocumentTransform_FieldTransform::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform_FieldTransform(); return *internal_default_instance(); } DocumentTransform_FieldTransform* DocumentTransform_FieldTransform::New(::google::protobuf::Arena* arena) const { DocumentTransform_FieldTransform* n = new DocumentTransform_FieldTransform; if (arena != NULL) { arena->Own(n); } return n; } void DocumentTransform_FieldTransform::clear_transform_type() { // @@protoc_insertion_point(one_of_clear_start:google.firestore.v1.DocumentTransform.FieldTransform) switch (transform_type_case()) { case kSetToServerValue: { // No need to clear break; } case kIncrement: { delete transform_type_.increment_; break; } case kMaximum: { delete transform_type_.maximum_; break; } case kMinimum: { delete transform_type_.minimum_; break; } case kAppendMissingElements: { delete transform_type_.append_missing_elements_; break; } case kRemoveAllFromArray: { delete transform_type_.remove_all_from_array_; break; } case TRANSFORM_TYPE_NOT_SET: { break; } } _oneof_case_[0] = TRANSFORM_TYPE_NOT_SET; } void DocumentTransform_FieldTransform::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.DocumentTransform.FieldTransform) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; field_path_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); clear_transform_type(); _internal_metadata_.Clear(); } bool DocumentTransform_FieldTransform::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.DocumentTransform.FieldTransform) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // string field_path = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_field_path())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->field_path().data(), static_cast(this->field_path().length()), ::google::protobuf::internal::WireFormatLite::PARSE, "google.firestore.v1.DocumentTransform.FieldTransform.field_path")); } else { goto handle_unusual; } break; } // .google.firestore.v1.DocumentTransform.FieldTransform.ServerValue set_to_server_value = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) { int value; DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( input, &value))); set_set_to_server_value(static_cast< ::google::firestore::v1::DocumentTransform_FieldTransform_ServerValue >(value)); } else { goto handle_unusual; } break; } // .google.firestore.v1.Value increment = 3; case 3: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_increment())); } else { goto handle_unusual; } break; } // .google.firestore.v1.Value maximum = 4; case 4: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_maximum())); } else { goto handle_unusual; } break; } // .google.firestore.v1.Value minimum = 5; case 5: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_minimum())); } else { goto handle_unusual; } break; } // .google.firestore.v1.ArrayValue append_missing_elements = 6; case 6: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_append_missing_elements())); } else { goto handle_unusual; } break; } // .google.firestore.v1.ArrayValue remove_all_from_array = 7; case 7: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(58u /* 58 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_remove_all_from_array())); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.DocumentTransform.FieldTransform) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.DocumentTransform.FieldTransform) return false; #undef DO_ } void DocumentTransform_FieldTransform::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.DocumentTransform.FieldTransform) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string field_path = 1; if (this->field_path().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->field_path().data(), static_cast(this->field_path().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentTransform.FieldTransform.field_path"); ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( 1, this->field_path(), output); } // .google.firestore.v1.DocumentTransform.FieldTransform.ServerValue set_to_server_value = 2; if (has_set_to_server_value()) { ::google::protobuf::internal::WireFormatLite::WriteEnum( 2, this->set_to_server_value(), output); } // .google.firestore.v1.Value increment = 3; if (has_increment()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 3, *transform_type_.increment_, output); } // .google.firestore.v1.Value maximum = 4; if (has_maximum()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 4, *transform_type_.maximum_, output); } // .google.firestore.v1.Value minimum = 5; if (has_minimum()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 5, *transform_type_.minimum_, output); } // .google.firestore.v1.ArrayValue append_missing_elements = 6; if (has_append_missing_elements()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 6, *transform_type_.append_missing_elements_, output); } // .google.firestore.v1.ArrayValue remove_all_from_array = 7; if (has_remove_all_from_array()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 7, *transform_type_.remove_all_from_array_, output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.DocumentTransform.FieldTransform) } ::google::protobuf::uint8* DocumentTransform_FieldTransform::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.DocumentTransform.FieldTransform) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string field_path = 1; if (this->field_path().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->field_path().data(), static_cast(this->field_path().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentTransform.FieldTransform.field_path"); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 1, this->field_path(), target); } // .google.firestore.v1.DocumentTransform.FieldTransform.ServerValue set_to_server_value = 2; if (has_set_to_server_value()) { target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( 2, this->set_to_server_value(), target); } // .google.firestore.v1.Value increment = 3; if (has_increment()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 3, *transform_type_.increment_, deterministic, target); } // .google.firestore.v1.Value maximum = 4; if (has_maximum()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 4, *transform_type_.maximum_, deterministic, target); } // .google.firestore.v1.Value minimum = 5; if (has_minimum()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 5, *transform_type_.minimum_, deterministic, target); } // .google.firestore.v1.ArrayValue append_missing_elements = 6; if (has_append_missing_elements()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 6, *transform_type_.append_missing_elements_, deterministic, target); } // .google.firestore.v1.ArrayValue remove_all_from_array = 7; if (has_remove_all_from_array()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 7, *transform_type_.remove_all_from_array_, deterministic, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.DocumentTransform.FieldTransform) return target; } size_t DocumentTransform_FieldTransform::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.DocumentTransform.FieldTransform) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // string field_path = 1; if (this->field_path().size() > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->field_path()); } switch (transform_type_case()) { // .google.firestore.v1.DocumentTransform.FieldTransform.ServerValue set_to_server_value = 2; case kSetToServerValue: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::EnumSize(this->set_to_server_value()); break; } // .google.firestore.v1.Value increment = 3; case kIncrement: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *transform_type_.increment_); break; } // .google.firestore.v1.Value maximum = 4; case kMaximum: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *transform_type_.maximum_); break; } // .google.firestore.v1.Value minimum = 5; case kMinimum: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *transform_type_.minimum_); break; } // .google.firestore.v1.ArrayValue append_missing_elements = 6; case kAppendMissingElements: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *transform_type_.append_missing_elements_); break; } // .google.firestore.v1.ArrayValue remove_all_from_array = 7; case kRemoveAllFromArray: { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *transform_type_.remove_all_from_array_); break; } case TRANSFORM_TYPE_NOT_SET: { break; } } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void DocumentTransform_FieldTransform::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.DocumentTransform.FieldTransform) GOOGLE_DCHECK_NE(&from, this); const DocumentTransform_FieldTransform* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.DocumentTransform.FieldTransform) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.DocumentTransform.FieldTransform) MergeFrom(*source); } } void DocumentTransform_FieldTransform::MergeFrom(const DocumentTransform_FieldTransform& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.DocumentTransform.FieldTransform) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.field_path().size() > 0) { field_path_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.field_path_); } switch (from.transform_type_case()) { case kSetToServerValue: { set_set_to_server_value(from.set_to_server_value()); break; } case kIncrement: { mutable_increment()->::google::firestore::v1::Value::MergeFrom(from.increment()); break; } case kMaximum: { mutable_maximum()->::google::firestore::v1::Value::MergeFrom(from.maximum()); break; } case kMinimum: { mutable_minimum()->::google::firestore::v1::Value::MergeFrom(from.minimum()); break; } case kAppendMissingElements: { mutable_append_missing_elements()->::google::firestore::v1::ArrayValue::MergeFrom(from.append_missing_elements()); break; } case kRemoveAllFromArray: { mutable_remove_all_from_array()->::google::firestore::v1::ArrayValue::MergeFrom(from.remove_all_from_array()); break; } case TRANSFORM_TYPE_NOT_SET: { break; } } } void DocumentTransform_FieldTransform::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.DocumentTransform.FieldTransform) if (&from == this) return; Clear(); MergeFrom(from); } void DocumentTransform_FieldTransform::CopyFrom(const DocumentTransform_FieldTransform& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.DocumentTransform.FieldTransform) if (&from == this) return; Clear(); MergeFrom(from); } bool DocumentTransform_FieldTransform::IsInitialized() const { return true; } void DocumentTransform_FieldTransform::Swap(DocumentTransform_FieldTransform* other) { if (other == this) return; InternalSwap(other); } void DocumentTransform_FieldTransform::InternalSwap(DocumentTransform_FieldTransform* other) { using std::swap; field_path_.Swap(&other->field_path_); swap(transform_type_, other->transform_type_); swap(_oneof_case_[0], other->_oneof_case_[0]); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata DocumentTransform_FieldTransform::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void DocumentTransform::InitAsDefaultInstance() { } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int DocumentTransform::kDocumentFieldNumber; const int DocumentTransform::kFieldTransformsFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 DocumentTransform::DocumentTransform() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.DocumentTransform) } DocumentTransform::DocumentTransform(const DocumentTransform& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), field_transforms_(from.field_transforms_), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.DocumentTransform) } void DocumentTransform::SharedCtor() { document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); _cached_size_ = 0; } DocumentTransform::~DocumentTransform() { // @@protoc_insertion_point(destructor:google.firestore.v1.DocumentTransform) SharedDtor(); } void DocumentTransform::SharedDtor() { document_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); } void DocumentTransform::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* DocumentTransform::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const DocumentTransform& DocumentTransform::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentTransform(); return *internal_default_instance(); } DocumentTransform* DocumentTransform::New(::google::protobuf::Arena* arena) const { DocumentTransform* n = new DocumentTransform; if (arena != NULL) { arena->Own(n); } return n; } void DocumentTransform::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.DocumentTransform) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; field_transforms_.Clear(); document_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); _internal_metadata_.Clear(); } bool DocumentTransform::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.DocumentTransform) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // string document = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_document())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::PARSE, "google.firestore.v1.DocumentTransform.document")); } else { goto handle_unusual; } break; } // repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_field_transforms())); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.DocumentTransform) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.DocumentTransform) return false; #undef DO_ } void DocumentTransform::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.DocumentTransform) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentTransform.document"); ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( 1, this->document(), output); } // repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; for (unsigned int i = 0, n = static_cast(this->field_transforms_size()); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 2, this->field_transforms(static_cast(i)), output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.DocumentTransform) } ::google::protobuf::uint8* DocumentTransform::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.DocumentTransform) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentTransform.document"); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 1, this->document(), target); } // repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; for (unsigned int i = 0, n = static_cast(this->field_transforms_size()); i < n; i++) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 2, this->field_transforms(static_cast(i)), deterministic, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.DocumentTransform) return target; } size_t DocumentTransform::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.DocumentTransform) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // repeated .google.firestore.v1.DocumentTransform.FieldTransform field_transforms = 2; { unsigned int count = static_cast(this->field_transforms_size()); total_size += 1UL * count; for (unsigned int i = 0; i < count; i++) { total_size += ::google::protobuf::internal::WireFormatLite::MessageSize( this->field_transforms(static_cast(i))); } } // string document = 1; if (this->document().size() > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->document()); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void DocumentTransform::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.DocumentTransform) GOOGLE_DCHECK_NE(&from, this); const DocumentTransform* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.DocumentTransform) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.DocumentTransform) MergeFrom(*source); } } void DocumentTransform::MergeFrom(const DocumentTransform& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.DocumentTransform) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; field_transforms_.MergeFrom(from.field_transforms_); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } } void DocumentTransform::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.DocumentTransform) if (&from == this) return; Clear(); MergeFrom(from); } void DocumentTransform::CopyFrom(const DocumentTransform& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.DocumentTransform) if (&from == this) return; Clear(); MergeFrom(from); } bool DocumentTransform::IsInitialized() const { return true; } void DocumentTransform::Swap(DocumentTransform* other) { if (other == this) return; InternalSwap(other); } void DocumentTransform::InternalSwap(DocumentTransform* other) { using std::swap; field_transforms_.InternalSwap(&other->field_transforms_); document_.Swap(&other->document_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata DocumentTransform::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void WriteResult::InitAsDefaultInstance() { ::google::firestore::v1::_WriteResult_default_instance_._instance.get_mutable()->update_time_ = const_cast< ::google::protobuf::Timestamp*>( ::google::protobuf::Timestamp::internal_default_instance()); } void WriteResult::clear_update_time() { if (GetArenaNoVirtual() == NULL && update_time_ != NULL) { delete update_time_; } update_time_ = NULL; } void WriteResult::clear_transform_results() { transform_results_.Clear(); } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int WriteResult::kUpdateTimeFieldNumber; const int WriteResult::kTransformResultsFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 WriteResult::WriteResult() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsWriteResult(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.WriteResult) } WriteResult::WriteResult(const WriteResult& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), transform_results_(from.transform_results_), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); if (from.has_update_time()) { update_time_ = new ::google::protobuf::Timestamp(*from.update_time_); } else { update_time_ = NULL; } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.WriteResult) } void WriteResult::SharedCtor() { update_time_ = NULL; _cached_size_ = 0; } WriteResult::~WriteResult() { // @@protoc_insertion_point(destructor:google.firestore.v1.WriteResult) SharedDtor(); } void WriteResult::SharedDtor() { if (this != internal_default_instance()) delete update_time_; } void WriteResult::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* WriteResult::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const WriteResult& WriteResult::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsWriteResult(); return *internal_default_instance(); } WriteResult* WriteResult::New(::google::protobuf::Arena* arena) const { WriteResult* n = new WriteResult; if (arena != NULL) { arena->Own(n); } return n; } void WriteResult::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.WriteResult) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; transform_results_.Clear(); if (GetArenaNoVirtual() == NULL && update_time_ != NULL) { delete update_time_; } update_time_ = NULL; _internal_metadata_.Clear(); } bool WriteResult::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.WriteResult) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // .google.protobuf.Timestamp update_time = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_update_time())); } else { goto handle_unusual; } break; } // repeated .google.firestore.v1.Value transform_results = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage(input, add_transform_results())); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.WriteResult) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.WriteResult) return false; #undef DO_ } void WriteResult::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.WriteResult) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.protobuf.Timestamp update_time = 1; if (this->has_update_time()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 1, *this->update_time_, output); } // repeated .google.firestore.v1.Value transform_results = 2; for (unsigned int i = 0, n = static_cast(this->transform_results_size()); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 2, this->transform_results(static_cast(i)), output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.WriteResult) } ::google::protobuf::uint8* WriteResult::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.WriteResult) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.protobuf.Timestamp update_time = 1; if (this->has_update_time()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 1, *this->update_time_, deterministic, target); } // repeated .google.firestore.v1.Value transform_results = 2; for (unsigned int i = 0, n = static_cast(this->transform_results_size()); i < n; i++) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 2, this->transform_results(static_cast(i)), deterministic, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.WriteResult) return target; } size_t WriteResult::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.WriteResult) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // repeated .google.firestore.v1.Value transform_results = 2; { unsigned int count = static_cast(this->transform_results_size()); total_size += 1UL * count; for (unsigned int i = 0; i < count; i++) { total_size += ::google::protobuf::internal::WireFormatLite::MessageSize( this->transform_results(static_cast(i))); } } // .google.protobuf.Timestamp update_time = 1; if (this->has_update_time()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->update_time_); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void WriteResult::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.WriteResult) GOOGLE_DCHECK_NE(&from, this); const WriteResult* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.WriteResult) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.WriteResult) MergeFrom(*source); } } void WriteResult::MergeFrom(const WriteResult& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.WriteResult) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; transform_results_.MergeFrom(from.transform_results_); if (from.has_update_time()) { mutable_update_time()->::google::protobuf::Timestamp::MergeFrom(from.update_time()); } } void WriteResult::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.WriteResult) if (&from == this) return; Clear(); MergeFrom(from); } void WriteResult::CopyFrom(const WriteResult& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.WriteResult) if (&from == this) return; Clear(); MergeFrom(from); } bool WriteResult::IsInitialized() const { return true; } void WriteResult::Swap(WriteResult* other) { if (other == this) return; InternalSwap(other); } void WriteResult::InternalSwap(WriteResult* other) { using std::swap; transform_results_.InternalSwap(&other->transform_results_); swap(update_time_, other->update_time_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata WriteResult::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void DocumentChange::InitAsDefaultInstance() { ::google::firestore::v1::_DocumentChange_default_instance_._instance.get_mutable()->document_ = const_cast< ::google::firestore::v1::Document*>( ::google::firestore::v1::Document::internal_default_instance()); } void DocumentChange::clear_document() { if (GetArenaNoVirtual() == NULL && document_ != NULL) { delete document_; } document_ = NULL; } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int DocumentChange::kDocumentFieldNumber; const int DocumentChange::kTargetIdsFieldNumber; const int DocumentChange::kRemovedTargetIdsFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 DocumentChange::DocumentChange() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentChange(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.DocumentChange) } DocumentChange::DocumentChange(const DocumentChange& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), target_ids_(from.target_ids_), removed_target_ids_(from.removed_target_ids_), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); if (from.has_document()) { document_ = new ::google::firestore::v1::Document(*from.document_); } else { document_ = NULL; } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.DocumentChange) } void DocumentChange::SharedCtor() { document_ = NULL; _cached_size_ = 0; } DocumentChange::~DocumentChange() { // @@protoc_insertion_point(destructor:google.firestore.v1.DocumentChange) SharedDtor(); } void DocumentChange::SharedDtor() { if (this != internal_default_instance()) delete document_; } void DocumentChange::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* DocumentChange::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const DocumentChange& DocumentChange::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentChange(); return *internal_default_instance(); } DocumentChange* DocumentChange::New(::google::protobuf::Arena* arena) const { DocumentChange* n = new DocumentChange; if (arena != NULL) { arena->Own(n); } return n; } void DocumentChange::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.DocumentChange) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; target_ids_.Clear(); removed_target_ids_.Clear(); if (GetArenaNoVirtual() == NULL && document_ != NULL) { delete document_; } document_ = NULL; _internal_metadata_.Clear(); } bool DocumentChange::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.DocumentChange) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // .google.firestore.v1.Document document = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_document())); } else { goto handle_unusual; } break; } // repeated int32 target_ids = 5; case 5: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, this->mutable_target_ids()))); } else if ( static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( 1, 42u, input, this->mutable_target_ids()))); } else { goto handle_unusual; } break; } // repeated int32 removed_target_ids = 6; case 6: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, this->mutable_removed_target_ids()))); } else if ( static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(48u /* 48 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( 1, 50u, input, this->mutable_removed_target_ids()))); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.DocumentChange) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.DocumentChange) return false; #undef DO_ } void DocumentChange::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.DocumentChange) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.firestore.v1.Document document = 1; if (this->has_document()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 1, *this->document_, output); } // repeated int32 target_ids = 5; if (this->target_ids_size() > 0) { ::google::protobuf::internal::WireFormatLite::WriteTag(5, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output); output->WriteVarint32(static_cast< ::google::protobuf::uint32>( _target_ids_cached_byte_size_)); } for (int i = 0, n = this->target_ids_size(); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteInt32NoTag( this->target_ids(i), output); } // repeated int32 removed_target_ids = 6; if (this->removed_target_ids_size() > 0) { ::google::protobuf::internal::WireFormatLite::WriteTag(6, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output); output->WriteVarint32(static_cast< ::google::protobuf::uint32>( _removed_target_ids_cached_byte_size_)); } for (int i = 0, n = this->removed_target_ids_size(); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteInt32NoTag( this->removed_target_ids(i), output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.DocumentChange) } ::google::protobuf::uint8* DocumentChange::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.DocumentChange) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // .google.firestore.v1.Document document = 1; if (this->has_document()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 1, *this->document_, deterministic, target); } // repeated int32 target_ids = 5; if (this->target_ids_size() > 0) { target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray( 5, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, target); target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray( static_cast< ::google::protobuf::int32>( _target_ids_cached_byte_size_), target); target = ::google::protobuf::internal::WireFormatLite:: WriteInt32NoTagToArray(this->target_ids_, target); } // repeated int32 removed_target_ids = 6; if (this->removed_target_ids_size() > 0) { target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray( 6, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, target); target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray( static_cast< ::google::protobuf::int32>( _removed_target_ids_cached_byte_size_), target); target = ::google::protobuf::internal::WireFormatLite:: WriteInt32NoTagToArray(this->removed_target_ids_, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.DocumentChange) return target; } size_t DocumentChange::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.DocumentChange) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // repeated int32 target_ids = 5; { size_t data_size = ::google::protobuf::internal::WireFormatLite:: Int32Size(this->target_ids_); if (data_size > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( static_cast< ::google::protobuf::int32>(data_size)); } int cached_size = ::google::protobuf::internal::ToCachedSize(data_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _target_ids_cached_byte_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); total_size += data_size; } // repeated int32 removed_target_ids = 6; { size_t data_size = ::google::protobuf::internal::WireFormatLite:: Int32Size(this->removed_target_ids_); if (data_size > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( static_cast< ::google::protobuf::int32>(data_size)); } int cached_size = ::google::protobuf::internal::ToCachedSize(data_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _removed_target_ids_cached_byte_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); total_size += data_size; } // .google.firestore.v1.Document document = 1; if (this->has_document()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->document_); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void DocumentChange::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.DocumentChange) GOOGLE_DCHECK_NE(&from, this); const DocumentChange* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.DocumentChange) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.DocumentChange) MergeFrom(*source); } } void DocumentChange::MergeFrom(const DocumentChange& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.DocumentChange) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; target_ids_.MergeFrom(from.target_ids_); removed_target_ids_.MergeFrom(from.removed_target_ids_); if (from.has_document()) { mutable_document()->::google::firestore::v1::Document::MergeFrom(from.document()); } } void DocumentChange::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.DocumentChange) if (&from == this) return; Clear(); MergeFrom(from); } void DocumentChange::CopyFrom(const DocumentChange& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.DocumentChange) if (&from == this) return; Clear(); MergeFrom(from); } bool DocumentChange::IsInitialized() const { return true; } void DocumentChange::Swap(DocumentChange* other) { if (other == this) return; InternalSwap(other); } void DocumentChange::InternalSwap(DocumentChange* other) { using std::swap; target_ids_.InternalSwap(&other->target_ids_); removed_target_ids_.InternalSwap(&other->removed_target_ids_); swap(document_, other->document_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata DocumentChange::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void DocumentDelete::InitAsDefaultInstance() { ::google::firestore::v1::_DocumentDelete_default_instance_._instance.get_mutable()->read_time_ = const_cast< ::google::protobuf::Timestamp*>( ::google::protobuf::Timestamp::internal_default_instance()); } void DocumentDelete::clear_read_time() { if (GetArenaNoVirtual() == NULL && read_time_ != NULL) { delete read_time_; } read_time_ = NULL; } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int DocumentDelete::kDocumentFieldNumber; const int DocumentDelete::kRemovedTargetIdsFieldNumber; const int DocumentDelete::kReadTimeFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 DocumentDelete::DocumentDelete() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentDelete(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.DocumentDelete) } DocumentDelete::DocumentDelete(const DocumentDelete& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), removed_target_ids_(from.removed_target_ids_), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } if (from.has_read_time()) { read_time_ = new ::google::protobuf::Timestamp(*from.read_time_); } else { read_time_ = NULL; } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.DocumentDelete) } void DocumentDelete::SharedCtor() { document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); read_time_ = NULL; _cached_size_ = 0; } DocumentDelete::~DocumentDelete() { // @@protoc_insertion_point(destructor:google.firestore.v1.DocumentDelete) SharedDtor(); } void DocumentDelete::SharedDtor() { document_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (this != internal_default_instance()) delete read_time_; } void DocumentDelete::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* DocumentDelete::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const DocumentDelete& DocumentDelete::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentDelete(); return *internal_default_instance(); } DocumentDelete* DocumentDelete::New(::google::protobuf::Arena* arena) const { DocumentDelete* n = new DocumentDelete; if (arena != NULL) { arena->Own(n); } return n; } void DocumentDelete::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.DocumentDelete) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; removed_target_ids_.Clear(); document_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (GetArenaNoVirtual() == NULL && read_time_ != NULL) { delete read_time_; } read_time_ = NULL; _internal_metadata_.Clear(); } bool DocumentDelete::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.DocumentDelete) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // string document = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_document())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::PARSE, "google.firestore.v1.DocumentDelete.document")); } else { goto handle_unusual; } break; } // .google.protobuf.Timestamp read_time = 4; case 4: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_read_time())); } else { goto handle_unusual; } break; } // repeated int32 removed_target_ids = 6; case 6: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, this->mutable_removed_target_ids()))); } else if ( static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(48u /* 48 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( 1, 50u, input, this->mutable_removed_target_ids()))); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.DocumentDelete) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.DocumentDelete) return false; #undef DO_ } void DocumentDelete::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.DocumentDelete) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentDelete.document"); ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( 1, this->document(), output); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 4, *this->read_time_, output); } // repeated int32 removed_target_ids = 6; if (this->removed_target_ids_size() > 0) { ::google::protobuf::internal::WireFormatLite::WriteTag(6, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output); output->WriteVarint32(static_cast< ::google::protobuf::uint32>( _removed_target_ids_cached_byte_size_)); } for (int i = 0, n = this->removed_target_ids_size(); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteInt32NoTag( this->removed_target_ids(i), output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.DocumentDelete) } ::google::protobuf::uint8* DocumentDelete::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.DocumentDelete) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentDelete.document"); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 1, this->document(), target); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 4, *this->read_time_, deterministic, target); } // repeated int32 removed_target_ids = 6; if (this->removed_target_ids_size() > 0) { target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray( 6, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, target); target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray( static_cast< ::google::protobuf::int32>( _removed_target_ids_cached_byte_size_), target); target = ::google::protobuf::internal::WireFormatLite:: WriteInt32NoTagToArray(this->removed_target_ids_, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.DocumentDelete) return target; } size_t DocumentDelete::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.DocumentDelete) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // repeated int32 removed_target_ids = 6; { size_t data_size = ::google::protobuf::internal::WireFormatLite:: Int32Size(this->removed_target_ids_); if (data_size > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( static_cast< ::google::protobuf::int32>(data_size)); } int cached_size = ::google::protobuf::internal::ToCachedSize(data_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _removed_target_ids_cached_byte_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); total_size += data_size; } // string document = 1; if (this->document().size() > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->document()); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->read_time_); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void DocumentDelete::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.DocumentDelete) GOOGLE_DCHECK_NE(&from, this); const DocumentDelete* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.DocumentDelete) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.DocumentDelete) MergeFrom(*source); } } void DocumentDelete::MergeFrom(const DocumentDelete& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.DocumentDelete) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; removed_target_ids_.MergeFrom(from.removed_target_ids_); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } if (from.has_read_time()) { mutable_read_time()->::google::protobuf::Timestamp::MergeFrom(from.read_time()); } } void DocumentDelete::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.DocumentDelete) if (&from == this) return; Clear(); MergeFrom(from); } void DocumentDelete::CopyFrom(const DocumentDelete& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.DocumentDelete) if (&from == this) return; Clear(); MergeFrom(from); } bool DocumentDelete::IsInitialized() const { return true; } void DocumentDelete::Swap(DocumentDelete* other) { if (other == this) return; InternalSwap(other); } void DocumentDelete::InternalSwap(DocumentDelete* other) { using std::swap; removed_target_ids_.InternalSwap(&other->removed_target_ids_); document_.Swap(&other->document_); swap(read_time_, other->read_time_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata DocumentDelete::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void DocumentRemove::InitAsDefaultInstance() { ::google::firestore::v1::_DocumentRemove_default_instance_._instance.get_mutable()->read_time_ = const_cast< ::google::protobuf::Timestamp*>( ::google::protobuf::Timestamp::internal_default_instance()); } void DocumentRemove::clear_read_time() { if (GetArenaNoVirtual() == NULL && read_time_ != NULL) { delete read_time_; } read_time_ = NULL; } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int DocumentRemove::kDocumentFieldNumber; const int DocumentRemove::kRemovedTargetIdsFieldNumber; const int DocumentRemove::kReadTimeFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 DocumentRemove::DocumentRemove() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentRemove(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.DocumentRemove) } DocumentRemove::DocumentRemove(const DocumentRemove& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), removed_target_ids_(from.removed_target_ids_), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } if (from.has_read_time()) { read_time_ = new ::google::protobuf::Timestamp(*from.read_time_); } else { read_time_ = NULL; } // @@protoc_insertion_point(copy_constructor:google.firestore.v1.DocumentRemove) } void DocumentRemove::SharedCtor() { document_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); read_time_ = NULL; _cached_size_ = 0; } DocumentRemove::~DocumentRemove() { // @@protoc_insertion_point(destructor:google.firestore.v1.DocumentRemove) SharedDtor(); } void DocumentRemove::SharedDtor() { document_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (this != internal_default_instance()) delete read_time_; } void DocumentRemove::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* DocumentRemove::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const DocumentRemove& DocumentRemove::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsDocumentRemove(); return *internal_default_instance(); } DocumentRemove* DocumentRemove::New(::google::protobuf::Arena* arena) const { DocumentRemove* n = new DocumentRemove; if (arena != NULL) { arena->Own(n); } return n; } void DocumentRemove::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.DocumentRemove) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; removed_target_ids_.Clear(); document_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); if (GetArenaNoVirtual() == NULL && read_time_ != NULL) { delete read_time_; } read_time_ = NULL; _internal_metadata_.Clear(); } bool DocumentRemove::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.DocumentRemove) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // string document = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_document())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::PARSE, "google.firestore.v1.DocumentRemove.document")); } else { goto handle_unusual; } break; } // repeated int32 removed_target_ids = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, this->mutable_removed_target_ids()))); } else if ( static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( 1, 18u, input, this->mutable_removed_target_ids()))); } else { goto handle_unusual; } break; } // .google.protobuf.Timestamp read_time = 4; case 4: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(34u /* 34 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( input, mutable_read_time())); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.DocumentRemove) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.DocumentRemove) return false; #undef DO_ } void DocumentRemove::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.DocumentRemove) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentRemove.document"); ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( 1, this->document(), output); } // repeated int32 removed_target_ids = 2; if (this->removed_target_ids_size() > 0) { ::google::protobuf::internal::WireFormatLite::WriteTag(2, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output); output->WriteVarint32(static_cast< ::google::protobuf::uint32>( _removed_target_ids_cached_byte_size_)); } for (int i = 0, n = this->removed_target_ids_size(); i < n; i++) { ::google::protobuf::internal::WireFormatLite::WriteInt32NoTag( this->removed_target_ids(i), output); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( 4, *this->read_time_, output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.DocumentRemove) } ::google::protobuf::uint8* DocumentRemove::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.DocumentRemove) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // string document = 1; if (this->document().size() > 0) { ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( this->document().data(), static_cast(this->document().length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "google.firestore.v1.DocumentRemove.document"); target = ::google::protobuf::internal::WireFormatLite::WriteStringToArray( 1, this->document(), target); } // repeated int32 removed_target_ids = 2; if (this->removed_target_ids_size() > 0) { target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray( 2, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, target); target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray( static_cast< ::google::protobuf::int32>( _removed_target_ids_cached_byte_size_), target); target = ::google::protobuf::internal::WireFormatLite:: WriteInt32NoTagToArray(this->removed_target_ids_, target); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( 4, *this->read_time_, deterministic, target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.DocumentRemove) return target; } size_t DocumentRemove::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.DocumentRemove) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // repeated int32 removed_target_ids = 2; { size_t data_size = ::google::protobuf::internal::WireFormatLite:: Int32Size(this->removed_target_ids_); if (data_size > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( static_cast< ::google::protobuf::int32>(data_size)); } int cached_size = ::google::protobuf::internal::ToCachedSize(data_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _removed_target_ids_cached_byte_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); total_size += data_size; } // string document = 1; if (this->document().size() > 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize( this->document()); } // .google.protobuf.Timestamp read_time = 4; if (this->has_read_time()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( *this->read_time_); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void DocumentRemove::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.DocumentRemove) GOOGLE_DCHECK_NE(&from, this); const DocumentRemove* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.DocumentRemove) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.DocumentRemove) MergeFrom(*source); } } void DocumentRemove::MergeFrom(const DocumentRemove& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.DocumentRemove) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; removed_target_ids_.MergeFrom(from.removed_target_ids_); if (from.document().size() > 0) { document_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.document_); } if (from.has_read_time()) { mutable_read_time()->::google::protobuf::Timestamp::MergeFrom(from.read_time()); } } void DocumentRemove::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.DocumentRemove) if (&from == this) return; Clear(); MergeFrom(from); } void DocumentRemove::CopyFrom(const DocumentRemove& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.DocumentRemove) if (&from == this) return; Clear(); MergeFrom(from); } bool DocumentRemove::IsInitialized() const { return true; } void DocumentRemove::Swap(DocumentRemove* other) { if (other == this) return; InternalSwap(other); } void DocumentRemove::InternalSwap(DocumentRemove* other) { using std::swap; removed_target_ids_.InternalSwap(&other->removed_target_ids_); document_.Swap(&other->document_); swap(read_time_, other->read_time_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata DocumentRemove::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // =================================================================== void ExistenceFilter::InitAsDefaultInstance() { } #if !defined(_MSC_VER) || _MSC_VER >= 1900 const int ExistenceFilter::kTargetIdFieldNumber; const int ExistenceFilter::kCountFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 ExistenceFilter::ExistenceFilter() : ::google::protobuf::Message(), _internal_metadata_(NULL) { if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsExistenceFilter(); } SharedCtor(); // @@protoc_insertion_point(constructor:google.firestore.v1.ExistenceFilter) } ExistenceFilter::ExistenceFilter(const ExistenceFilter& from) : ::google::protobuf::Message(), _internal_metadata_(NULL), _cached_size_(0) { _internal_metadata_.MergeFrom(from._internal_metadata_); ::memcpy(&target_id_, &from.target_id_, static_cast(reinterpret_cast(&count_) - reinterpret_cast(&target_id_)) + sizeof(count_)); // @@protoc_insertion_point(copy_constructor:google.firestore.v1.ExistenceFilter) } void ExistenceFilter::SharedCtor() { ::memset(&target_id_, 0, static_cast( reinterpret_cast(&count_) - reinterpret_cast(&target_id_)) + sizeof(count_)); _cached_size_ = 0; } ExistenceFilter::~ExistenceFilter() { // @@protoc_insertion_point(destructor:google.firestore.v1.ExistenceFilter) SharedDtor(); } void ExistenceFilter::SharedDtor() { } void ExistenceFilter::SetCachedSize(int size) const { GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); } const ::google::protobuf::Descriptor* ExistenceFilter::descriptor() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; } const ExistenceFilter& ExistenceFilter::default_instance() { ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::InitDefaultsExistenceFilter(); return *internal_default_instance(); } ExistenceFilter* ExistenceFilter::New(::google::protobuf::Arena* arena) const { ExistenceFilter* n = new ExistenceFilter; if (arena != NULL) { arena->Own(n); } return n; } void ExistenceFilter::Clear() { // @@protoc_insertion_point(message_clear_start:google.firestore.v1.ExistenceFilter) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; ::memset(&target_id_, 0, static_cast( reinterpret_cast(&count_) - reinterpret_cast(&target_id_)) + sizeof(count_)); _internal_metadata_.Clear(); } bool ExistenceFilter::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; // @@protoc_insertion_point(parse_start:google.firestore.v1.ExistenceFilter) for (;;) { ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { // int32 target_id = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, &target_id_))); } else { goto handle_unusual; } break; } // int32 count = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == static_cast< ::google::protobuf::uint8>(16u /* 16 & 0xFF */)) { DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>( input, &count_))); } else { goto handle_unusual; } break; } default: { handle_unusual: if (tag == 0) { goto success; } DO_(::google::protobuf::internal::WireFormat::SkipField( input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } } success: // @@protoc_insertion_point(parse_success:google.firestore.v1.ExistenceFilter) return true; failure: // @@protoc_insertion_point(parse_failure:google.firestore.v1.ExistenceFilter) return false; #undef DO_ } void ExistenceFilter::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { // @@protoc_insertion_point(serialize_start:google.firestore.v1.ExistenceFilter) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // int32 target_id = 1; if (this->target_id() != 0) { ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->target_id(), output); } // int32 count = 2; if (this->count() != 0) { ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->count(), output); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); } // @@protoc_insertion_point(serialize_end:google.firestore.v1.ExistenceFilter) } ::google::protobuf::uint8* ExistenceFilter::InternalSerializeWithCachedSizesToArray( bool deterministic, ::google::protobuf::uint8* target) const { (void)deterministic; // Unused // @@protoc_insertion_point(serialize_to_array_start:google.firestore.v1.ExistenceFilter) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; // int32 target_id = 1; if (this->target_id() != 0) { target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->target_id(), target); } // int32 count = 2; if (this->count() != 0) { target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->count(), target); } if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); } // @@protoc_insertion_point(serialize_to_array_end:google.firestore.v1.ExistenceFilter) return target; } size_t ExistenceFilter::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.firestore.v1.ExistenceFilter) size_t total_size = 0; if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { total_size += ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); } // int32 target_id = 1; if (this->target_id() != 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( this->target_id()); } // int32 count = 2; if (this->count() != 0) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::Int32Size( this->count()); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); _cached_size_ = cached_size; GOOGLE_SAFE_CONCURRENT_WRITES_END(); return total_size; } void ExistenceFilter::MergeFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_merge_from_start:google.firestore.v1.ExistenceFilter) GOOGLE_DCHECK_NE(&from, this); const ExistenceFilter* source = ::google::protobuf::internal::DynamicCastToGenerated( &from); if (source == NULL) { // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.firestore.v1.ExistenceFilter) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { // @@protoc_insertion_point(generalized_merge_from_cast_success:google.firestore.v1.ExistenceFilter) MergeFrom(*source); } } void ExistenceFilter::MergeFrom(const ExistenceFilter& from) { // @@protoc_insertion_point(class_specific_merge_from_start:google.firestore.v1.ExistenceFilter) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; if (from.target_id() != 0) { set_target_id(from.target_id()); } if (from.count() != 0) { set_count(from.count()); } } void ExistenceFilter::CopyFrom(const ::google::protobuf::Message& from) { // @@protoc_insertion_point(generalized_copy_from_start:google.firestore.v1.ExistenceFilter) if (&from == this) return; Clear(); MergeFrom(from); } void ExistenceFilter::CopyFrom(const ExistenceFilter& from) { // @@protoc_insertion_point(class_specific_copy_from_start:google.firestore.v1.ExistenceFilter) if (&from == this) return; Clear(); MergeFrom(from); } bool ExistenceFilter::IsInitialized() const { return true; } void ExistenceFilter::Swap(ExistenceFilter* other) { if (other == this) return; InternalSwap(other); } void ExistenceFilter::InternalSwap(ExistenceFilter* other) { using std::swap; swap(target_id_, other->target_id_); swap(count_, other->count_); _internal_metadata_.Swap(&other->_internal_metadata_); swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata ExistenceFilter::GetMetadata() const { protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::protobuf_AssignDescriptorsOnce(); return ::protobuf_google_2ffirestore_2fv1_2fwrite_2eproto::file_level_metadata[kIndexInFileMessages]; } // @@protoc_insertion_point(namespace_scope) } // namespace v1 } // namespace firestore } // namespace google // @@protoc_insertion_point(global_scope)