From 68f0e2dafbc99df0789be5fd0aa847ae69940363 Mon Sep 17 00:00:00 2001 From: zxu Date: Fri, 25 May 2018 15:06:19 -0400 Subject: Firestore project: Import of API interfaces. (#1337) - 198063502 Address comment upstream. by zxu - 197942352 Fix style upstream and fix destination depot in copybara. by zxu - 197925542 Fix headers with change from GitHub, see the current diff... by zxu - 197922012 Implement ListenerRegistration::Remove(). by zxu - 197713382 Implement more on listener class and implement ListenerRe... by zxu - 196551381 Implement more on listener class and implement the Docume... by zxu - 196276752 Implement the SnapshotMetadata with inline methods and (n... by zxu - 195841793 Implement the wrapper class for callback (EventListener). by zxu - 194112388 Add Android-Wrapper for DocumentReference's non-callback ... by zxu - 192445183 Add Android-Wrapper for Firestore's remaining methods. by zxu - 190986604 Manually import the public portion of by mcg - 189013767 Add Android-Wrapper for Firestore's method that does not ... by zxu - 188809445 Import of firebase-ios-sdk from Github. by mcg - 187049498 Import of firebase-ios-sdk from Github. by mcg - 184568931 Import of firebase-ios-sdk from Github. by mcg ORIGINAL_AUTHOR=Firebase PiperOrigin-RevId: 198063502 --- .../core/include/firebase/firestore/CMakeLists.txt | 2 +- .../firebase/firestore/collection_reference.h | 98 ++++++++++++++++++++ .../include/firebase/firestore/document_change.h | 34 +++++++ .../firebase/firestore/document_reference.h | 101 ++++++++------------- .../include/firebase/firestore/document_snapshot.h | 38 ++++++++ .../include/firebase/firestore/event_listener.h | 10 +- .../core/include/firebase/firestore/field_path.h | 34 +++++++ .../core/include/firebase/firestore/field_value.h | 33 +++++++ .../core/include/firebase/firestore/firestore.h | 26 ++++-- .../include/firebase/firestore/firestore_errors.h | 4 + .../firebase/firestore/listener_registration.h | 92 +++++++++++++++++++ Firestore/core/include/firebase/firestore/query.h | 33 +++++++ .../include/firebase/firestore/query_snapshot.h | 34 +++++++ .../core/include/firebase/firestore/set_options.h | 39 ++++++++ .../core/include/firebase/firestore/settings.h | 32 +++++++ .../include/firebase/firestore/snapshot_metadata.h | 46 ++++++++++ .../core/include/firebase/firestore/transaction.h | 32 +++++++ .../core/include/firebase/firestore/write_batch.h | 39 ++++++++ 18 files changed, 650 insertions(+), 77 deletions(-) create mode 100644 Firestore/core/include/firebase/firestore/collection_reference.h create mode 100644 Firestore/core/include/firebase/firestore/document_change.h create mode 100644 Firestore/core/include/firebase/firestore/document_snapshot.h create mode 100644 Firestore/core/include/firebase/firestore/field_path.h create mode 100644 Firestore/core/include/firebase/firestore/field_value.h create mode 100644 Firestore/core/include/firebase/firestore/listener_registration.h create mode 100644 Firestore/core/include/firebase/firestore/query.h create mode 100644 Firestore/core/include/firebase/firestore/query_snapshot.h create mode 100644 Firestore/core/include/firebase/firestore/set_options.h create mode 100644 Firestore/core/include/firebase/firestore/settings.h create mode 100644 Firestore/core/include/firebase/firestore/snapshot_metadata.h create mode 100644 Firestore/core/include/firebase/firestore/transaction.h create mode 100644 Firestore/core/include/firebase/firestore/write_batch.h (limited to 'Firestore/core') diff --git a/Firestore/core/include/firebase/firestore/CMakeLists.txt b/Firestore/core/include/firebase/firestore/CMakeLists.txt index e4e7acd..0c7fd48 100644 --- a/Firestore/core/include/firebase/firestore/CMakeLists.txt +++ b/Firestore/core/include/firebase/firestore/CMakeLists.txt @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Hack to make the headers show up in IDEs +# Workaround to make the headers show up in IDEs # (see https://stackoverflow.com/questions/27039019/ and open issue on CMake # issue tracker: https://gitlab.kitware.com/cmake/cmake/issues/15234) add_custom_target(firebase_firestore_types_ide SOURCES diff --git a/Firestore/core/include/firebase/firestore/collection_reference.h b/Firestore/core/include/firebase/firestore/collection_reference.h new file mode 100644 index 0000000..4d47248 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/collection_reference.h @@ -0,0 +1,98 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_COLLECTION_REFERENCE_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_COLLECTION_REFERENCE_H_ + +namespace firebase { +namespace firestore { + +class CollectionReferenceInternal; +class FirestoreInternal; + +/** + * A CollectionReference refers to a collection of documents location in a + * Firestore database and can be used for adding documents, getting document + * references, and querying for documents. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class CollectionReference { + public: + /** + * @brief Default constructor. This creates an invalid CollectionReference. + * Attempting to perform any operations on this reference will fail unless a + * valid CollectionReference has been assigned to it. + */ + CollectionReference(); + + /** + * @brief Copy constructor. It's totally okay (and efficient) to copy + * CollectionReference instances, as they simply point to the same location in + * the database. + * + * @param[in] reference CollectionReference to copy from. + */ + CollectionReference(const CollectionReference& reference); + + /** + * @brief Move constructor. Moving is an efficient operation for + * CollectionReference instances. + * + * @param[in] reference CollectionReference to move data from. + */ + CollectionReference(CollectionReference&& reference); + + /** @brief Required virtual destructor. */ + virtual ~CollectionReference(); + + /** + * @brief Copy assignment operator. It's totally okay (and efficient) to copy + * CollectionReference instances, as they simply point to the same location in + * the database. + * + * @param[in] reference CollectionReference to copy from. + * + * @returns Reference to the destination CollectionReference. + */ + CollectionReference& operator=(const CollectionReference& reference); + + /** + * @brief Move assignment operator. Moving is an efficient operation for + * CollectionReference instances. + * + * @param[in] reference CollectionReference to move data from. + * + * @returns Reference to the destination CollectionReference. + */ + CollectionReference& operator=(CollectionReference&& reference); + + protected: + explicit CollectionReference(CollectionReferenceInternal* internal); + + private: + friend class DocumentReference; + friend class DocumentReferenceInternal; + friend class FirestoreInternal; + + // TODO(zxu123): investigate possibility to use std::unique_ptr or + // firebase::UniquePtr. + CollectionReferenceInternal* internal_ = nullptr; +}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_COLLECTION_REFERENCE_H_ diff --git a/Firestore/core/include/firebase/firestore/document_change.h b/Firestore/core/include/firebase/firestore/document_change.h new file mode 100644 index 0000000..4812290 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/document_change.h @@ -0,0 +1,34 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_CHANGE_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_CHANGE_H_ + +namespace firebase { +namespace firestore { + +/** + * A DocumentChange represents a change to the documents matching a query. It + * contains the document affected and the type of change that occurred (added, + * modified, or removed). + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class DocumentChange {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_CHANGE_H_ diff --git a/Firestore/core/include/firebase/firestore/document_reference.h b/Firestore/core/include/firebase/firestore/document_reference.h index d295188..9385ed3 100644 --- a/Firestore/core/include/firebase/firestore/document_reference.h +++ b/Firestore/core/include/firebase/firestore/document_reference.h @@ -29,6 +29,17 @@ #include #endif +#include "firebase/app.h" +#include "firebase/firestore/collection_reference.h" +#include "firebase/firestore/document_snapshot.h" +#include "firebase/firestore/event_listener.h" +#include "firebase/firestore/field_value.h" +#include "firebase/firestore/firestore.h" +#include "firebase/firestore/firestore_errors.h" +#include "firebase/firestore/listener_registration.h" +#include "firebase/firestore/set_options.h" +#include "firebase/future.h" + // TODO(rsgowman): Note that RTDB uses: // #if defined(FIREBASE_USE_MOVE_OPERATORS) || defined(DOXYGEN // to protect move operators from older compilers. But all our supported @@ -36,34 +47,12 @@ // here so we don't forget to mention this during the API review, and should be // removed once this note has migrated to the API review doc. -// TODO(rsgowman): replace these forward decls with appropriate includes (once -// they exist) -namespace firebase { -class App; -template -class Future; -} // namespace firebase - namespace firebase { namespace firestore { -// TODO(rsgowman): replace these forward decls with appropriate includes (once -// they exist) -class FieldValue; -class DocumentSnapshot; +class DocumentReferenceInternal; class Firestore; -class Error; -template -class EventListener; -class ListenerRegistration; -class CollectionReference; -class DocumentListenOptions; -// TODO(rsgowman): not quite a forward decl, but required to make the default -// parameter to Set() "compile". -class SetOptions { - public: - SetOptions(); -}; +class FirestoreInternal; // TODO(rsgowman): move this into the FieldValue header #ifdef STLPORT @@ -80,12 +69,19 @@ using MapFieldValue = std::unordered_map; * * Create a DocumentReference via Firebase::Document(const string& path). * + * NOT thread-safe: an instance should not be used from multiple threads + * * Subclassing Note: Firestore classes are not meant to be subclassed except for * use in test mocks. Subclassing is not supported in production code and new * SDK releases may break code that does so. */ class DocumentReference { public: + enum class MetadataChanges { + kExclude, + kInclude, + }; + /** * @brief Default constructor. This creates an invalid DocumentReference. * Attempting to perform any operations on this reference will fail (and cause @@ -269,28 +265,15 @@ class DocumentReference { * this DocumentReference. (Ownership is not transferred; you are responsible * for making sure that listener is valid as long as this DocumentReference is * valid and the listener is registered.) + * @param[in] metadata_changes Indicates whether metadata-only changes (i.e. + * only DocumentSnapshot.getMetadata() changed) should trigger snapshot + * events. * * @return A registration object that can be used to remove the listener. */ virtual ListenerRegistration AddSnapshotListener( - EventListener* listener); - - /** - * @brief Starts listening to the document referenced by this - * DocumentReference. - * - * @param[in] options The options to use for this listen. - * @param[in] listener The event listener that will be called with the - * snapshots, which must remain in memory until you remove the listener from - * this DocumentReference. (Ownership is not transferred; you are responsible - * for making sure that listener is valid as long as this DocumentReference is - * valid and the listener is registered.) - * - * @return A registration object that can be used to remove the listener. - */ - virtual ListenerRegistration AddSnapshotListener( - const DocumentListenOptions& options, - EventListener* listener); + EventListener* listener, + MetadataChanges metadata_changes = MetadataChanges::kExclude); #if defined(FIREBASE_USE_STD_FUNCTION) || defined(DOXYGEN) /** @@ -299,6 +282,9 @@ class DocumentReference { * * @param[in] callback function or lambda to call. When this function is * called, exactly one of the parameters will be non-null. + * @param[in] metadata_changes Indicates whether metadata-only changes (i.e. + * only DocumentSnapshot.getMetadata() changed) should trigger snapshot + * events. * * @return A registration object that can be used to remove the listener. * @@ -306,28 +292,21 @@ class DocumentReference { * std::function is not supported on STLPort. */ virtual ListenerRegistration AddSnapshotListener( - std::function callback); - - /** - * @brief Starts listening to the document referenced by this - * DocumentReference. - * - * @param[in] options The options to use for this listen. - * @param[in] callback function or lambda to call. When this function is - * called, exactly one of the parameters will be non-null. - * - * @return A registration object that can be used to remove the listener. - * - * @note This method is not available when using STLPort on Android, as - * std::function is not supported on STLPort. - */ - virtual ListenerRegistration AddSnapshotListener( - const DocumentListenOptions& options, - std::function callback); + std::function callback, + MetadataChanges metadata_changes = MetadataChanges::kExclude); #endif // defined(FIREBASE_USE_STD_FUNCTION) || defined(DOXYGEN) + + protected: + explicit DocumentReference(DocumentReferenceInternal* internal); + + private: + friend class FirestoreInternal; + + // TODO(zxu123): investigate possibility to use std::unique_ptr or + // firebase::UniquePtr. + DocumentReferenceInternal* internal_ = nullptr; }; -// TODO(rsgowman): probably define and inline here. bool operator==(const DocumentReference& lhs, const DocumentReference& rhs); inline bool operator!=(const DocumentReference& lhs, diff --git a/Firestore/core/include/firebase/firestore/document_snapshot.h b/Firestore/core/include/firebase/firestore/document_snapshot.h new file mode 100644 index 0000000..3be72b5 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/document_snapshot.h @@ -0,0 +1,38 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_SNAPSHOT_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_SNAPSHOT_H_ + +namespace firebase { +namespace firestore { + +/** + * A DocumentSnapshot contains data read from a document in your Firestore + * database. The data can be extracted with the data() method or by using + * FooValue() to access a specific field, where Foo is the type of that field. + * + * For a DocumentSnapshot that points to a non-existing document, any data + * access will cause a failed assertion. You can use the exists() method to + * explicitly verify a documents existence. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class DocumentSnapshot {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_DOCUMENT_SNAPSHOT_H_ diff --git a/Firestore/core/include/firebase/firestore/event_listener.h b/Firestore/core/include/firebase/firestore/event_listener.h index 6c94428..cbe8a28 100644 --- a/Firestore/core/include/firebase/firestore/event_listener.h +++ b/Firestore/core/include/firebase/firestore/event_listener.h @@ -22,19 +22,19 @@ #ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_EVENT_LISTENER_H_ #define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_EVENT_LISTENER_H_ +#include "firebase/firestore/firestore_errors.h" + namespace firebase { namespace firestore { -// TODO(rsgowman): replace these forward decl's with appropriate includes (once -// they exist) -class Error; - /** * @brief An interface for event listeners. */ template class EventListener { public: + virtual ~EventListener() { + } /** * @brief OnEvent will be called with the new value or the error if an error * occurred. @@ -44,7 +44,7 @@ class EventListener { * @param value The value of the event. null if there was an error. * @param error The error if there was error. null otherwise. */ - void OnEvent(const T* value, const Error* error); + virtual void OnEvent(const T* value, const Error* error) = 0; }; } // namespace firestore diff --git a/Firestore/core/include/firebase/firestore/field_path.h b/Firestore/core/include/firebase/firestore/field_path.h new file mode 100644 index 0000000..29e1dea --- /dev/null +++ b/Firestore/core/include/firebase/firestore/field_path.h @@ -0,0 +1,34 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_PATH_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_PATH_H_ + +namespace firebase { +namespace firestore { + +/** + * A FieldPath refers to a field in a document. The path may consist of a single + * field name (referring to a top level field in the document), or a list of + * field names (referring to a nested field in the document). + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class FieldPath {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_PATH_H_ diff --git a/Firestore/core/include/firebase/firestore/field_value.h b/Firestore/core/include/firebase/firestore/field_value.h new file mode 100644 index 0000000..d919de4 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/field_value.h @@ -0,0 +1,33 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_VALUE_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_VALUE_H_ + +namespace firebase { +namespace firestore { + +/** + * Sentinel values that can be used when writing document fields with setData() + * or updateData(). + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class FieldValue {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIELD_VALUE_H_ diff --git a/Firestore/core/include/firebase/firestore/firestore.h b/Firestore/core/include/firebase/firestore/firestore.h index 793fdd0..6591a72 100644 --- a/Firestore/core/include/firebase/firestore/firestore.h +++ b/Firestore/core/include/firebase/firestore/firestore.h @@ -22,23 +22,19 @@ #ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIRESTORE_H_ #define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_FIRESTORE_H_ +#include #include -// TODO(rsgowman): replace these forward decl's with appropriate includes (once -// they exist) -namespace firebase { -class App; -class InitResult; -} // namespace firebase +#include "firebase/app.h" +#include "firebase/firestore/collection_reference.h" +#include "firebase/firestore/document_reference.h" +#include "firebase/firestore/settings.h" namespace firebase { namespace firestore { -// TODO(rsgowman): replace these forward decl's with appropriate includes (once -// they exist) class DocumentReference; -class CollectionReference; -class Settings; +class FirestoreInternal; /** * @brief Entry point for the Firebase Firestore C++ SDK. @@ -152,6 +148,16 @@ class Firestore { /** Globally enables / disables Firestore logging for the SDK. */ static void set_logging_enabled(bool logging_enabled); + + Firestore(const Firestore& src) = delete; + Firestore& operator=(const Firestore& src) = delete; + + private: + explicit Firestore(::firebase::App* app); + + // TODO(zxu123): investigate possibility to use std::unique_ptr or + // firebase::UniquePtr. + FirestoreInternal* internal_ = nullptr; }; } // namespace firestore diff --git a/Firestore/core/include/firebase/firestore/firestore_errors.h b/Firestore/core/include/firebase/firestore/firestore_errors.h index 7a0ff7c..92c0c92 100644 --- a/Firestore/core/include/firebase/firestore/firestore_errors.h +++ b/Firestore/core/include/firebase/firestore/firestore_errors.h @@ -109,6 +109,10 @@ enum FirestoreErrorCode { Unauthenticated = 16 }; +// TODO(zxu123): decide whether we actually want an Error class or just use +// enum. +using Error = FirestoreErrorCode; + } // namespace firestore } // namespace firebase diff --git a/Firestore/core/include/firebase/firestore/listener_registration.h b/Firestore/core/include/firebase/firestore/listener_registration.h new file mode 100644 index 0000000..a37c2aa --- /dev/null +++ b/Firestore/core/include/firebase/firestore/listener_registration.h @@ -0,0 +1,92 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_LISTENER_REGISTRATION_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_LISTENER_REGISTRATION_H_ + +namespace firebase { +namespace firestore { + +class FirestoreInternal; +class ListenerRegistrationInternal; + +/** Represents a listener that can be removed by calling remove. */ +class ListenerRegistration { + public: + /** + * @brief Default constructor. This creates a no-op instance. + */ + ListenerRegistration(); + + /** + * @brief Copy constructor. It's totally okay to copy ListenerRegistration + * instances. + * + * @param[in] registration ListenerRegistration to copy from. + */ + ListenerRegistration(const ListenerRegistration& registration); + + /** + * @brief Move constructor. Moving is an efficient operation for + * ListenerRegistration instances. + * + * @param[in] registration ListenerRegistration to move data from. + */ + ListenerRegistration(ListenerRegistration&& registration); + + ~ListenerRegistration(); + + /** + * @brief Copy assignment operator. It's totally okay to copy + * ListenerRegistration instances. + * + * @param[in] registration ListenerRegistration to copy from. + * + * @returns Reference to the destination ListenerRegistration. + */ + ListenerRegistration& operator=(const ListenerRegistration& registration); + + /** + * @brief Move assignment operator. Moving is an efficient operation for + * ListenerRegistration instances. + * + * @param[in] registration ListenerRegistration to move data from. + * + * @returns Reference to the destination ListenerRegistration. + */ + ListenerRegistration& operator=(ListenerRegistration&& registration); + + /** + * Removes the listener being tracked by this ListenerRegistration. After the + * initial call, subsequent calls have no effect. + */ + void Remove(); + + private: + friend class DocumentReferenceInternal; + friend class ListenerRegistrationInternal; + friend class FirestoreInternal; + + explicit ListenerRegistration(ListenerRegistrationInternal* internal); + + FirestoreInternal* firestore_ = nullptr; + ListenerRegistrationInternal* internal_ = nullptr; +}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_LISTENER_REGISTRATION_H_ diff --git a/Firestore/core/include/firebase/firestore/query.h b/Firestore/core/include/firebase/firestore/query.h new file mode 100644 index 0000000..da6dfdd --- /dev/null +++ b/Firestore/core/include/firebase/firestore/query.h @@ -0,0 +1,33 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_H_ + +namespace firebase { +namespace firestore { + +/** + * A Query which you can read or listen to. You can also construct refined + * Query objects by adding filters and ordering. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class Query {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_H_ diff --git a/Firestore/core/include/firebase/firestore/query_snapshot.h b/Firestore/core/include/firebase/firestore/query_snapshot.h new file mode 100644 index 0000000..ffa2bd6 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/query_snapshot.h @@ -0,0 +1,34 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_SNAPSHOT_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_SNAPSHOT_H_ + +namespace firebase { +namespace firestore { + +/** + * A QuerySnapshot contains zero or more DocumentSnapshot objects. It can be + * iterated using a range-based for loop and its size can be inspected with + * empty() and count(). + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class QuerySnapshot {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_QUERY_SNAPSHOT_H_ diff --git a/Firestore/core/include/firebase/firestore/set_options.h b/Firestore/core/include/firebase/firestore/set_options.h new file mode 100644 index 0000000..802f3b5 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/set_options.h @@ -0,0 +1,39 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SET_OPTIONS_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SET_OPTIONS_H_ + +namespace firebase { +namespace firestore { + +/** + * An options object that configures the behavior of Set() calls. By providing + * the SetOptions objects returned by Merge(), the Set() methods in + * DocumentReference, WriteBatch and Transaction can be configured to perform + * granular merges instead of overwriting the target documents in their + * entirety. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class SetOptions { + public: + SetOptions(); +}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SET_OPTIONS_H_ diff --git a/Firestore/core/include/firebase/firestore/settings.h b/Firestore/core/include/firebase/firestore/settings.h new file mode 100644 index 0000000..9356b26 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/settings.h @@ -0,0 +1,32 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SETTINGS_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SETTINGS_H_ + +namespace firebase { +namespace firestore { + +class SettingsInternal; + +/** Settings used to configure a Firestore instance. */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class Settings {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SETTINGS_H_ diff --git a/Firestore/core/include/firebase/firestore/snapshot_metadata.h b/Firestore/core/include/firebase/firestore/snapshot_metadata.h new file mode 100644 index 0000000..9bcc54c --- /dev/null +++ b/Firestore/core/include/firebase/firestore/snapshot_metadata.h @@ -0,0 +1,46 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SNAPSHOT_METADATA_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SNAPSHOT_METADATA_H_ + +namespace firebase { +namespace firestore { + +/** Metadata about a snapshot, describing the state of the snapshot. */ +class SnapshotMetadata { + public: + SnapshotMetadata(bool has_pending_writes, bool is_from_cache) + : has_pending_writes_(has_pending_writes), is_from_cache_(is_from_cache) { + } + + bool has_pending_writes() const { + return has_pending_writes_; + } + + bool is_from_cache() const { + return is_from_cache_; + } + + private: + const bool has_pending_writes_; + const bool is_from_cache_; +}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_SNAPSHOT_METADATA_H_ diff --git a/Firestore/core/include/firebase/firestore/transaction.h b/Firestore/core/include/firebase/firestore/transaction.h new file mode 100644 index 0000000..be043b8 --- /dev/null +++ b/Firestore/core/include/firebase/firestore/transaction.h @@ -0,0 +1,32 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_TRANSACTION_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_TRANSACTION_H_ + +namespace firebase { +namespace firestore { + +/** + * Transaction provides methods to read and write data within a transaction. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class Transaction {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_TRANSACTION_H_ diff --git a/Firestore/core/include/firebase/firestore/write_batch.h b/Firestore/core/include/firebase/firestore/write_batch.h new file mode 100644 index 0000000..bd2c12f --- /dev/null +++ b/Firestore/core/include/firebase/firestore/write_batch.h @@ -0,0 +1,39 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_WRITE_BATCH_H_ +#define FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_WRITE_BATCH_H_ + +namespace firebase { +namespace firestore { + +/** + * A write batch is used to perform multiple writes as a single atomic unit. + * + * A WriteBatch object provides methods for adding writes to the write batch. + * None of the writes will be committed (or visible locally) until commit() is + * called. + * + * Unlike transactions, write batches are persisted offline and therefore are + * preferable when you don't need to condition your writes on read data. + */ +// TODO(zxu123): add more methods to complete the class and make it useful. +class WriteBatch {}; + +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_INCLUDE_FIREBASE_FIRESTORE_WRITE_BATCH_H_ -- cgit v1.2.3 From e318923d318151e503de03be53aef1a0cffc58e3 Mon Sep 17 00:00:00 2001 From: rsgowman Date: Mon, 28 May 2018 16:42:23 -0400 Subject: "Handle" BatchGetDocumentsResponse.transaction (by ignoring it) (#1318) --- .../core/src/firebase/firestore/remote/serializer.cc | 16 +++++++++------- .../test/firebase/firestore/remote/serializer_test.cc | 11 ++++++----- 2 files changed, 15 insertions(+), 12 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index 6ea5844..e06dcb4 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -504,7 +504,7 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( // Initialize BatchGetDocumentsResponse fields to their default values std::unique_ptr found; std::string missing; - // TODO(rsgowman): transaction + // We explicitly ignore the 'transaction' field SnapshotVersion read_time = SnapshotVersion::None(); while (reader->bytes_left()) { @@ -515,6 +515,7 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( switch (tag.field_number) { case google_firestore_v1beta1_BatchGetDocumentsResponse_found_tag: case google_firestore_v1beta1_BatchGetDocumentsResponse_missing_tag: + case google_firestore_v1beta1_BatchGetDocumentsResponse_transaction_tag: case google_firestore_v1beta1_BatchGetDocumentsResponse_read_time_tag: if (tag.wire_type != PB_WT_STRING) { reader->set_status( @@ -524,10 +525,6 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( } break; - case google_firestore_v1beta1_BatchGetDocumentsResponse_transaction_tag: - // TODO(rsgowman) - abort(); - default: reader->set_status(Status( FirestoreErrorCode::DataLoss, @@ -559,8 +556,13 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( break; case google_firestore_v1beta1_BatchGetDocumentsResponse_transaction_tag: - // TODO(rsgowman) - abort(); + // This field is ignored by the client sdk, but we still need to extract + // it. + // TODO(rsgowman) switch this to reader->SkipField() (or whatever we end + // up calling it) once that exists. Possibly group this with other + // ignored and/or unknown fields + reader->ReadString(); + break; case google_firestore_v1beta1_BatchGetDocumentsResponse_read_time_tag: read_time = SnapshotVersion{ diff --git a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc index ba9ea47..db13228 100644 --- a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc +++ b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc @@ -230,20 +230,21 @@ class SerializerTest : public ::testing::Test { /** * Creates entries in the proto that we don't care about. * - * We ignore create time in our serializer. We never set it, and never read it - * (other than to throw it away). But the server could (and probably does) set - * it, so we need to be able to discard it properly. The ExpectRoundTrip deals - * with this asymmetry. + * We ignore certain fields in our serializer. We never set them, and never + * read them (other than to throw them away). But the server could (and + * probably does) set them, so we need to be able to discard them properly. + * The ExpectRoundTrip deals with this asymmetry. * * This method adds these ignored fields to the proto. */ void TouchIgnoredBatchGetDocumentsResponseFields( v1beta1::BatchGetDocumentsResponse* proto) { + proto->set_transaction("random bytes"); + // TODO(rsgowman): This method currently assumes that this is a 'found' // document. We (probably) will need to adjust this to work with NoDocuments // too. v1beta1::Document* doc_proto = proto->mutable_found(); - google::protobuf::Timestamp* create_time_proto = doc_proto->mutable_create_time(); create_time_proto->set_seconds(8765); -- cgit v1.2.3 From 3fd7b456d5b58481fada7a31305bb21bb64dbd06 Mon Sep 17 00:00:00 2001 From: rsgowman Date: Tue, 29 May 2018 10:33:10 -0400 Subject: Handle deserializing BatchGetDocumentsResponse error case... (#1344) ... where neither 'found' nor 'missing' fields set. --- .../src/firebase/firestore/remote/serializer.cc | 7 ++-- .../firebase/firestore/remote/serializer_test.cc | 47 +++++++++++++++------- 2 files changed, 37 insertions(+), 17 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index e06dcb4..ccc5ac3 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -583,9 +583,10 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( } else if (!missing.empty()) { return absl::make_unique(DecodeKey(missing), read_time); } else { - // Neither 'found' nor 'missing' fields were set. - // TODO(rsgowman): Handle the error case. - abort(); + reader->set_status(Status(FirestoreErrorCode::DataLoss, + "Invalid BatchGetDocumentsReponse message: " + "Neither 'found' nor 'missing' fields set.")); + return nullptr; } } diff --git a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc index db13228..999acb8 100644 --- a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc +++ b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc @@ -146,13 +146,21 @@ class SerializerTest : public ::testing::Test { * * @param status the expected (failed) status. Only the code() is verified. */ - void ExpectFailedStatusDuringDecode(Status status, - const std::vector& bytes) { + void ExpectFailedStatusDuringFieldValueDecode( + Status status, const std::vector& bytes) { StatusOr bad_status = serializer.DecodeFieldValue(bytes); ASSERT_NOT_OK(bad_status); EXPECT_EQ(status.code(), bad_status.status().code()); } + void ExpectFailedStatusDuringMaybeDocumentDecode( + Status status, const std::vector& bytes) { + StatusOr> bad_status = + serializer.DecodeMaybeDocument(bytes); + ASSERT_NOT_OK(bad_status); + EXPECT_EQ(status.code(), bad_status.status().code()); + } + v1beta1::Value ValueProto(nullptr_t) { std::vector bytes = EncodeFieldValue(&serializer, FieldValue::NullValue()); @@ -473,7 +481,7 @@ TEST_F(SerializerTest, BadNullValue) { // Alter the null value from 0 to 1. Mutate(&bytes[1], /*expected_initial_value=*/0, /*new_value=*/1); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -484,7 +492,7 @@ TEST_F(SerializerTest, BadBoolValue) { // Alter the bool value from 1 to 2. (Value values are 0,1) Mutate(&bytes[1], /*expected_initial_value=*/1, /*new_value=*/2); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -503,7 +511,7 @@ TEST_F(SerializerTest, BadIntegerValue) { bytes.resize(12); bytes[11] = 0x7f; - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -515,7 +523,7 @@ TEST_F(SerializerTest, BadStringValue) { // used by the encoded tag.) Mutate(&bytes[2], /*expected_initial_value=*/1, /*new_value=*/5); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -526,7 +534,7 @@ TEST_F(SerializerTest, BadTimestampValue_TooLarge) { // Add some time, which should push us above the maximum allowed timestamp. Mutate(&bytes[4], 0x82, 0x83); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -537,7 +545,7 @@ TEST_F(SerializerTest, BadTimestampValue_TooSmall) { // Remove some time, which should push us below the minimum allowed timestamp. Mutate(&bytes[4], 0x92, 0x91); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -556,9 +564,9 @@ TEST_F(SerializerTest, BadTag) { // status. Remove this EXPECT_ANY_THROW statement (and reenable the // following commented out statement) once the corresponding assert has been // removed from serializer.cc. - EXPECT_ANY_THROW(ExpectFailedStatusDuringDecode( + EXPECT_ANY_THROW(ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes)); - // ExpectFailedStatusDuringDecode( + // ExpectFailedStatusDuringFieldValueDecode( // Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -571,7 +579,7 @@ TEST_F(SerializerTest, TagVarintWiretypeStringMismatch) { // would do.) Mutate(&bytes[0], /*expected_initial_value=*/0x08, /*new_value=*/0x0a); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -582,7 +590,7 @@ TEST_F(SerializerTest, TagStringWiretypeVarintMismatch) { // 0x88 represents a string value encoded as a varint. Mutate(&bytes[0], /*expected_initial_value=*/0x8a, /*new_value=*/0x88); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -595,13 +603,13 @@ TEST_F(SerializerTest, IncompleteFieldValue) { ASSERT_EQ(0x00, bytes[1]); bytes.pop_back(); - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } TEST_F(SerializerTest, IncompleteTag) { std::vector bytes; - ExpectFailedStatusDuringDecode( + ExpectFailedStatusDuringFieldValueDecode( Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } @@ -714,5 +722,16 @@ TEST_F(SerializerTest, DecodesNoDocument) { ExpectNoDocumentDeserializationRoundTrip(key, read_time, proto); } +TEST_F(SerializerTest, DecodeMaybeDocWithoutFoundOrMissingSetShouldFail) { + v1beta1::BatchGetDocumentsResponse proto; + + std::vector bytes(proto.ByteSizeLong()); + bool status = proto.SerializeToArray(bytes.data(), bytes.size()); + EXPECT_TRUE(status); + + ExpectFailedStatusDuringMaybeDocumentDecode( + Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); +} + // TODO(rsgowman): Test [en|de]coding multiple protos into the same output // vector. -- cgit v1.2.3 From 2a24b363a9351e40d80fbe7b9b92836203a147cb Mon Sep 17 00:00:00 2001 From: rsgowman Date: Wed, 30 May 2018 10:05:40 -0400 Subject: Allow repeated entries in Value proto. (#1346) Normally, this would be unexpected, as only a single entry in the Value proto *should* be present. However, the proto docs state that parsers should be able to handle repeated fields. (In the case of repeated fields, the last one "wins".) --- .../src/firebase/firestore/remote/serializer.cc | 147 ++++++++++++--------- .../firebase/firestore/remote/serializer_test.cc | 56 ++++++++ 2 files changed, 139 insertions(+), 64 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index ccc5ac3..03fbb1a 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -167,77 +167,96 @@ void EncodeFieldValueImpl(Writer* writer, const FieldValue& field_value) { FieldValue DecodeFieldValueImpl(Reader* reader) { if (!reader->status().ok()) return FieldValue::NullValue(); - Tag tag = reader->ReadTag(); - if (!reader->status().ok()) return FieldValue::NullValue(); + // There needs to be at least one entry in the FieldValue. + if (reader->bytes_left() == 0) { + reader->set_status(Status(FirestoreErrorCode::DataLoss, + "Input Value proto missing contents")); + return FieldValue::NullValue(); + } - // Ensure the tag matches the wire type - switch (tag.field_number) { - case google_firestore_v1beta1_Value_null_value_tag: - case google_firestore_v1beta1_Value_boolean_value_tag: - case google_firestore_v1beta1_Value_integer_value_tag: - if (tag.wire_type != PB_WT_VARINT) { - reader->set_status( - Status(FirestoreErrorCode::DataLoss, - "Input proto bytes cannot be parsed (mismatch between " - "the wiretype and the field number (tag))")); - } - break; + FieldValue result = FieldValue::NullValue(); - case google_firestore_v1beta1_Value_string_value_tag: - case google_firestore_v1beta1_Value_timestamp_value_tag: - case google_firestore_v1beta1_Value_map_value_tag: - if (tag.wire_type != PB_WT_STRING) { - reader->set_status( - Status(FirestoreErrorCode::DataLoss, - "Input proto bytes cannot be parsed (mismatch between " - "the wiretype and the field number (tag))")); - } - break; + while (reader->bytes_left()) { + Tag tag = reader->ReadTag(); + if (!reader->status().ok()) return FieldValue::NullValue(); - default: - // We could get here for one of two reasons; either because the input - // bytes are corrupt, or because we're attempting to parse a tag that we - // haven't implemented yet. Long term, the latter reason should become - // less likely (especially in production), so we'll assume former. - - // TODO(rsgowman): While still in development, we'll contradict the above - // and assume the latter. Remove the following assertion when we're - // confident that we're handling all the tags in the protos. - HARD_FAIL( - "Unhandled message field number (tag): %s. (Or possibly " - "corrupt input bytes)", - tag.field_number); - reader->set_status(Status( - FirestoreErrorCode::DataLoss, - "Input proto bytes cannot be parsed (invalid field number (tag))")); - } + // Ensure the tag matches the wire type + switch (tag.field_number) { + case google_firestore_v1beta1_Value_null_value_tag: + case google_firestore_v1beta1_Value_boolean_value_tag: + case google_firestore_v1beta1_Value_integer_value_tag: + if (tag.wire_type != PB_WT_VARINT) { + reader->set_status( + Status(FirestoreErrorCode::DataLoss, + "Input proto bytes cannot be parsed (mismatch between " + "the wiretype and the field number (tag))")); + } + break; - if (!reader->status().ok()) return FieldValue::NullValue(); + case google_firestore_v1beta1_Value_string_value_tag: + case google_firestore_v1beta1_Value_timestamp_value_tag: + case google_firestore_v1beta1_Value_map_value_tag: + if (tag.wire_type != PB_WT_STRING) { + reader->set_status( + Status(FirestoreErrorCode::DataLoss, + "Input proto bytes cannot be parsed (mismatch between " + "the wiretype and the field number (tag))")); + } + break; - switch (tag.field_number) { - case google_firestore_v1beta1_Value_null_value_tag: - reader->ReadNull(); - return FieldValue::NullValue(); - case google_firestore_v1beta1_Value_boolean_value_tag: - return FieldValue::BooleanValue(reader->ReadBool()); - case google_firestore_v1beta1_Value_integer_value_tag: - return FieldValue::IntegerValue(reader->ReadInteger()); - case google_firestore_v1beta1_Value_string_value_tag: - return FieldValue::StringValue(reader->ReadString()); - case google_firestore_v1beta1_Value_timestamp_value_tag: - return FieldValue::TimestampValue( - reader->ReadNestedMessage(DecodeTimestamp)); - case google_firestore_v1beta1_Value_map_value_tag: - return FieldValue::ObjectValueFromMap( - reader->ReadNestedMessage(DecodeMapValue)); + default: + // We could get here for one of two reasons; either because the input + // bytes are corrupt, or because we're attempting to parse a tag that we + // haven't implemented yet. Long term, the latter reason should become + // less likely (especially in production), so we'll assume former. + + // TODO(rsgowman): While still in development, we'll contradict the + // above and assume the latter. Remove the following assertion when + // we're confident that we're handling all the tags in the protos. + HARD_FAIL("Unhandled message field number (tag): %i.", + tag.field_number); + reader->set_status(Status( + FirestoreErrorCode::DataLoss, + "Input proto bytes cannot be parsed (invalid field number (tag))")); + } - default: - // This indicates an internal error as we've already ensured that this is - // a valid field_number. - HARD_FAIL( - "Somehow got an unexpected field number (tag) after verifying that " - "the field number was expected."); + if (!reader->status().ok()) return FieldValue::NullValue(); + + switch (tag.field_number) { + case google_firestore_v1beta1_Value_null_value_tag: + reader->ReadNull(); + result = FieldValue::NullValue(); + break; + case google_firestore_v1beta1_Value_boolean_value_tag: + result = FieldValue::BooleanValue(reader->ReadBool()); + break; + case google_firestore_v1beta1_Value_integer_value_tag: + result = FieldValue::IntegerValue(reader->ReadInteger()); + break; + case google_firestore_v1beta1_Value_string_value_tag: + result = FieldValue::StringValue(reader->ReadString()); + break; + case google_firestore_v1beta1_Value_timestamp_value_tag: + result = FieldValue::TimestampValue( + reader->ReadNestedMessage(DecodeTimestamp)); + break; + case google_firestore_v1beta1_Value_map_value_tag: + // TODO(rsgowman): We should merge the existing map (if any) with the + // newly parsed map. + result = FieldValue::ObjectValueFromMap( + reader->ReadNestedMessage(DecodeMapValue)); + break; + + default: + // This indicates an internal error as we've already ensured that this + // is a valid field_number. + HARD_FAIL( + "Somehow got an unexpected field number (tag) after verifying that " + "the field number was expected."); + } } + + return result; } /** diff --git a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc index 999acb8..96ffa9e 100644 --- a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc +++ b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc @@ -474,6 +474,62 @@ TEST_F(SerializerTest, EncodesNestedObjects) { ExpectRoundTrip(model, proto, FieldValue::Type::Object); } +TEST_F(SerializerTest, EncodesFieldValuesWithRepeatedEntries) { + // Technically, serialized Value protos can contain multiple values. (The last + // one "wins".) However, well-behaved proto emitters (such as libprotobuf) + // won't generate that, so to test, we either need to use hand-crafted, raw + // bytes or use a proto message that's *almost* the same as the real one, such + // that when it's encoded, you can generate these repeated fields. (This is + // how libprotobuf tests itself.) + // + // Using libprotobuf for this purpose is mildly inconvenient for us, since we + // don't run protoc as part of the build process, so we'd need to either add + // these fake messages to our protos tree (Protos/testprotos?) and then check + // in the results (which isn't great when writing new tests). Fortunately, we + // have another alternative: nanopb. + // + // So we'll create a nanopb struct that *looks* like + // google_firestore_v1beta1_Value, and then populate and serialize it using + // the normal nanopb mechanisms. This should give us a wire-compatible Value + // message, but with multiple values set. + + // Copy of the real one (from the nanopb generated document.pb.h), but with + // only boolean_value and integer_value. + struct google_firestore_v1beta1_Value_Fake { + bool boolean_value; + int64_t integer_value; + }; + + // Copy of the real one (from the nanopb generated document.pb.c), but with + // only boolean_value and integer_value. + const pb_field_t google_firestore_v1beta1_Value_fields_Fake[2] = { + PB_FIELD(1, BOOL, SINGULAR, STATIC, FIRST, + google_firestore_v1beta1_Value_Fake, boolean_value, + boolean_value, 0), + PB_FIELD(2, INT64, SINGULAR, STATIC, OTHER, + google_firestore_v1beta1_Value_Fake, integer_value, + boolean_value, 0), + }; + + // Craft the bytes. boolean_value has a smaller tag, so it'll get encoded + // first. Implying integer_value should "win". + google_firestore_v1beta1_Value_Fake crafty_value{false, int64_t{42}}; + std::vector bytes(128); + pb_ostream_t stream = pb_ostream_from_buffer(bytes.data(), bytes.size()); + pb_encode(&stream, google_firestore_v1beta1_Value_fields_Fake, &crafty_value); + bytes.resize(stream.bytes_written); + + // Decode the bytes into the model + StatusOr actual_model_status = serializer.DecodeFieldValue(bytes); + EXPECT_OK(actual_model_status); + FieldValue actual_model = actual_model_status.ValueOrDie(); + + // Ensure the decoded model is as expected. + FieldValue expected_model = FieldValue::IntegerValue(42); + EXPECT_EQ(FieldValue::Type::Integer, actual_model.type()); + EXPECT_EQ(expected_model, actual_model); +} + TEST_F(SerializerTest, BadNullValue) { std::vector bytes = EncodeFieldValue(&serializer, FieldValue::NullValue()); -- cgit v1.2.3 From 03d26a76a0f7efb7ed3bb142a8e558fb68e4cccf Mon Sep 17 00:00:00 2001 From: Gil Date: Wed, 30 May 2018 10:24:40 -0700 Subject: Remove nearly all usages of WrapNSStringNoCopy (#1351) --- Firestore/Source/API/FIRFirestore.mm | 4 ++-- Firestore/Source/API/FSTUserDataConverter.mm | 19 +++++++++++-------- Firestore/Source/Core/FSTQuery.mm | 3 ++- Firestore/Source/Local/FSTLevelDB.mm | 6 +++--- Firestore/Source/Model/FSTFieldValue.mm | 7 +++---- .../core/src/firebase/firestore/util/comparison.cc | 6 ++++++ .../core/src/firebase/firestore/util/comparison.h | 5 +++++ .../src/firebase/firestore/util/hard_assert_apple.mm | 4 ++-- 8 files changed, 34 insertions(+), 20 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/Source/API/FIRFirestore.mm b/Firestore/Source/API/FIRFirestore.mm index 3671b51..fb4a1ec 100644 --- a/Firestore/Source/API/FIRFirestore.mm +++ b/Firestore/Source/API/FIRFirestore.mm @@ -128,11 +128,11 @@ extern "C" NSString *const FIRFirestoreErrorDomain = @"FIRFirestoreErrorDomain"; @"Failed to get FirebaseApp instance. Please call FirebaseApp.configure() " @"before using Firestore"); } - return [self firestoreForApp:app database:util::WrapNSStringNoCopy(DatabaseId::kDefault)]; + return [self firestoreForApp:app database:util::WrapNSString(DatabaseId::kDefault)]; } + (instancetype)firestoreForApp:(FIRApp *)app { - return [self firestoreForApp:app database:util::WrapNSStringNoCopy(DatabaseId::kDefault)]; + return [self firestoreForApp:app database:util::WrapNSString(DatabaseId::kDefault)]; } // TODO(b/62410906): make this public diff --git a/Firestore/Source/API/FSTUserDataConverter.mm b/Firestore/Source/API/FSTUserDataConverter.mm index 44e46da..d73a870 100644 --- a/Firestore/Source/API/FSTUserDataConverter.mm +++ b/Firestore/Source/API/FSTUserDataConverter.mm @@ -17,6 +17,7 @@ #import "Firestore/Source/API/FSTUserDataConverter.h" #include +#include #include #include @@ -41,6 +42,7 @@ #include "Firestore/core/src/firebase/firestore/util/hard_assert.h" #include "Firestore/core/src/firebase/firestore/util/string_apple.h" #include "absl/memory/memory.h" +#include "absl/strings/match.h" namespace util = firebase::firestore::util; using firebase::firestore::model::ArrayTransform; @@ -55,7 +57,7 @@ using firebase::firestore::model::TransformOperation; NS_ASSUME_NONNULL_BEGIN -static NSString *const RESERVED_FIELD_DESIGNATOR = @"__"; +static const char *RESERVED_FIELD_DESIGNATOR = "__"; #pragma mark - FSTParsedSetData @@ -277,7 +279,7 @@ typedef NS_ENUM(NSInteger, FSTUserDataSource) { arrayElement:NO fieldTransforms:_fieldTransforms fieldMask:_fieldMask]; - [context validatePathSegment:fieldName]; + [context validatePathSegment:util::MakeStringView(fieldName)]; return context; } @@ -334,15 +336,16 @@ typedef NS_ENUM(NSInteger, FSTUserDataSource) { if (_path == nullptr) { return; } - for (const auto &segment : *_path) { - [self validatePathSegment:util::WrapNSStringNoCopy(segment)]; + for (const std::string &segment : *_path) { + [self validatePathSegment:segment]; } } -- (void)validatePathSegment:(NSString *)segment { - if ([self isWrite] && [segment hasPrefix:RESERVED_FIELD_DESIGNATOR] && - [segment hasSuffix:RESERVED_FIELD_DESIGNATOR]) { - FSTThrowInvalidArgument(@"Document fields cannot begin and end with %@%@", +- (void)validatePathSegment:(absl::string_view)segment { + absl::string_view designator{RESERVED_FIELD_DESIGNATOR}; + if ([self isWrite] && absl::StartsWith(segment, designator) && + absl::EndsWith(segment, designator)) { + FSTThrowInvalidArgument(@"Document fields cannot begin and end with %s%@", RESERVED_FIELD_DESIGNATOR, [self fieldDescription]); } } diff --git a/Firestore/Source/Core/FSTQuery.mm b/Firestore/Source/Core/FSTQuery.mm index eb6d087..abec474 100644 --- a/Firestore/Source/Core/FSTQuery.mm +++ b/Firestore/Source/Core/FSTQuery.mm @@ -753,7 +753,8 @@ NSString *FSTStringFromQueryRelationOperator(FSTRelationFilterOperator filterOpe return _canonicalID; } - NSMutableString *canonicalID = [util::WrapNSStringNoCopy(_path.CanonicalString()) mutableCopy]; + NSMutableString *canonicalID = [NSMutableString string]; + [canonicalID appendFormat:@"%s", _path.CanonicalString().c_str()]; // Add filters. [canonicalID appendString:@"|f:"]; diff --git a/Firestore/Source/Local/FSTLevelDB.mm b/Firestore/Source/Local/FSTLevelDB.mm index 321d47a..9f75a3e 100644 --- a/Firestore/Source/Local/FSTLevelDB.mm +++ b/Firestore/Source/Local/FSTLevelDB.mm @@ -114,10 +114,10 @@ using leveldb::WriteOptions; // projectIDs are DNS-compatible names and cannot contain dots so there's // no danger of collisions. NSString *directory = documentsDirectory; - directory = [directory - stringByAppendingPathComponent:util::WrapNSStringNoCopy(databaseInfo.persistence_key())]; + directory = + [directory stringByAppendingPathComponent:util::WrapNSString(databaseInfo.persistence_key())]; - NSString *segment = util::WrapNSStringNoCopy(databaseInfo.database_id().project_id()); + NSString *segment = util::WrapNSString(databaseInfo.database_id().project_id()); if (!databaseInfo.database_id().IsDefaultDatabase()) { segment = [NSString stringWithFormat:@"%@.%s", segment, databaseInfo.database_id().database_id().c_str()]; diff --git a/Firestore/Source/Model/FSTFieldValue.mm b/Firestore/Source/Model/FSTFieldValue.mm index 6a13511..4acae7d 100644 --- a/Firestore/Source/Model/FSTFieldValue.mm +++ b/Firestore/Source/Model/FSTFieldValue.mm @@ -690,13 +690,12 @@ static NSComparisonResult CompareBytes(NSData *left, NSData *right) { - (NSComparisonResult)compare:(FSTFieldValue *)other { if ([other isKindOfClass:[FSTReferenceValue class]]) { FSTReferenceValue *ref = (FSTReferenceValue *)other; - NSComparisonResult cmp = [util::WrapNSStringNoCopy(self.databaseID->project_id()) - compare:util::WrapNSStringNoCopy(ref.databaseID->project_id())]; + NSComparisonResult cmp = + WrapCompare(self.databaseID->project_id(), ref.databaseID->project_id()); if (cmp != NSOrderedSame) { return cmp; } - cmp = [util::WrapNSStringNoCopy(self.databaseID->database_id()) - compare:util::WrapNSStringNoCopy(ref.databaseID->database_id())]; + cmp = WrapCompare(self.databaseID->database_id(), ref.databaseID->database_id()); return cmp != NSOrderedSame ? cmp : [self.key compare:ref.key]; } else { return [self defaultCompare:other]; diff --git a/Firestore/core/src/firebase/firestore/util/comparison.cc b/Firestore/core/src/firebase/firestore/util/comparison.cc index 5ac4c27..d1cdbfa 100644 --- a/Firestore/core/src/firebase/firestore/util/comparison.cc +++ b/Firestore/core/src/firebase/firestore/util/comparison.cc @@ -31,6 +31,12 @@ bool Comparator::operator()( return left < right; } +bool Comparator::operator()(const std::string& left, + const std::string& right) const { + // TODO(wilhuff): truncation aware comparison + return left < right; +} + bool Comparator::operator()(double left, double right) const { // NaN sorts equal to itself and before any other number. if (left < right) { diff --git a/Firestore/core/src/firebase/firestore/util/comparison.h b/Firestore/core/src/firebase/firestore/util/comparison.h index d7f4dfd..a7d7944 100644 --- a/Firestore/core/src/firebase/firestore/util/comparison.h +++ b/Firestore/core/src/firebase/firestore/util/comparison.h @@ -86,6 +86,11 @@ struct Comparator { const absl::string_view& right) const; }; +template <> +struct Comparator { + bool operator()(const std::string& left, const std::string& right) const; +}; + /** Compares two bools: false < true. */ template <> struct Comparator : public std::less {}; diff --git a/Firestore/core/src/firebase/firestore/util/hard_assert_apple.mm b/Firestore/core/src/firebase/firestore/util/hard_assert_apple.mm index 3324fe8..6abd324 100644 --- a/Firestore/core/src/firebase/firestore/util/hard_assert_apple.mm +++ b/Firestore/core/src/firebase/firestore/util/hard_assert_apple.mm @@ -32,8 +32,8 @@ void Fail(const char* file, const int line, const std::string& message) { [[NSAssertionHandler currentHandler] - handleFailureInFunction:WrapNSStringNoCopy(func) - file:WrapNSStringNoCopy(file) + handleFailureInFunction:WrapNSString(func) + file:WrapNSString(file) lineNumber:line description:@"FIRESTORE INTERNAL ASSERTION FAILED: %s", message.c_str()]; -- cgit v1.2.3 From bb546e19885ae084823e0315e93564a44c0a8257 Mon Sep 17 00:00:00 2001 From: Gil Date: Fri, 1 Jun 2018 13:42:47 -0700 Subject: Fix Firestore compilation under Xcode < 9.2 (#1367) * Don't rely on specialization failure to determine when std::hash is unavailable. Instead manually declare the conditions under which std::hash should be defined. * Fix detection of Objective-C classes in Xcode < 9.2 std::is_base_of{} is false there so the overloads defined for Objective-C types weren't getting enabled. * Add explicit tests for StringFormat using Objective-C objects * Add explicit tests for HasStdHash --- .../Example/Firestore.xcodeproj/project.pbxproj | 8 ++ Firestore/Source/Remote/FSTSerializerBeta.mm | 2 +- .../src/firebase/firestore/util/CMakeLists.txt | 1 + .../core/src/firebase/firestore/util/hashing.h | 39 +++++++++- .../src/firebase/firestore/util/string_format.h | 28 +++---- .../core/src/firebase/firestore/util/type_traits.h | 90 ++++++++++++++++++++++ .../test/firebase/firestore/util/CMakeLists.txt | 9 +++ .../test/firebase/firestore/util/hashing_test.cc | 18 +++++ .../firestore/util/string_format_apple_test.mm | 60 +++++++++++++++ .../firestore/util/type_traits_apple_test.mm | 50 ++++++++++++ 10 files changed, 283 insertions(+), 22 deletions(-) create mode 100644 Firestore/core/src/firebase/firestore/util/type_traits.h create mode 100644 Firestore/core/test/firebase/firestore/util/string_format_apple_test.mm create mode 100644 Firestore/core/test/firebase/firestore/util/type_traits_apple_test.mm (limited to 'Firestore/core') diff --git a/Firestore/Example/Firestore.xcodeproj/project.pbxproj b/Firestore/Example/Firestore.xcodeproj/project.pbxproj index ca8b598..9207ad2 100644 --- a/Firestore/Example/Firestore.xcodeproj/project.pbxproj +++ b/Firestore/Example/Firestore.xcodeproj/project.pbxproj @@ -24,6 +24,7 @@ /* End PBXAggregateTarget section */ /* Begin PBXBuildFile section */ + 0535C1B65DADAE1CE47FA3CA /* string_format_apple_test.mm in Sources */ = {isa = PBXBuildFile; fileRef = 9CFD366B783AE27B9E79EE7A /* string_format_apple_test.mm */; }; 132E3E53179DE287D875F3F2 /* FSTLevelDBTransactionTests.mm in Sources */ = {isa = PBXBuildFile; fileRef = 132E36BB104830BD806351AC /* FSTLevelDBTransactionTests.mm */; }; 3B843E4C1F3A182900548890 /* remote_store_spec_test.json in Resources */ = {isa = PBXBuildFile; fileRef = 3B843E4A1F3930A400548890 /* remote_store_spec_test.json */; }; 54131E9720ADE679001DF3FF /* string_format_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 54131E9620ADE678001DF3FF /* string_format_test.cc */; }; @@ -180,6 +181,7 @@ B6FB4690208F9BB300554BA2 /* executor_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = B6FB4688208F9B9100554BA2 /* executor_test.cc */; }; BF219E98F1C5A1DAEB5EEC86 /* Pods_Firestore_Example_iOS_SwiftBuildTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 379B34A1536045869826D82A /* Pods_Firestore_Example_iOS_SwiftBuildTest.framework */; }; C1AA536F90A0A576CA2816EB /* Pods_Firestore_Example_iOS_Firestore_SwiftTests_iOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BB92EB03E3F92485023F64ED /* Pods_Firestore_Example_iOS_Firestore_SwiftTests_iOS.framework */; }; + C80B10E79CDD7EF7843C321E /* type_traits_apple_test.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2A0CF41BA5AED6049B0BEB2C /* type_traits_apple_test.mm */; }; C8D3CE2343E53223E6487F2C /* Pods_Firestore_Example_iOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5918805E993304321A05E82B /* Pods_Firestore_Example_iOS.framework */; }; DE03B2D41F2149D600A30B9C /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F5AF195388D20070C39A /* XCTest.framework */; }; DE03B2D51F2149D600A30B9C /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F591195388D20070C39A /* UIKit.framework */; }; @@ -251,6 +253,7 @@ 1277F98C20D2DF0867496976 /* Pods-Firestore_IntegrationTests_iOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Firestore_IntegrationTests_iOS.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Firestore_IntegrationTests_iOS/Pods-Firestore_IntegrationTests_iOS.debug.xcconfig"; sourceTree = ""; }; 12F4357299652983A615F886 /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = ""; }; 132E36BB104830BD806351AC /* FSTLevelDBTransactionTests.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FSTLevelDBTransactionTests.mm; sourceTree = ""; }; + 2A0CF41BA5AED6049B0BEB2C /* type_traits_apple_test.mm */ = {isa = PBXFileReference; includeInIndex = 1; path = type_traits_apple_test.mm; sourceTree = ""; }; 2B50B3A0DF77100EEE887891 /* Pods_Firestore_Tests_iOS.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Firestore_Tests_iOS.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 379B34A1536045869826D82A /* Pods_Firestore_Example_iOS_SwiftBuildTest.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Firestore_Example_iOS_SwiftBuildTest.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 3B843E4A1F3930A400548890 /* remote_store_spec_test.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = remote_store_spec_test.json; sourceTree = ""; }; @@ -399,6 +402,7 @@ 74ACEC3603BE58B57A7E8D4C /* Pods-Firestore_Example_iOS-SwiftBuildTest.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Firestore_Example_iOS-SwiftBuildTest.release.xcconfig"; path = "Pods/Target Support Files/Pods-Firestore_Example_iOS-SwiftBuildTest/Pods-Firestore_Example_iOS-SwiftBuildTest.release.xcconfig"; sourceTree = ""; }; 873B8AEA1B1F5CCA007FD442 /* Main.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = Main.storyboard; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 8E002F4AD5D9B6197C940847 /* Firestore.podspec */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = Firestore.podspec; path = ../Firestore.podspec; sourceTree = ""; }; + 9CFD366B783AE27B9E79EE7A /* string_format_apple_test.mm */ = {isa = PBXFileReference; includeInIndex = 1; path = string_format_apple_test.mm; sourceTree = ""; }; AB356EF6200EA5EB0089B766 /* field_value_test.cc */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = field_value_test.cc; sourceTree = ""; }; AB380CF82019382300D97691 /* target_id_generator_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = target_id_generator_test.cc; sourceTree = ""; }; AB380CFC201A2EE200D97691 /* string_util_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = string_util_test.cc; sourceTree = ""; }; @@ -558,8 +562,10 @@ 54A0352C20A3B3D7003E0143 /* status_test.cc */, 54A0352B20A3B3D7003E0143 /* status_test_util.h */, 54A0352D20A3B3D7003E0143 /* statusor_test.cc */, + 9CFD366B783AE27B9E79EE7A /* string_format_apple_test.mm */, 54131E9620ADE678001DF3FF /* string_format_test.cc */, AB380CFC201A2EE200D97691 /* string_util_test.cc */, + 2A0CF41BA5AED6049B0BEB2C /* type_traits_apple_test.mm */, ); path = util; sourceTree = ""; @@ -1557,6 +1563,7 @@ 549CCA5020A36DBC00BCEB75 /* sorted_set_test.cc in Sources */, 54A0352F20A3B3D8003E0143 /* status_test.cc in Sources */, 54A0353020A3B3D8003E0143 /* statusor_test.cc in Sources */, + 0535C1B65DADAE1CE47FA3CA /* string_format_apple_test.mm in Sources */, 54131E9720ADE679001DF3FF /* string_format_test.cc in Sources */, AB380CFE201A2F4500D97691 /* string_util_test.cc in Sources */, AB380CFB2019388600D97691 /* target_id_generator_test.cc in Sources */, @@ -1565,6 +1572,7 @@ ABC1D7E12023A40C00BA84F0 /* token_test.cc in Sources */, 54A0352720A3AED0003E0143 /* transform_operations_test.mm in Sources */, 549CCA5120A36DBC00BCEB75 /* tree_sorted_map_test.cc in Sources */, + C80B10E79CDD7EF7843C321E /* type_traits_apple_test.mm in Sources */, ABC1D7DE2023A05300BA84F0 /* user_test.cc in Sources */, ); runOnlyForDeploymentPostprocessing = 0; diff --git a/Firestore/Source/Remote/FSTSerializerBeta.mm b/Firestore/Source/Remote/FSTSerializerBeta.mm index ab40dd6..263fe6d 100644 --- a/Firestore/Source/Remote/FSTSerializerBeta.mm +++ b/Firestore/Source/Remote/FSTSerializerBeta.mm @@ -921,7 +921,7 @@ NS_ASSUME_NONNULL_BEGIN } else if ([filter isKindOfClass:[FSTNullFilter class]]) { proto.unaryFilter.op = GCFSStructuredQuery_UnaryFilter_Operator_IsNull; } else { - HARD_FAIL("Unrecognized filter: %s", static_cast(filter)); + HARD_FAIL("Unrecognized filter: %s", filter); } return proto; } diff --git a/Firestore/core/src/firebase/firestore/util/CMakeLists.txt b/Firestore/core/src/firebase/firestore/util/CMakeLists.txt index 043713f..ed3a301 100644 --- a/Firestore/core/src/firebase/firestore/util/CMakeLists.txt +++ b/Firestore/core/src/firebase/firestore/util/CMakeLists.txt @@ -200,6 +200,7 @@ cc_library( statusor_internals.h string_util.cc string_util.h + type_traits.h DEPENDS absl_base firebase_firestore_util_base diff --git a/Firestore/core/src/firebase/firestore/util/hashing.h b/Firestore/core/src/firebase/firestore/util/hashing.h index d8058c8..21c0bd6 100644 --- a/Firestore/core/src/firebase/firestore/util/hashing.h +++ b/Firestore/core/src/firebase/firestore/util/hashing.h @@ -18,6 +18,7 @@ #define FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_UTIL_HASHING_H_ #include +#include #include namespace firebase { @@ -48,6 +49,41 @@ namespace util { namespace impl { +/** + * A type trait that identifies whether or not std::hash is available for a + * given type. + * + * This type should not be necessary since specialization failure on an + * expression like `decltype(std::hash{}(value)` should be enough to disable + * overloads that require `std::hash` to be defined but unfortunately some + * standard libraries ship with std::hash defined for all types that only + * fail later (e.g. via static_assert). One such implementation is the libc++ + * that ships with Xcode 8.3.3, which is a supported platform. + */ +template +struct has_std_hash { + // There may be other types for which std::hash is defined but they don't + // matter for our purposes. + enum { + value = std::is_arithmetic{} || std::is_pointer{} || + std::is_same{} + }; + + constexpr operator bool() const { + return value; + } +}; + +/** + * A type that's equivalent to size_t if std::hash is defined or a compile + * error otherwise. + * + * This is effectively just a safe implementation of + * `decltype(std::hash{}(std::declval()))`. + */ +template +using std_hash_type = typename std::enable_if{}, size_t>::type; + /** * Combines a hash_value with whatever accumulated state there is so far. */ @@ -100,8 +136,7 @@ auto RankedInvokeHash(const K& value, HashChoice<0>) -> decltype(value.Hash()) { * @return The result of `std::hash{}(value)` */ template -auto RankedInvokeHash(const K& value, HashChoice<1>) - -> decltype(std::hash{}(value)) { +std_hash_type RankedInvokeHash(const K& value, HashChoice<1>) { return std::hash{}(value); } diff --git a/Firestore/core/src/firebase/firestore/util/string_format.h b/Firestore/core/src/firebase/firestore/util/string_format.h index d691984..01776a9 100644 --- a/Firestore/core/src/firebase/firestore/util/string_format.h +++ b/Firestore/core/src/firebase/firestore/util/string_format.h @@ -22,6 +22,7 @@ #include #include "Firestore/core/src/firebase/firestore/util/string_apple.h" +#include "Firestore/core/src/firebase/firestore/util/type_traits.h" #include "absl/base/attributes.h" #include "absl/strings/str_cat.h" #include "absl/strings/string_view.h" @@ -43,7 +44,7 @@ template struct FormatChoice : FormatChoice {}; template <> -struct FormatChoice<4> {}; +struct FormatChoice<5> {}; } // namespace internal @@ -87,8 +88,8 @@ class FormatArg : public absl::AlphaNum { */ template < typename T, - typename = typename std::enable_if{}>::type> - FormatArg(T* object, internal::FormatChoice<0>) + typename = typename std::enable_if{}>::type> + FormatArg(T object, internal::FormatChoice<1>) : AlphaNum{MakeStringView([object description])} { } @@ -96,20 +97,9 @@ class FormatArg : public absl::AlphaNum { * Creates a FormatArg from any Objective-C Class type. Objective-C Class * types are a special struct that aren't of a type derived from NSObject. */ - FormatArg(Class object, internal::FormatChoice<0>) + FormatArg(Class object, internal::FormatChoice<1>) : AlphaNum{MakeStringView(NSStringFromClass(object))} { } - - /** - * Creates a FormatArg from any id pointer. Note that instances of `id` - * (which means "pointer conforming to the protocol Foo") do not match this - * without first casting to type `id`. There's no way to express a template of - * `id` since `id` isn't actually a C++ template and `id` isn't a - * parameterized C++ class. - */ - FormatArg(id object, internal::FormatChoice<0>) - : AlphaNum{MakeStringView([object description])} { - } #endif /** @@ -117,7 +107,7 @@ class FormatArg : public absl::AlphaNum { * handled specially to avoid ambiguity with generic pointers, which are * handled differently. */ - FormatArg(std::nullptr_t, internal::FormatChoice<1>) : AlphaNum{"null"} { + FormatArg(std::nullptr_t, internal::FormatChoice<2>) : AlphaNum{"null"} { } /** @@ -125,7 +115,7 @@ class FormatArg : public absl::AlphaNum { * handled specially to avoid ambiguity with generic pointers, which are * handled differently. */ - FormatArg(const char* string_value, internal::FormatChoice<2>) + FormatArg(const char* string_value, internal::FormatChoice<3>) : AlphaNum{string_value == nullptr ? "null" : string_value} { } @@ -134,7 +124,7 @@ class FormatArg : public absl::AlphaNum { * hexidecimal integer literal. */ template - FormatArg(T* pointer_value, internal::FormatChoice<3>) + FormatArg(T* pointer_value, internal::FormatChoice<4>) : AlphaNum{absl::Hex{reinterpret_cast(pointer_value)}} { } @@ -143,7 +133,7 @@ class FormatArg : public absl::AlphaNum { * absl::AlphaNum accepts. */ template - FormatArg(T&& value, internal::FormatChoice<4>) + FormatArg(T&& value, internal::FormatChoice<5>) : AlphaNum{std::forward(value)} { } }; diff --git a/Firestore/core/src/firebase/firestore/util/type_traits.h b/Firestore/core/src/firebase/firestore/util/type_traits.h new file mode 100644 index 0000000..52feb6b --- /dev/null +++ b/Firestore/core/src/firebase/firestore/util/type_traits.h @@ -0,0 +1,90 @@ +/* + * 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. + */ + +#ifndef FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_UTIL_TYPE_TRAITS_H_ +#define FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_UTIL_TYPE_TRAITS_H_ + +#if __OBJC__ +#import // for id +#endif + +#include + +namespace firebase { +namespace firestore { +namespace util { + +#if __OBJC__ + +/** + * A type trait that identifies whether or not the given pointer points to an + * Objective-C object. + * + * is_objective_c_pointer::value == true + * is_objective_c_pointer*>::value == true + * + * // id is a dynamically typed pointer to an Objective-C object. + * is_objective_c_pointer::value == true + * + * // pointers to C++ classes are not Objective-C pointers. + * is_objective_c_pointer::value == false + * is_objective_c_pointer::value == false + * is_objective_c_pointer>::value == false + */ +template +struct is_objective_c_pointer { + private: + using yes_type = char (&)[10]; + using no_type = char (&)[1]; + + /** + * A non-existent function declared to produce a pointer to type T (which is + * consistent with the way Objective-C objects are referenced). + * + * Note that there is no definition for this function but that's okay because + * we only need it to reason about the function's type at compile type. + */ + static T Pointer(); + + static yes_type Choose(id value); + static no_type Choose(...); + + public: + using value_type = bool; + + enum { value = sizeof(Choose(Pointer())) == sizeof(yes_type) }; + + constexpr operator bool() const { + return value; + } + + constexpr bool operator()() const { + return value; + } +}; + +// Hard-code the answer for `void` because you can't pass arguments of type +// `void` to another function. +template <> +struct is_objective_c_pointer : public std::false_type {}; + +#endif // __OBJC__ + +} // namespace util +} // namespace firestore +} // namespace firebase + +#endif // FIRESTORE_CORE_SRC_FIREBASE_FIRESTORE_UTIL_TYPE_TRAITS_H_ diff --git a/Firestore/core/test/firebase/firestore/util/CMakeLists.txt b/Firestore/core/test/firebase/firestore/util/CMakeLists.txt index bcb1c84..c07a4ea 100644 --- a/Firestore/core/test/firebase/firestore/util/CMakeLists.txt +++ b/Firestore/core/test/firebase/firestore/util/CMakeLists.txt @@ -137,3 +137,12 @@ cc_test( firebase_firestore_util gmock ) + +if(APPLE) + target_sources( + firebase_firestore_util_test + PUBLIC + string_format_apple_test.mm + type_traits_apple_test.mm + ) +endif() diff --git a/Firestore/core/test/firebase/firestore/util/hashing_test.cc b/Firestore/core/test/firebase/firestore/util/hashing_test.cc index e5d9ff8..2c5c2f7 100644 --- a/Firestore/core/test/firebase/firestore/util/hashing_test.cc +++ b/Firestore/core/test/firebase/firestore/util/hashing_test.cc @@ -16,6 +16,9 @@ #include "Firestore/core/src/firebase/firestore/util/hashing.h" +#include +#include + #include "absl/strings/string_view.h" #include "gtest/gtest.h" @@ -29,6 +32,21 @@ struct HasHashMember { } }; +TEST(HashingTest, HasStdHash) { + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + EXPECT_TRUE(impl::has_std_hash::value); + + struct Foo {}; + EXPECT_FALSE(impl::has_std_hash::value); + EXPECT_FALSE(impl::has_std_hash::value); + EXPECT_FALSE((impl::has_std_hash>::value)); +} + TEST(HashingTest, Int) { ASSERT_EQ(std::hash{}(0), Hash(0)); } diff --git a/Firestore/core/test/firebase/firestore/util/string_format_apple_test.mm b/Firestore/core/test/firebase/firestore/util/string_format_apple_test.mm new file mode 100644 index 0000000..f0bcd35 --- /dev/null +++ b/Firestore/core/test/firebase/firestore/util/string_format_apple_test.mm @@ -0,0 +1,60 @@ +/* + * 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. + */ + +#include "Firestore/core/src/firebase/firestore/util/string_format.h" + +#import + +#include "gtest/gtest.h" + +@interface FSTDescribable : NSObject +@end + +@implementation FSTDescribable + +- (NSString*)description { + return @"description"; +} + +@end + +namespace firebase { +namespace firestore { +namespace util { + +TEST(StringFormatTest, NSString) { + EXPECT_EQ("Hello World", StringFormat("Hello %s", @"World")); + + NSString* hello = [NSString stringWithUTF8String:"Hello"]; + EXPECT_EQ("Hello World", StringFormat("%s World", hello)); + + // NOLINTNEXTLINE false positive on "string" + NSMutableString* world = [NSMutableString string]; + [world appendString:@"World"]; + EXPECT_EQ("Hello World", StringFormat("Hello %s", world)); +} + +TEST(StringFormatTest, FSTDescribable) { + FSTDescribable* desc = [[FSTDescribable alloc] init]; + EXPECT_EQ("Hello description", StringFormat("Hello %s", desc)); + + id desc_id = desc; + EXPECT_EQ("Hello description", StringFormat("Hello %s", desc_id)); +} + +} // namespace util +} // namespace firestore +} // namespace firebase diff --git a/Firestore/core/test/firebase/firestore/util/type_traits_apple_test.mm b/Firestore/core/test/firebase/firestore/util/type_traits_apple_test.mm new file mode 100644 index 0000000..dfb03bb --- /dev/null +++ b/Firestore/core/test/firebase/firestore/util/type_traits_apple_test.mm @@ -0,0 +1,50 @@ +/* + * 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. + */ + +#include "Firestore/core/src/firebase/firestore/util/type_traits.h" + +#import +#import +#import + +#include "gtest/gtest.h" + +namespace firebase { +namespace firestore { +namespace util { + +TEST(TypeTraitsTest, IsObjectiveCPointer) { + static_assert(is_objective_c_pointer{}, "NSObject"); + static_assert(is_objective_c_pointer{}, "NSString"); + static_assert(is_objective_c_pointer*>{}, + "NSArray"); + + static_assert(is_objective_c_pointer{}, "id"); + static_assert(is_objective_c_pointer>{}, "id"); + + static_assert(!is_objective_c_pointer{}, "int*"); + static_assert(!is_objective_c_pointer{}, "void*"); + static_assert(!is_objective_c_pointer{}, "int"); + static_assert(!is_objective_c_pointer{}, "void"); + + struct Foo {}; + static_assert(!is_objective_c_pointer{}, "Foo"); + static_assert(!is_objective_c_pointer{}, "Foo"); +} + +} // namespace util +} // namespace firestore +} // namespace firebase -- cgit v1.2.3 From ce61f4e0e654e7a16dad023e1b8df32449d5a00f Mon Sep 17 00:00:00 2001 From: rsgowman Date: Mon, 4 Jun 2018 13:02:31 -0400 Subject: Rename nanopb generated headers from foo.pb.h to foo.nanopb.h (#1371) This avoids a collision with the libprotobuf generated files. Also removes the "well-known" cpp protos, relying on libprotobuf to supply these instead. --- Firestore/Protos/CMakeLists.txt | 44 +- Firestore/Protos/build-protos.sh | 20 +- Firestore/Protos/cpp/google/protobuf/any.pb.cc | 456 ---- Firestore/Protos/cpp/google/protobuf/any.pb.h | 339 --- Firestore/Protos/cpp/google/protobuf/empty.pb.cc | 358 --- Firestore/Protos/cpp/google/protobuf/empty.pb.h | 206 -- Firestore/Protos/cpp/google/protobuf/struct.pb.cc | 1491 ----------- Firestore/Protos/cpp/google/protobuf/struct.pb.h | 1046 -------- .../Protos/cpp/google/protobuf/timestamp.pb.cc | 447 ---- .../Protos/cpp/google/protobuf/timestamp.pb.h | 248 -- .../Protos/cpp/google/protobuf/wrappers.pb.cc | 2812 -------------------- Firestore/Protos/cpp/google/protobuf/wrappers.pb.h | 1503 ----------- .../nanopb/firestore/local/maybe_document.nanopb.h | 88 + .../nanopb/firestore/local/maybe_document.pb.c | 4 +- .../nanopb/firestore/local/maybe_document.pb.h | 88 - .../nanopb/firestore/local/mutation.nanopb.h | 87 + .../Protos/nanopb/firestore/local/mutation.pb.c | 4 +- .../Protos/nanopb/firestore/local/mutation.pb.h | 87 - .../Protos/nanopb/firestore/local/target.nanopb.h | 100 + .../Protos/nanopb/firestore/local/target.pb.c | 4 +- .../Protos/nanopb/firestore/local/target.pb.h | 100 - .../Protos/nanopb/google/api/annotations.nanopb.h | 44 + .../Protos/nanopb/google/api/annotations.pb.c | 4 +- .../Protos/nanopb/google/api/annotations.pb.h | 44 - Firestore/Protos/nanopb/google/api/http.nanopb.h | 107 + Firestore/Protos/nanopb/google/api/http.pb.c | 4 +- Firestore/Protos/nanopb/google/api/http.pb.h | 107 - .../google/firestore/v1beta1/common.nanopb.h | 124 + .../nanopb/google/firestore/v1beta1/common.pb.c | 4 +- .../nanopb/google/firestore/v1beta1/common.pb.h | 124 - .../google/firestore/v1beta1/document.nanopb.h | 155 ++ .../nanopb/google/firestore/v1beta1/document.pb.c | 4 +- .../nanopb/google/firestore/v1beta1/document.pb.h | 155 -- .../google/firestore/v1beta1/firestore.nanopb.h | 508 ++++ .../nanopb/google/firestore/v1beta1/firestore.pb.c | 4 +- .../nanopb/google/firestore/v1beta1/firestore.pb.h | 508 ---- .../nanopb/google/firestore/v1beta1/query.nanopb.h | 241 ++ .../nanopb/google/firestore/v1beta1/query.pb.c | 4 +- .../nanopb/google/firestore/v1beta1/query.pb.h | 241 -- .../nanopb/google/firestore/v1beta1/write.nanopb.h | 189 ++ .../nanopb/google/firestore/v1beta1/write.pb.c | 4 +- .../nanopb/google/firestore/v1beta1/write.pb.h | 189 -- .../Protos/nanopb/google/protobuf/any.nanopb.h | 69 + Firestore/Protos/nanopb/google/protobuf/any.pb.c | 4 +- Firestore/Protos/nanopb/google/protobuf/any.pb.h | 69 - .../Protos/nanopb/google/protobuf/empty.nanopb.h | 66 + Firestore/Protos/nanopb/google/protobuf/empty.pb.c | 4 +- Firestore/Protos/nanopb/google/protobuf/empty.pb.h | 66 - .../Protos/nanopb/google/protobuf/struct.nanopb.h | 117 + .../Protos/nanopb/google/protobuf/struct.pb.c | 4 +- .../Protos/nanopb/google/protobuf/struct.pb.h | 117 - .../nanopb/google/protobuf/timestamp.nanopb.h | 69 + .../Protos/nanopb/google/protobuf/timestamp.pb.c | 4 +- .../Protos/nanopb/google/protobuf/timestamp.pb.h | 69 - .../nanopb/google/protobuf/wrappers.nanopb.h | 147 + .../Protos/nanopb/google/protobuf/wrappers.pb.c | 4 +- .../Protos/nanopb/google/protobuf/wrappers.pb.h | 147 - Firestore/Protos/nanopb/google/rpc/status.nanopb.h | 73 + Firestore/Protos/nanopb/google/rpc/status.pb.c | 4 +- Firestore/Protos/nanopb/google/rpc/status.pb.h | 73 - .../Protos/nanopb/google/type/latlng.nanopb.h | 69 + Firestore/Protos/nanopb/google/type/latlng.pb.c | 4 +- Firestore/Protos/nanopb/google/type/latlng.pb.h | 69 - .../core/src/firebase/firestore/nanopb/reader.cc | 2 +- .../core/src/firebase/firestore/nanopb/writer.cc | 2 +- .../src/firebase/firestore/remote/serializer.cc | 4 +- scripts/style.sh | 1 + 67 files changed, 2325 insertions(+), 11228 deletions(-) delete mode 100644 Firestore/Protos/cpp/google/protobuf/any.pb.cc delete mode 100644 Firestore/Protos/cpp/google/protobuf/any.pb.h delete mode 100644 Firestore/Protos/cpp/google/protobuf/empty.pb.cc delete mode 100644 Firestore/Protos/cpp/google/protobuf/empty.pb.h delete mode 100644 Firestore/Protos/cpp/google/protobuf/struct.pb.cc delete mode 100644 Firestore/Protos/cpp/google/protobuf/struct.pb.h delete mode 100644 Firestore/Protos/cpp/google/protobuf/timestamp.pb.cc delete mode 100644 Firestore/Protos/cpp/google/protobuf/timestamp.pb.h delete mode 100644 Firestore/Protos/cpp/google/protobuf/wrappers.pb.cc delete mode 100644 Firestore/Protos/cpp/google/protobuf/wrappers.pb.h create mode 100644 Firestore/Protos/nanopb/firestore/local/maybe_document.nanopb.h delete mode 100644 Firestore/Protos/nanopb/firestore/local/maybe_document.pb.h create mode 100644 Firestore/Protos/nanopb/firestore/local/mutation.nanopb.h delete mode 100644 Firestore/Protos/nanopb/firestore/local/mutation.pb.h create mode 100644 Firestore/Protos/nanopb/firestore/local/target.nanopb.h delete mode 100644 Firestore/Protos/nanopb/firestore/local/target.pb.h create mode 100644 Firestore/Protos/nanopb/google/api/annotations.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/api/annotations.pb.h create mode 100644 Firestore/Protos/nanopb/google/api/http.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/api/http.pb.h create mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/common.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.h create mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h create mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.h create mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/query.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.h create mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/write.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.h create mode 100644 Firestore/Protos/nanopb/google/protobuf/any.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/protobuf/any.pb.h create mode 100644 Firestore/Protos/nanopb/google/protobuf/empty.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/protobuf/empty.pb.h create mode 100644 Firestore/Protos/nanopb/google/protobuf/struct.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/protobuf/struct.pb.h create mode 100644 Firestore/Protos/nanopb/google/protobuf/timestamp.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/protobuf/timestamp.pb.h create mode 100644 Firestore/Protos/nanopb/google/protobuf/wrappers.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/protobuf/wrappers.pb.h create mode 100644 Firestore/Protos/nanopb/google/rpc/status.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/rpc/status.pb.h create mode 100644 Firestore/Protos/nanopb/google/type/latlng.nanopb.h delete mode 100644 Firestore/Protos/nanopb/google/type/latlng.pb.h (limited to 'Firestore/core') diff --git a/Firestore/Protos/CMakeLists.txt b/Firestore/Protos/CMakeLists.txt index c589a0f..5c0fda0 100644 --- a/Firestore/Protos/CMakeLists.txt +++ b/Firestore/Protos/CMakeLists.txt @@ -2,39 +2,39 @@ cc_library( firebase_firestore_protos_nanopb SOURCES nanopb/firestore/local/maybe_document.pb.c - nanopb/firestore/local/maybe_document.pb.h + nanopb/firestore/local/maybe_document.nanopb.h nanopb/firestore/local/mutation.pb.c - nanopb/firestore/local/mutation.pb.h + nanopb/firestore/local/mutation.nanopb.h nanopb/firestore/local/target.pb.c - nanopb/firestore/local/target.pb.h + nanopb/firestore/local/target.nanopb.h nanopb/google/api/annotations.pb.c - nanopb/google/api/annotations.pb.h + nanopb/google/api/annotations.nanopb.h nanopb/google/api/http.pb.c - nanopb/google/api/http.pb.h + nanopb/google/api/http.nanopb.h nanopb/google/firestore/v1beta1/common.pb.c - nanopb/google/firestore/v1beta1/common.pb.h + nanopb/google/firestore/v1beta1/common.nanopb.h nanopb/google/firestore/v1beta1/document.pb.c - nanopb/google/firestore/v1beta1/document.pb.h + nanopb/google/firestore/v1beta1/document.nanopb.h nanopb/google/firestore/v1beta1/firestore.pb.c - nanopb/google/firestore/v1beta1/firestore.pb.h + nanopb/google/firestore/v1beta1/firestore.nanopb.h nanopb/google/firestore/v1beta1/query.pb.c - nanopb/google/firestore/v1beta1/query.pb.h + nanopb/google/firestore/v1beta1/query.nanopb.h nanopb/google/firestore/v1beta1/write.pb.c - nanopb/google/firestore/v1beta1/write.pb.h + nanopb/google/firestore/v1beta1/write.nanopb.h nanopb/google/protobuf/any.pb.c - nanopb/google/protobuf/any.pb.h + nanopb/google/protobuf/any.nanopb.h nanopb/google/protobuf/empty.pb.c - nanopb/google/protobuf/empty.pb.h + nanopb/google/protobuf/empty.nanopb.h nanopb/google/protobuf/struct.pb.c - nanopb/google/protobuf/struct.pb.h + nanopb/google/protobuf/struct.nanopb.h nanopb/google/protobuf/timestamp.pb.c - nanopb/google/protobuf/timestamp.pb.h + nanopb/google/protobuf/timestamp.nanopb.h nanopb/google/protobuf/wrappers.pb.c - nanopb/google/protobuf/wrappers.pb.h + nanopb/google/protobuf/wrappers.nanopb.h nanopb/google/rpc/status.pb.c - nanopb/google/rpc/status.pb.h + nanopb/google/rpc/status.nanopb.h nanopb/google/type/latlng.pb.c - nanopb/google/type/latlng.pb.h + nanopb/google/type/latlng.nanopb.h DEPENDS nanopb ) @@ -77,16 +77,6 @@ cc_library( cpp/google/firestore/v1beta1/query.pb.h cpp/google/firestore/v1beta1/write.pb.cc cpp/google/firestore/v1beta1/write.pb.h - cpp/google/protobuf/any.pb.cc - cpp/google/protobuf/any.pb.h - cpp/google/protobuf/empty.pb.cc - cpp/google/protobuf/empty.pb.h - cpp/google/protobuf/struct.pb.cc - cpp/google/protobuf/struct.pb.h - cpp/google/protobuf/timestamp.pb.cc - cpp/google/protobuf/timestamp.pb.h - cpp/google/protobuf/wrappers.pb.cc - cpp/google/protobuf/wrappers.pb.h cpp/google/rpc/status.pb.cc cpp/google/rpc/status.pb.h cpp/google/type/latlng.pb.cc diff --git a/Firestore/Protos/build-protos.sh b/Firestore/Protos/build-protos.sh index d55ed55..2745a41 100755 --- a/Firestore/Protos/build-protos.sh +++ b/Firestore/Protos/build-protos.sh @@ -27,24 +27,36 @@ pod update --nanopb_out="--options-file=protos/%s.options:nanopb" \ `find protos -name *.proto -print | xargs` -# Remove "well-known" protos from objc. (We get these for free. We only need -# them for nanopb.) +# Remove "well-known" protos from objc and cpp. (We get these for free. We only +# need them for nanopb.) rm -rf objc/google/protobuf/ +rm -rf cpp/google/protobuf # If a proto uses a field named 'delete', nanopb happily uses that in the # message definition. Works fine for C; not so much for C++. Rename uses of this # to delete_ (which is how protoc does it for c++ files.) perl -i -pe 's/\bdelete\b/delete_/g' `find nanopb -type f` +# Rename nanopb's headers from foo.pb.h to foo.nanopb.h. This avoids collisions +# with libprotobuf. +for f in $(find nanopb -name \*.pb.h); do + mv "$f" "${f%.pb.h}.nanopb.h" +done + +# Adjust include paths to match +for f in $(find nanopb -name \*.h -or -name \*.c); do + perl -i -pe 's/(#include .*)\.pb\.h/\1.nanopb.h/' $f +done + # CocoaPods does not like paths in library imports, flatten them. -for i in `find objc -name "*.[mh]"` ; do +for i in $(find objc -name "*.[mh]"); do perl -i -pe 's#import ".*/#import "#' $i; done # Remove the unnecessary extensionRegistry functions. -for i in `find objc -name "*.[m]" ` ; do +for i in $(find objc -name "*.[m]"); do ./strip-registry.py $i done diff --git a/Firestore/Protos/cpp/google/protobuf/any.pb.cc b/Firestore/Protos/cpp/google/protobuf/any.pb.cc deleted file mode 100644 index 6f7c576..0000000 --- a/Firestore/Protos/cpp/google/protobuf/any.pb.cc +++ /dev/null @@ -1,456 +0,0 @@ -/* - * 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/protobuf/any.proto - -#include - -#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 protobuf { -class AnyDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Any_default_instance_; -} // namespace protobuf -} // namespace google -namespace protobuf_google_2fprotobuf_2fany_2eproto { -void InitDefaultsAnyImpl() { - 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::protobuf::_Any_default_instance_; - new (ptr) ::google::protobuf::Any(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Any::InitAsDefaultInstance(); -} - -void InitDefaultsAny() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsAnyImpl); -} - -::google::protobuf::Metadata file_level_metadata[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::protobuf::Any, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Any, type_url_), - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Any, value_), -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - { 0, -1, sizeof(::google::protobuf::Any)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::google::protobuf::_Any_default_instance_), -}; - -void protobuf_AssignDescriptors() { - AddDescriptors(); - ::google::protobuf::MessageFactory* factory = NULL; - AssignDescriptors( - "google/protobuf/any.proto", schemas, file_default_instances, TableStruct::offsets, factory, - file_level_metadata, NULL, 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, 1); -} - -void AddDescriptorsImpl() { - InitDefaults(); - static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - "\n\031google/protobuf/any.proto\022\017google.prot" - "obuf\"&\n\003Any\022\020\n\010type_url\030\001 \001(\t\022\r\n\005value\030\002" - " \001(\014Bo\n\023com.google.protobufB\010AnyProtoP\001Z" - "%github.com/golang/protobuf/ptypes/any\242\002" - "\003GPB\252\002\036Google.Protobuf.WellKnownTypesb\006p" - "roto3" - }; - ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( - descriptor, 205); - ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( - "google/protobuf/any.proto", &protobuf_RegisterTypes); -} - -void AddDescriptors() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); -} -// Force AddDescriptors() to be called at dynamic initialization time. -struct StaticDescriptorInitializer { - StaticDescriptorInitializer() { - AddDescriptors(); - } -} static_descriptor_initializer; -} // namespace protobuf_google_2fprotobuf_2fany_2eproto -namespace google { -namespace protobuf { - -// =================================================================== - -void Any::InitAsDefaultInstance() { -} -void Any::PackFrom(const ::google::protobuf::Message& message) { - _any_metadata_.PackFrom(message); -} - -void Any::PackFrom(const ::google::protobuf::Message& message, - const ::std::string& type_url_prefix) { - _any_metadata_.PackFrom(message, type_url_prefix); -} - -bool Any::UnpackTo(::google::protobuf::Message* message) const { - return _any_metadata_.UnpackTo(message); -} - -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Any::kTypeUrlFieldNumber; -const int Any::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Any::Any() - : ::google::protobuf::Message(), _internal_metadata_(NULL), _any_metadata_(&type_url_, &value_) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fany_2eproto::InitDefaultsAny(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Any) -} -Any::Any(const Any& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0), - _any_metadata_(&type_url_, &value_) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.type_url().size() > 0) { - type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_url_); - } - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.value().size() > 0) { - value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value_); - } - // @@protoc_insertion_point(copy_constructor:google.protobuf.Any) -} - -void Any::SharedCtor() { - type_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - _cached_size_ = 0; -} - -Any::~Any() { - // @@protoc_insertion_point(destructor:google.protobuf.Any) - SharedDtor(); -} - -void Any::SharedDtor() { - type_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} - -void Any::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Any::descriptor() { - ::protobuf_google_2fprotobuf_2fany_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fany_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Any& Any::default_instance() { - ::protobuf_google_2fprotobuf_2fany_2eproto::InitDefaultsAny(); - return *internal_default_instance(); -} - -Any* Any::New(::google::protobuf::Arena* arena) const { - Any* n = new Any; - if (arena != NULL) { - arena->Own(n); - } - return n; -} - -void Any::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Any) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - type_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - value_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - _internal_metadata_.Clear(); -} - -bool Any::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.protobuf.Any) - 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 type_url = 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_type_url())); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->type_url().data(), static_cast(this->type_url().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "google.protobuf.Any.type_url")); - } else { - goto handle_unusual; - } - break; - } - - // bytes value = 2; - case 2: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(18u /* 18 & 0xFF */)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( - input, this->mutable_value())); - } 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.protobuf.Any) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Any) - return false; -#undef DO_ -} - -void Any::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Any) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // string type_url = 1; - if (this->type_url().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->type_url().data(), static_cast(this->type_url().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Any.type_url"); - ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( - 1, this->type_url(), output); - } - - // bytes value = 2; - if (this->value().size() > 0) { - ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( - 2, this->value(), 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.protobuf.Any) -} - -::google::protobuf::uint8* Any::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Any) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // string type_url = 1; - if (this->type_url().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->type_url().data(), static_cast(this->type_url().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Any.type_url"); - target = - ::google::protobuf::internal::WireFormatLite::WriteStringToArray( - 1, this->type_url(), target); - } - - // bytes value = 2; - if (this->value().size() > 0) { - target = - ::google::protobuf::internal::WireFormatLite::WriteBytesToArray( - 2, this->value(), 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.protobuf.Any) - return target; -} - -size_t Any::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Any) - 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 type_url = 1; - if (this->type_url().size() > 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::StringSize( - this->type_url()); - } - - // bytes value = 2; - if (this->value().size() > 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::BytesSize( - this->value()); - } - - 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 Any::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Any) - GOOGLE_DCHECK_NE(&from, this); - const Any* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Any) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Any) - MergeFrom(*source); - } -} - -void Any::MergeFrom(const Any& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Any) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.type_url().size() > 0) { - - type_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_url_); - } - if (from.value().size() > 0) { - - value_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value_); - } -} - -void Any::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Any) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Any::CopyFrom(const Any& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Any) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Any::IsInitialized() const { - return true; -} - -void Any::Swap(Any* other) { - if (other == this) return; - InternalSwap(other); -} -void Any::InternalSwap(Any* other) { - using std::swap; - type_url_.Swap(&other->type_url_); - value_.Swap(&other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Any::GetMetadata() const { - protobuf_google_2fprotobuf_2fany_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fany_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) diff --git a/Firestore/Protos/cpp/google/protobuf/any.pb.h b/Firestore/Protos/cpp/google/protobuf/any.pb.h deleted file mode 100644 index 98a8f3e..0000000 --- a/Firestore/Protos/cpp/google/protobuf/any.pb.h +++ /dev/null @@ -1,339 +0,0 @@ -/* - * 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/protobuf/any.proto - -#ifndef PROTOBUF_google_2fprotobuf_2fany_2eproto__INCLUDED -#define PROTOBUF_google_2fprotobuf_2fany_2eproto__INCLUDED - -#include - -#include - -#if GOOGLE_PROTOBUF_VERSION < 3005000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -#include -// @@protoc_insertion_point(includes) - -namespace protobuf_google_2fprotobuf_2fany_2eproto { -// Internal implementation detail -- do not use these members. -struct TableStruct { - static const ::google::protobuf::internal::ParseTableField entries[]; - static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; - static const ::google::protobuf::internal::ParseTable schema[1]; - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors(); -void InitDefaultsAnyImpl(); -void InitDefaultsAny(); -inline void InitDefaults() { - InitDefaultsAny(); -} -} // namespace protobuf_google_2fprotobuf_2fany_2eproto -namespace google { -namespace protobuf { -class Any; -class AnyDefaultTypeInternal; -extern AnyDefaultTypeInternal _Any_default_instance_; -} // namespace protobuf -} // namespace google -namespace google { -namespace protobuf { - -// =================================================================== - -class Any : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Any) */ { - public: - Any(); - virtual ~Any(); - - Any(const Any& from); - - inline Any& operator=(const Any& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Any(Any&& from) noexcept - : Any() { - *this = ::std::move(from); - } - - inline Any& operator=(Any&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - static const ::google::protobuf::Descriptor* descriptor(); - static const Any& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Any* internal_default_instance() { - return reinterpret_cast( - &_Any_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 0; - - // implements Any ----------------------------------------------- - - void PackFrom(const ::google::protobuf::Message& message); - void PackFrom(const ::google::protobuf::Message& message, - const ::std::string& type_url_prefix); - bool UnpackTo(::google::protobuf::Message* message) const; - template bool Is() const { - return _any_metadata_.Is(); - } - - void Swap(Any* other); - friend void swap(Any& a, Any& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Any* New() const PROTOBUF_FINAL { return New(NULL); } - - Any* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Any& from); - void MergeFrom(const Any& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Any* other); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return NULL; - } - inline void* MaybeArenaPtr() const { - return NULL; - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // string type_url = 1; - void clear_type_url(); - static const int kTypeUrlFieldNumber = 1; - const ::std::string& type_url() const; - void set_type_url(const ::std::string& value); - #if LANG_CXX11 - void set_type_url(::std::string&& value); - #endif - void set_type_url(const char* value); - void set_type_url(const char* value, size_t size); - ::std::string* mutable_type_url(); - ::std::string* release_type_url(); - void set_allocated_type_url(::std::string* type_url); - - // bytes value = 2; - void clear_value(); - static const int kValueFieldNumber = 2; - const ::std::string& value() const; - void set_value(const ::std::string& value); - #if LANG_CXX11 - void set_value(::std::string&& value); - #endif - void set_value(const char* value); - void set_value(const void* value, size_t size); - ::std::string* mutable_value(); - ::std::string* release_value(); - void set_allocated_value(::std::string* value); - - // @@protoc_insertion_point(class_scope:google.protobuf.Any) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - ::google::protobuf::internal::ArenaStringPtr type_url_; - ::google::protobuf::internal::ArenaStringPtr value_; - mutable int _cached_size_; - ::google::protobuf::internal::AnyMetadata _any_metadata_; - friend struct ::protobuf_google_2fprotobuf_2fany_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fany_2eproto::InitDefaultsAnyImpl(); -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// Any - -// string type_url = 1; -inline void Any::clear_type_url() { - type_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline const ::std::string& Any::type_url() const { - // @@protoc_insertion_point(field_get:google.protobuf.Any.type_url) - return type_url_.GetNoArena(); -} -inline void Any::set_type_url(const ::std::string& value) { - - type_url_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value); - // @@protoc_insertion_point(field_set:google.protobuf.Any.type_url) -} -#if LANG_CXX11 -inline void Any::set_type_url(::std::string&& value) { - - type_url_.SetNoArena( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value)); - // @@protoc_insertion_point(field_set_rvalue:google.protobuf.Any.type_url) -} -#endif -inline void Any::set_type_url(const char* value) { - GOOGLE_DCHECK(value != NULL); - - type_url_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value)); - // @@protoc_insertion_point(field_set_char:google.protobuf.Any.type_url) -} -inline void Any::set_type_url(const char* value, size_t size) { - - type_url_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - ::std::string(reinterpret_cast(value), size)); - // @@protoc_insertion_point(field_set_pointer:google.protobuf.Any.type_url) -} -inline ::std::string* Any::mutable_type_url() { - - // @@protoc_insertion_point(field_mutable:google.protobuf.Any.type_url) - return type_url_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline ::std::string* Any::release_type_url() { - // @@protoc_insertion_point(field_release:google.protobuf.Any.type_url) - - return type_url_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline void Any::set_allocated_type_url(::std::string* type_url) { - if (type_url != NULL) { - - } else { - - } - type_url_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), type_url); - // @@protoc_insertion_point(field_set_allocated:google.protobuf.Any.type_url) -} - -// bytes value = 2; -inline void Any::clear_value() { - value_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline const ::std::string& Any::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Any.value) - return value_.GetNoArena(); -} -inline void Any::set_value(const ::std::string& value) { - - value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value); - // @@protoc_insertion_point(field_set:google.protobuf.Any.value) -} -#if LANG_CXX11 -inline void Any::set_value(::std::string&& value) { - - value_.SetNoArena( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value)); - // @@protoc_insertion_point(field_set_rvalue:google.protobuf.Any.value) -} -#endif -inline void Any::set_value(const char* value) { - GOOGLE_DCHECK(value != NULL); - - value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value)); - // @@protoc_insertion_point(field_set_char:google.protobuf.Any.value) -} -inline void Any::set_value(const void* value, size_t size) { - - value_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - ::std::string(reinterpret_cast(value), size)); - // @@protoc_insertion_point(field_set_pointer:google.protobuf.Any.value) -} -inline ::std::string* Any::mutable_value() { - - // @@protoc_insertion_point(field_mutable:google.protobuf.Any.value) - return value_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline ::std::string* Any::release_value() { - // @@protoc_insertion_point(field_release:google.protobuf.Any.value) - - return value_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline void Any::set_allocated_value(::std::string* value) { - if (value != NULL) { - - } else { - - } - value_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value); - // @@protoc_insertion_point(field_set_allocated:google.protobuf.Any.value) -} - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ - -// @@protoc_insertion_point(namespace_scope) - -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) - -#endif // PROTOBUF_google_2fprotobuf_2fany_2eproto__INCLUDED diff --git a/Firestore/Protos/cpp/google/protobuf/empty.pb.cc b/Firestore/Protos/cpp/google/protobuf/empty.pb.cc deleted file mode 100644 index dfed277..0000000 --- a/Firestore/Protos/cpp/google/protobuf/empty.pb.cc +++ /dev/null @@ -1,358 +0,0 @@ -/* - * 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/protobuf/empty.proto - -#include - -#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 protobuf { -class EmptyDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Empty_default_instance_; -} // namespace protobuf -} // namespace google -namespace protobuf_google_2fprotobuf_2fempty_2eproto { -void InitDefaultsEmptyImpl() { - 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::protobuf::_Empty_default_instance_; - new (ptr) ::google::protobuf::Empty(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Empty::InitAsDefaultInstance(); -} - -void InitDefaultsEmpty() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsEmptyImpl); -} - -::google::protobuf::Metadata file_level_metadata[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::protobuf::Empty, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - { 0, -1, sizeof(::google::protobuf::Empty)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::google::protobuf::_Empty_default_instance_), -}; - -void protobuf_AssignDescriptors() { - AddDescriptors(); - ::google::protobuf::MessageFactory* factory = NULL; - AssignDescriptors( - "google/protobuf/empty.proto", schemas, file_default_instances, TableStruct::offsets, factory, - file_level_metadata, NULL, 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, 1); -} - -void AddDescriptorsImpl() { - InitDefaults(); - static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - "\n\033google/protobuf/empty.proto\022\017google.pr" - "otobuf\"\007\n\005EmptyBv\n\023com.google.protobufB\n" - "EmptyProtoP\001Z\'github.com/golang/protobuf" - "/ptypes/empty\370\001\001\242\002\003GPB\252\002\036Google.Protobuf" - ".WellKnownTypesb\006proto3" - }; - ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( - descriptor, 183); - ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( - "google/protobuf/empty.proto", &protobuf_RegisterTypes); -} - -void AddDescriptors() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); -} -// Force AddDescriptors() to be called at dynamic initialization time. -struct StaticDescriptorInitializer { - StaticDescriptorInitializer() { - AddDescriptors(); - } -} static_descriptor_initializer; -} // namespace protobuf_google_2fprotobuf_2fempty_2eproto -namespace google { -namespace protobuf { - -// =================================================================== - -void Empty::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Empty::Empty() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fempty_2eproto::InitDefaultsEmpty(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Empty) -} -Empty::Empty(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fempty_2eproto::InitDefaultsEmpty(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Empty) -} -Empty::Empty(const Empty& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - // @@protoc_insertion_point(copy_constructor:google.protobuf.Empty) -} - -void Empty::SharedCtor() { - _cached_size_ = 0; -} - -Empty::~Empty() { - // @@protoc_insertion_point(destructor:google.protobuf.Empty) - SharedDtor(); -} - -void Empty::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void Empty::ArenaDtor(void* object) { - Empty* _this = reinterpret_cast< Empty* >(object); - (void)_this; -} -void Empty::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Empty::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Empty::descriptor() { - ::protobuf_google_2fprotobuf_2fempty_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fempty_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Empty& Empty::default_instance() { - ::protobuf_google_2fprotobuf_2fempty_2eproto::InitDefaultsEmpty(); - return *internal_default_instance(); -} - -Empty* Empty::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Empty::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Empty) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - _internal_metadata_.Clear(); -} - -bool Empty::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.protobuf.Empty) - for (;;) { - ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); - tag = p.first; - if (!p.second) goto handle_unusual; - handle_unusual: - if (tag == 0) { - goto success; - } - DO_(::google::protobuf::internal::WireFormat::SkipField( - input, tag, _internal_metadata_.mutable_unknown_fields())); - } -success: - // @@protoc_insertion_point(parse_success:google.protobuf.Empty) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Empty) - return false; -#undef DO_ -} - -void Empty::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Empty) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - 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.protobuf.Empty) -} - -::google::protobuf::uint8* Empty::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Empty) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - 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.protobuf.Empty) - return target; -} - -size_t Empty::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Empty) - 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())); - } - 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 Empty::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Empty) - GOOGLE_DCHECK_NE(&from, this); - const Empty* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Empty) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Empty) - MergeFrom(*source); - } -} - -void Empty::MergeFrom(const Empty& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Empty) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - -} - -void Empty::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Empty) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Empty::CopyFrom(const Empty& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Empty) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Empty::IsInitialized() const { - return true; -} - -void Empty::Swap(Empty* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Empty* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Empty::UnsafeArenaSwap(Empty* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Empty::InternalSwap(Empty* other) { - using std::swap; - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Empty::GetMetadata() const { - protobuf_google_2fprotobuf_2fempty_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fempty_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) diff --git a/Firestore/Protos/cpp/google/protobuf/empty.pb.h b/Firestore/Protos/cpp/google/protobuf/empty.pb.h deleted file mode 100644 index a5276b6..0000000 --- a/Firestore/Protos/cpp/google/protobuf/empty.pb.h +++ /dev/null @@ -1,206 +0,0 @@ -/* - * 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/protobuf/empty.proto - -#ifndef PROTOBUF_google_2fprotobuf_2fempty_2eproto__INCLUDED -#define PROTOBUF_google_2fprotobuf_2fempty_2eproto__INCLUDED - -#include - -#include - -#if GOOGLE_PROTOBUF_VERSION < 3005000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -// @@protoc_insertion_point(includes) - -namespace protobuf_google_2fprotobuf_2fempty_2eproto { -// Internal implementation detail -- do not use these members. -struct TableStruct { - static const ::google::protobuf::internal::ParseTableField entries[]; - static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; - static const ::google::protobuf::internal::ParseTable schema[1]; - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors(); -void InitDefaultsEmptyImpl(); -void InitDefaultsEmpty(); -inline void InitDefaults() { - InitDefaultsEmpty(); -} -} // namespace protobuf_google_2fprotobuf_2fempty_2eproto -namespace google { -namespace protobuf { -class Empty; -class EmptyDefaultTypeInternal; -extern EmptyDefaultTypeInternal _Empty_default_instance_; -} // namespace protobuf -} // namespace google -namespace google { -namespace protobuf { - -// =================================================================== - -class Empty : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Empty) */ { - public: - Empty(); - virtual ~Empty(); - - Empty(const Empty& from); - - inline Empty& operator=(const Empty& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Empty(Empty&& from) noexcept - : Empty() { - *this = ::std::move(from); - } - - inline Empty& operator=(Empty&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Empty& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Empty* internal_default_instance() { - return reinterpret_cast( - &_Empty_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 0; - - void UnsafeArenaSwap(Empty* other); - void Swap(Empty* other); - friend void swap(Empty& a, Empty& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Empty* New() const PROTOBUF_FINAL { return New(NULL); } - - Empty* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Empty& from); - void MergeFrom(const Empty& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Empty* other); - protected: - explicit Empty(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // @@protoc_insertion_point(class_scope:google.protobuf.Empty) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fempty_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fempty_2eproto::InitDefaultsEmptyImpl(); -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// Empty - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ - -// @@protoc_insertion_point(namespace_scope) - -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) - -#endif // PROTOBUF_google_2fprotobuf_2fempty_2eproto__INCLUDED diff --git a/Firestore/Protos/cpp/google/protobuf/struct.pb.cc b/Firestore/Protos/cpp/google/protobuf/struct.pb.cc deleted file mode 100644 index 360a89b..0000000 --- a/Firestore/Protos/cpp/google/protobuf/struct.pb.cc +++ /dev/null @@ -1,1491 +0,0 @@ -/* - * 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/protobuf/struct.proto - -#include - -#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 protobuf { -class Struct_FieldsEntry_DoNotUseDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Struct_FieldsEntry_DoNotUse_default_instance_; -class StructDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Struct_default_instance_; -class ValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; - int null_value_; - double number_value_; - ::google::protobuf::internal::ArenaStringPtr string_value_; - bool bool_value_; - const ::google::protobuf::Struct* struct_value_; - const ::google::protobuf::ListValue* list_value_; -} _Value_default_instance_; -class ListValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _ListValue_default_instance_; -} // namespace protobuf -} // namespace google -namespace protobuf_google_2fprotobuf_2fstruct_2eproto { -void InitDefaultsListValueImpl() { - 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::protobuf::_Struct_FieldsEntry_DoNotUse_default_instance_; - new (ptr) ::google::protobuf::Struct_FieldsEntry_DoNotUse(); - } - { - void* ptr = &::google::protobuf::_Struct_default_instance_; - new (ptr) ::google::protobuf::Struct(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - { - void* ptr = &::google::protobuf::_Value_default_instance_; - new (ptr) ::google::protobuf::Value(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - { - void* ptr = &::google::protobuf::_ListValue_default_instance_; - new (ptr) ::google::protobuf::ListValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Struct_FieldsEntry_DoNotUse::InitAsDefaultInstance(); - ::google::protobuf::Struct::InitAsDefaultInstance(); - ::google::protobuf::Value::InitAsDefaultInstance(); - ::google::protobuf::ListValue::InitAsDefaultInstance(); -} - -void InitDefaultsListValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsListValueImpl); -} - -::google::protobuf::Metadata file_level_metadata[4]; -const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1]; - -const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct_FieldsEntry_DoNotUse, _has_bits_), - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct_FieldsEntry_DoNotUse, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct_FieldsEntry_DoNotUse, key_), - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct_FieldsEntry_DoNotUse, value_), - 0, - 1, - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Struct, fields_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Value, _internal_metadata_), - ~0u, // no _extensions_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Value, _oneof_case_[0]), - ~0u, // no _weak_field_map_ - offsetof(::google::protobuf::ValueDefaultTypeInternal, null_value_), - offsetof(::google::protobuf::ValueDefaultTypeInternal, number_value_), - offsetof(::google::protobuf::ValueDefaultTypeInternal, string_value_), - offsetof(::google::protobuf::ValueDefaultTypeInternal, bool_value_), - offsetof(::google::protobuf::ValueDefaultTypeInternal, struct_value_), - offsetof(::google::protobuf::ValueDefaultTypeInternal, list_value_), - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Value, kind_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::ListValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::ListValue, values_), -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - { 0, 7, sizeof(::google::protobuf::Struct_FieldsEntry_DoNotUse)}, - { 9, -1, sizeof(::google::protobuf::Struct)}, - { 15, -1, sizeof(::google::protobuf::Value)}, - { 27, -1, sizeof(::google::protobuf::ListValue)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::google::protobuf::_Struct_FieldsEntry_DoNotUse_default_instance_), - reinterpret_cast(&::google::protobuf::_Struct_default_instance_), - reinterpret_cast(&::google::protobuf::_Value_default_instance_), - reinterpret_cast(&::google::protobuf::_ListValue_default_instance_), -}; - -void protobuf_AssignDescriptors() { - AddDescriptors(); - ::google::protobuf::MessageFactory* factory = NULL; - AssignDescriptors( - "google/protobuf/struct.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, 4); -} - -void AddDescriptorsImpl() { - InitDefaults(); - static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - "\n\034google/protobuf/struct.proto\022\017google.p" - "rotobuf\"\204\001\n\006Struct\0223\n\006fields\030\001 \003(\0132#.goo" - "gle.protobuf.Struct.FieldsEntry\032E\n\013Field" - "sEntry\022\013\n\003key\030\001 \001(\t\022%\n\005value\030\002 \001(\0132\026.goo" - "gle.protobuf.Value:\0028\001\"\352\001\n\005Value\0220\n\nnull" - "_value\030\001 \001(\0162\032.google.protobuf.NullValue" - "H\000\022\026\n\014number_value\030\002 \001(\001H\000\022\026\n\014string_val" - "ue\030\003 \001(\tH\000\022\024\n\nbool_value\030\004 \001(\010H\000\022/\n\014stru" - "ct_value\030\005 \001(\0132\027.google.protobuf.StructH" - "\000\0220\n\nlist_value\030\006 \001(\0132\032.google.protobuf." - "ListValueH\000B\006\n\004kind\"3\n\tListValue\022&\n\006valu" - "es\030\001 \003(\0132\026.google.protobuf.Value*\033\n\tNull" - "Value\022\016\n\nNULL_VALUE\020\000B\201\001\n\023com.google.pro" - "tobufB\013StructProtoP\001Z1github.com/golang/" - "protobuf/ptypes/struct;structpb\370\001\001\242\002\003GPB" - "\252\002\036Google.Protobuf.WellKnownTypesb\006proto" - "3" - }; - ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( - descriptor, 641); - ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( - "google/protobuf/struct.proto", &protobuf_RegisterTypes); -} - -void AddDescriptors() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); -} -// Force AddDescriptors() to be called at dynamic initialization time. -struct StaticDescriptorInitializer { - StaticDescriptorInitializer() { - AddDescriptors(); - } -} static_descriptor_initializer; -} // namespace protobuf_google_2fprotobuf_2fstruct_2eproto -namespace google { -namespace protobuf { -const ::google::protobuf::EnumDescriptor* NullValue_descriptor() { - protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_enum_descriptors[0]; -} -bool NullValue_IsValid(int value) { - switch (value) { - case 0: - return true; - default: - return false; - } -} - - -// =================================================================== - -Struct_FieldsEntry_DoNotUse::Struct_FieldsEntry_DoNotUse() {} -Struct_FieldsEntry_DoNotUse::Struct_FieldsEntry_DoNotUse(::google::protobuf::Arena* arena) : SuperType(arena) {} -void Struct_FieldsEntry_DoNotUse::MergeFrom(const Struct_FieldsEntry_DoNotUse& other) { - MergeFromInternal(other); -} -::google::protobuf::Metadata Struct_FieldsEntry_DoNotUse::GetMetadata() const { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[0]; -} -void Struct_FieldsEntry_DoNotUse::MergeFrom( - const ::google::protobuf::Message& other) { - ::google::protobuf::Message::MergeFrom(other); -} - - -// =================================================================== - -void Struct::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Struct::kFieldsFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Struct::Struct() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Struct) -} -Struct::Struct(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena), - fields_(arena) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Struct) -} -Struct::Struct(const Struct& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - fields_.MergeFrom(from.fields_); - // @@protoc_insertion_point(copy_constructor:google.protobuf.Struct) -} - -void Struct::SharedCtor() { - _cached_size_ = 0; -} - -Struct::~Struct() { - // @@protoc_insertion_point(destructor:google.protobuf.Struct) - SharedDtor(); -} - -void Struct::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void Struct::ArenaDtor(void* object) { - Struct* _this = reinterpret_cast< Struct* >(object); - (void)_this; -} -void Struct::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Struct::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Struct::descriptor() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Struct& Struct::default_instance() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - return *internal_default_instance(); -} - -Struct* Struct::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Struct::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Struct) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - fields_.Clear(); - _internal_metadata_.Clear(); -} - -bool Struct::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.protobuf.Struct) - 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)) { - // map fields = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { - Struct_FieldsEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField< - Struct_FieldsEntry_DoNotUse, - ::std::string, ::google::protobuf::Value, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, - 0 >, - ::google::protobuf::Map< ::std::string, ::google::protobuf::Value > > parser(&fields_); - DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( - input, &parser)); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.key().data(), static_cast(parser.key().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "google.protobuf.Struct.FieldsEntry.key")); - } 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.protobuf.Struct) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Struct) - return false; -#undef DO_ -} - -void Struct::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Struct) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // map fields = 1; - if (!this->fields().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Struct.FieldsEntry.key"); - } - }; - - if (output->IsSerializationDeterministic() && - this->fields().size() > 1) { - ::google::protobuf::scoped_array items( - new SortItem[this->fields().size()]); - typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_iterator - it = this->fields().begin(); - it != this->fields().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::google::protobuf::scoped_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(fields_.NewEntryWrapper( - items[static_cast(i)]->first, items[static_cast(i)]->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, *entry, output); - if (entry->GetArena() != NULL) { - entry.release(); - } - Utf8Check::Check(items[static_cast(i)]); - } - } else { - ::google::protobuf::scoped_ptr entry; - for (::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_iterator - it = this->fields().begin(); - it != this->fields().end(); ++it) { - entry.reset(fields_.NewEntryWrapper( - it->first, it->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, *entry, output); - if (entry->GetArena() != NULL) { - entry.release(); - } - Utf8Check::Check(&*it); - } - } - } - - 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.protobuf.Struct) -} - -::google::protobuf::uint8* Struct::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Struct) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // map fields = 1; - if (!this->fields().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Struct.FieldsEntry.key"); - } - }; - - if (deterministic && - this->fields().size() > 1) { - ::google::protobuf::scoped_array items( - new SortItem[this->fields().size()]); - typedef ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_iterator - it = this->fields().begin(); - it != this->fields().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::google::protobuf::scoped_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(fields_.NewEntryWrapper( - items[static_cast(i)]->first, items[static_cast(i)]->second)); - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageNoVirtualToArray( - 1, *entry, deterministic, target); -; - if (entry->GetArena() != NULL) { - entry.release(); - } - Utf8Check::Check(items[static_cast(i)]); - } - } else { - ::google::protobuf::scoped_ptr entry; - for (::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_iterator - it = this->fields().begin(); - it != this->fields().end(); ++it) { - entry.reset(fields_.NewEntryWrapper( - it->first, it->second)); - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageNoVirtualToArray( - 1, *entry, deterministic, target); -; - if (entry->GetArena() != NULL) { - entry.release(); - } - Utf8Check::Check(&*it); - } - } - } - - 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.protobuf.Struct) - return target; -} - -size_t Struct::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Struct) - 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())); - } - // map fields = 1; - total_size += 1 * - ::google::protobuf::internal::FromIntSize(this->fields_size()); - { - ::google::protobuf::scoped_ptr entry; - for (::google::protobuf::Map< ::std::string, ::google::protobuf::Value >::const_iterator - it = this->fields().begin(); - it != this->fields().end(); ++it) { - if (entry.get() != NULL && entry->GetArena() != NULL) { - entry.release(); - } - entry.reset(fields_.NewEntryWrapper(it->first, it->second)); - total_size += ::google::protobuf::internal::WireFormatLite:: - MessageSizeNoVirtual(*entry); - } - if (entry.get() != NULL && entry->GetArena() != NULL) { - entry.release(); - } - } - - 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 Struct::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Struct) - GOOGLE_DCHECK_NE(&from, this); - const Struct* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Struct) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Struct) - MergeFrom(*source); - } -} - -void Struct::MergeFrom(const Struct& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Struct) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - fields_.MergeFrom(from.fields_); -} - -void Struct::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Struct) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Struct::CopyFrom(const Struct& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Struct) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Struct::IsInitialized() const { - return true; -} - -void Struct::Swap(Struct* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Struct* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Struct::UnsafeArenaSwap(Struct* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Struct::InternalSwap(Struct* other) { - using std::swap; - fields_.Swap(&other->fields_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Struct::GetMetadata() const { - protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void Value::InitAsDefaultInstance() { - ::google::protobuf::_Value_default_instance_.null_value_ = 0; - ::google::protobuf::_Value_default_instance_.number_value_ = 0; - ::google::protobuf::_Value_default_instance_.string_value_.UnsafeSetDefault( - &::google::protobuf::internal::GetEmptyStringAlreadyInited()); - ::google::protobuf::_Value_default_instance_.bool_value_ = false; - ::google::protobuf::_Value_default_instance_.struct_value_ = const_cast< ::google::protobuf::Struct*>( - ::google::protobuf::Struct::internal_default_instance()); - ::google::protobuf::_Value_default_instance_.list_value_ = const_cast< ::google::protobuf::ListValue*>( - ::google::protobuf::ListValue::internal_default_instance()); -} -void Value::set_allocated_struct_value(::google::protobuf::Struct* struct_value) { - ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); - clear_kind(); - if (struct_value) { - ::google::protobuf::Arena* submessage_arena = - ::google::protobuf::Arena::GetArena(struct_value); - if (message_arena != submessage_arena) { - struct_value = ::google::protobuf::internal::GetOwnedMessage( - message_arena, struct_value, submessage_arena); - } - set_has_struct_value(); - kind_.struct_value_ = struct_value; - } - // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.struct_value) -} -void Value::set_allocated_list_value(::google::protobuf::ListValue* list_value) { - ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); - clear_kind(); - if (list_value) { - ::google::protobuf::Arena* submessage_arena = - ::google::protobuf::Arena::GetArena(list_value); - if (message_arena != submessage_arena) { - list_value = ::google::protobuf::internal::GetOwnedMessage( - message_arena, list_value, submessage_arena); - } - set_has_list_value(); - kind_.list_value_ = list_value; - } - // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.list_value) -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Value::kNullValueFieldNumber; -const int Value::kNumberValueFieldNumber; -const int Value::kStringValueFieldNumber; -const int Value::kBoolValueFieldNumber; -const int Value::kStructValueFieldNumber; -const int Value::kListValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Value::Value() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Value) -} -Value::Value(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Value) -} -Value::Value(const Value& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - clear_has_kind(); - switch (from.kind_case()) { - case kNullValue: { - set_null_value(from.null_value()); - break; - } - case kNumberValue: { - set_number_value(from.number_value()); - break; - } - case kStringValue: { - set_string_value(from.string_value()); - break; - } - case kBoolValue: { - set_bool_value(from.bool_value()); - break; - } - case kStructValue: { - mutable_struct_value()->::google::protobuf::Struct::MergeFrom(from.struct_value()); - break; - } - case kListValue: { - mutable_list_value()->::google::protobuf::ListValue::MergeFrom(from.list_value()); - break; - } - case KIND_NOT_SET: { - break; - } - } - // @@protoc_insertion_point(copy_constructor:google.protobuf.Value) -} - -void Value::SharedCtor() { - clear_has_kind(); - _cached_size_ = 0; -} - -Value::~Value() { - // @@protoc_insertion_point(destructor:google.protobuf.Value) - SharedDtor(); -} - -void Value::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); - if (has_kind()) { - clear_kind(); - } -} - -void Value::ArenaDtor(void* object) { - Value* _this = reinterpret_cast< Value* >(object); - (void)_this; -} -void Value::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Value::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Value::descriptor() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Value& Value::default_instance() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - return *internal_default_instance(); -} - -Value* Value::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Value::clear_kind() { -// @@protoc_insertion_point(one_of_clear_start:google.protobuf.Value) - switch (kind_case()) { - case kNullValue: { - // No need to clear - break; - } - case kNumberValue: { - // No need to clear - break; - } - case kStringValue: { - kind_.string_value_.Destroy(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); - break; - } - case kBoolValue: { - // No need to clear - break; - } - case kStructValue: { - if (GetArenaNoVirtual() == NULL) { - delete kind_.struct_value_; - } - break; - } - case kListValue: { - if (GetArenaNoVirtual() == NULL) { - delete kind_.list_value_; - } - break; - } - case KIND_NOT_SET: { - break; - } - } - _oneof_case_[0] = KIND_NOT_SET; -} - - -void Value::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Value) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - clear_kind(); - _internal_metadata_.Clear(); -} - -bool Value::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.protobuf.Value) - 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.NullValue null_value = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { - int value; - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( - input, &value))); - set_null_value(static_cast< ::google::protobuf::NullValue >(value)); - } else { - goto handle_unusual; - } - break; - } - - // double number_value = 2; - case 2: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(17u /* 17 & 0xFF */)) { - clear_kind(); - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>( - input, &kind_.number_value_))); - set_has_number_value(); - } else { - goto handle_unusual; - } - break; - } - - // string string_value = 3; - case 3: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadString( - input, this->mutable_string_value())); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->string_value().data(), static_cast(this->string_value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "google.protobuf.Value.string_value")); - } else { - goto handle_unusual; - } - break; - } - - // bool bool_value = 4; - case 4: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(32u /* 32 & 0xFF */)) { - clear_kind(); - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( - input, &kind_.bool_value_))); - set_has_bool_value(); - } else { - goto handle_unusual; - } - break; - } - - // .google.protobuf.Struct struct_value = 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_struct_value())); - } else { - goto handle_unusual; - } - break; - } - - // .google.protobuf.ListValue list_value = 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_list_value())); - } 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.protobuf.Value) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Value) - return false; -#undef DO_ -} - -void Value::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // .google.protobuf.NullValue null_value = 1; - if (has_null_value()) { - ::google::protobuf::internal::WireFormatLite::WriteEnum( - 1, this->null_value(), output); - } - - // double number_value = 2; - if (has_number_value()) { - ::google::protobuf::internal::WireFormatLite::WriteDouble(2, this->number_value(), output); - } - - // string string_value = 3; - if (has_string_value()) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->string_value().data(), static_cast(this->string_value().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Value.string_value"); - ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( - 3, this->string_value(), output); - } - - // bool bool_value = 4; - if (has_bool_value()) { - ::google::protobuf::internal::WireFormatLite::WriteBool(4, this->bool_value(), output); - } - - // .google.protobuf.Struct struct_value = 5; - if (has_struct_value()) { - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 5, *kind_.struct_value_, output); - } - - // .google.protobuf.ListValue list_value = 6; - if (has_list_value()) { - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 6, *kind_.list_value_, 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.protobuf.Value) -} - -::google::protobuf::uint8* Value::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // .google.protobuf.NullValue null_value = 1; - if (has_null_value()) { - target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( - 1, this->null_value(), target); - } - - // double number_value = 2; - if (has_number_value()) { - target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(2, this->number_value(), target); - } - - // string string_value = 3; - if (has_string_value()) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->string_value().data(), static_cast(this->string_value().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.Value.string_value"); - target = - ::google::protobuf::internal::WireFormatLite::WriteStringToArray( - 3, this->string_value(), target); - } - - // bool bool_value = 4; - if (has_bool_value()) { - target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->bool_value(), target); - } - - // .google.protobuf.Struct struct_value = 5; - if (has_struct_value()) { - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageToArray( - 5, *kind_.struct_value_, deterministic, target); - } - - // .google.protobuf.ListValue list_value = 6; - if (has_list_value()) { - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageToArray( - 6, *kind_.list_value_, 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.protobuf.Value) - return target; -} - -size_t Value::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Value) - 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())); - } - switch (kind_case()) { - // .google.protobuf.NullValue null_value = 1; - case kNullValue: { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::EnumSize(this->null_value()); - break; - } - // double number_value = 2; - case kNumberValue: { - total_size += 1 + 8; - break; - } - // string string_value = 3; - case kStringValue: { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::StringSize( - this->string_value()); - break; - } - // bool bool_value = 4; - case kBoolValue: { - total_size += 1 + 1; - break; - } - // .google.protobuf.Struct struct_value = 5; - case kStructValue: { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::MessageSize( - *kind_.struct_value_); - break; - } - // .google.protobuf.ListValue list_value = 6; - case kListValue: { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::MessageSize( - *kind_.list_value_); - break; - } - case KIND_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 Value::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Value) - GOOGLE_DCHECK_NE(&from, this); - const Value* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Value) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Value) - MergeFrom(*source); - } -} - -void Value::MergeFrom(const Value& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Value) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - switch (from.kind_case()) { - case kNullValue: { - set_null_value(from.null_value()); - break; - } - case kNumberValue: { - set_number_value(from.number_value()); - break; - } - case kStringValue: { - set_string_value(from.string_value()); - break; - } - case kBoolValue: { - set_bool_value(from.bool_value()); - break; - } - case kStructValue: { - mutable_struct_value()->::google::protobuf::Struct::MergeFrom(from.struct_value()); - break; - } - case kListValue: { - mutable_list_value()->::google::protobuf::ListValue::MergeFrom(from.list_value()); - break; - } - case KIND_NOT_SET: { - break; - } - } -} - -void Value::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Value::CopyFrom(const Value& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Value::IsInitialized() const { - return true; -} - -void Value::Swap(Value* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Value* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Value::UnsafeArenaSwap(Value* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Value::InternalSwap(Value* other) { - using std::swap; - swap(kind_, other->kind_); - swap(_oneof_case_[0], other->_oneof_case_[0]); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Value::GetMetadata() const { - protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void ListValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int ListValue::kValuesFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -ListValue::ListValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.ListValue) -} -ListValue::ListValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena), - values_(arena) { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.ListValue) -} -ListValue::ListValue(const ListValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - values_(from.values_), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - // @@protoc_insertion_point(copy_constructor:google.protobuf.ListValue) -} - -void ListValue::SharedCtor() { - _cached_size_ = 0; -} - -ListValue::~ListValue() { - // @@protoc_insertion_point(destructor:google.protobuf.ListValue) - SharedDtor(); -} - -void ListValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void ListValue::ArenaDtor(void* object) { - ListValue* _this = reinterpret_cast< ListValue* >(object); - (void)_this; -} -void ListValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void ListValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* ListValue::descriptor() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const ListValue& ListValue::default_instance() { - ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValue(); - return *internal_default_instance(); -} - -ListValue* ListValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void ListValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.ListValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - values_.Clear(); - _internal_metadata_.Clear(); -} - -bool ListValue::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.protobuf.ListValue) - 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)) { - // repeated .google.protobuf.Value values = 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, add_values())); - } 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.protobuf.ListValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.ListValue) - return false; -#undef DO_ -} - -void ListValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.ListValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // repeated .google.protobuf.Value values = 1; - for (unsigned int i = 0, - n = static_cast(this->values_size()); i < n; i++) { - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, this->values(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.protobuf.ListValue) -} - -::google::protobuf::uint8* ListValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.ListValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // repeated .google.protobuf.Value values = 1; - for (unsigned int i = 0, - n = static_cast(this->values_size()); i < n; i++) { - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageToArray( - 1, this->values(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.protobuf.ListValue) - return target; -} - -size_t ListValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.ListValue) - 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.protobuf.Value values = 1; - { - unsigned int count = static_cast(this->values_size()); - total_size += 1UL * count; - for (unsigned int i = 0; i < count; i++) { - total_size += - ::google::protobuf::internal::WireFormatLite::MessageSize( - this->values(static_cast(i))); - } - } - - 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 ListValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.ListValue) - GOOGLE_DCHECK_NE(&from, this); - const ListValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.ListValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.ListValue) - MergeFrom(*source); - } -} - -void ListValue::MergeFrom(const ListValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.ListValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - values_.MergeFrom(from.values_); -} - -void ListValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.ListValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void ListValue::CopyFrom(const ListValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.ListValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool ListValue::IsInitialized() const { - return true; -} - -void ListValue::Swap(ListValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - ListValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void ListValue::UnsafeArenaSwap(ListValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void ListValue::InternalSwap(ListValue* other) { - using std::swap; - values_.InternalSwap(&other->values_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata ListValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fstruct_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fstruct_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) diff --git a/Firestore/Protos/cpp/google/protobuf/struct.pb.h b/Firestore/Protos/cpp/google/protobuf/struct.pb.h deleted file mode 100644 index 8a6f0d2..0000000 --- a/Firestore/Protos/cpp/google/protobuf/struct.pb.h +++ /dev/null @@ -1,1046 +0,0 @@ -/* - * 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/protobuf/struct.proto - -#ifndef PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED -#define PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED - -#include - -#include - -#if GOOGLE_PROTOBUF_VERSION < 3005000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -#include -#include -#include -// @@protoc_insertion_point(includes) - -namespace protobuf_google_2fprotobuf_2fstruct_2eproto { -// Internal implementation detail -- do not use these members. -struct TableStruct { - static const ::google::protobuf::internal::ParseTableField entries[]; - static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; - static const ::google::protobuf::internal::ParseTable schema[4]; - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors(); -void InitDefaultsListValueImpl(); -void InitDefaultsListValue(); -inline void InitDefaults() { - InitDefaultsListValue(); -} -} // namespace protobuf_google_2fprotobuf_2fstruct_2eproto -namespace google { -namespace protobuf { -class ListValue; -class ListValueDefaultTypeInternal; -extern ListValueDefaultTypeInternal _ListValue_default_instance_; -class Struct; -class StructDefaultTypeInternal; -extern StructDefaultTypeInternal _Struct_default_instance_; -class Struct_FieldsEntry_DoNotUse; -class Struct_FieldsEntry_DoNotUseDefaultTypeInternal; -extern Struct_FieldsEntry_DoNotUseDefaultTypeInternal _Struct_FieldsEntry_DoNotUse_default_instance_; -class Value; -class ValueDefaultTypeInternal; -extern ValueDefaultTypeInternal _Value_default_instance_; -} // namespace protobuf -} // namespace google -namespace google { -namespace protobuf { - -enum NullValue { - NULL_VALUE = 0, - NullValue_INT_MIN_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32min, - NullValue_INT_MAX_SENTINEL_DO_NOT_USE_ = ::google::protobuf::kint32max -}; -bool NullValue_IsValid(int value); -const NullValue NullValue_MIN = NULL_VALUE; -const NullValue NullValue_MAX = NULL_VALUE; -const int NullValue_ARRAYSIZE = NullValue_MAX + 1; - -const ::google::protobuf::EnumDescriptor* NullValue_descriptor(); -inline const ::std::string& NullValue_Name(NullValue value) { - return ::google::protobuf::internal::NameOfEnum( - NullValue_descriptor(), value); -} -inline bool NullValue_Parse( - const ::std::string& name, NullValue* value) { - return ::google::protobuf::internal::ParseNamedEnum( - NullValue_descriptor(), name, value); -} -// =================================================================== - -class Struct_FieldsEntry_DoNotUse : public ::google::protobuf::internal::MapEntry { -public: - typedef ::google::protobuf::internal::MapEntry SuperType; - Struct_FieldsEntry_DoNotUse(); - Struct_FieldsEntry_DoNotUse(::google::protobuf::Arena* arena); - void MergeFrom(const Struct_FieldsEntry_DoNotUse& other); - static const Struct_FieldsEntry_DoNotUse* internal_default_instance() { return reinterpret_cast(&_Struct_FieldsEntry_DoNotUse_default_instance_); } - void MergeFrom(const ::google::protobuf::Message& other) PROTOBUF_FINAL; - ::google::protobuf::Metadata GetMetadata() const; -}; - -// ------------------------------------------------------------------- - -class Struct : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Struct) */ { - public: - Struct(); - virtual ~Struct(); - - Struct(const Struct& from); - - inline Struct& operator=(const Struct& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Struct(Struct&& from) noexcept - : Struct() { - *this = ::std::move(from); - } - - inline Struct& operator=(Struct&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Struct& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Struct* internal_default_instance() { - return reinterpret_cast( - &_Struct_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 1; - - void UnsafeArenaSwap(Struct* other); - void Swap(Struct* other); - friend void swap(Struct& a, Struct& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Struct* New() const PROTOBUF_FINAL { return New(NULL); } - - Struct* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Struct& from); - void MergeFrom(const Struct& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Struct* other); - protected: - explicit Struct(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - - // accessors ------------------------------------------------------- - - // map fields = 1; - int fields_size() const; - void clear_fields(); - static const int kFieldsFieldNumber = 1; - const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >& - fields() const; - ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* - mutable_fields(); - - // @@protoc_insertion_point(class_scope:google.protobuf.Struct) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::internal::MapField< - Struct_FieldsEntry_DoNotUse, - ::std::string, ::google::protobuf::Value, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_MESSAGE, - 0 > fields_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fstruct_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValueImpl(); -}; -// ------------------------------------------------------------------- - -class Value : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Value) */ { - public: - Value(); - virtual ~Value(); - - Value(const Value& from); - - inline Value& operator=(const Value& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Value(Value&& from) noexcept - : Value() { - *this = ::std::move(from); - } - - inline Value& operator=(Value&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Value& default_instance(); - - enum KindCase { - kNullValue = 1, - kNumberValue = 2, - kStringValue = 3, - kBoolValue = 4, - kStructValue = 5, - kListValue = 6, - KIND_NOT_SET = 0, - }; - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Value* internal_default_instance() { - return reinterpret_cast( - &_Value_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 2; - - void UnsafeArenaSwap(Value* other); - void Swap(Value* other); - friend void swap(Value& a, Value& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Value* New() const PROTOBUF_FINAL { return New(NULL); } - - Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Value& from); - void MergeFrom(const Value& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Value* other); - protected: - explicit Value(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // .google.protobuf.NullValue null_value = 1; - private: - bool has_null_value() const; - public: - void clear_null_value(); - static const int kNullValueFieldNumber = 1; - ::google::protobuf::NullValue null_value() const; - void set_null_value(::google::protobuf::NullValue value); - - // double number_value = 2; - private: - bool has_number_value() const; - public: - void clear_number_value(); - static const int kNumberValueFieldNumber = 2; - double number_value() const; - void set_number_value(double value); - - // string string_value = 3; - private: - bool has_string_value() const; - public: - void clear_string_value(); - static const int kStringValueFieldNumber = 3; - const ::std::string& string_value() const; - void set_string_value(const ::std::string& value); - #if LANG_CXX11 - void set_string_value(::std::string&& value); - #endif - void set_string_value(const char* value); - void set_string_value(const char* value, size_t size); - ::std::string* mutable_string_value(); - ::std::string* release_string_value(); - void set_allocated_string_value(::std::string* string_value); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - ::std::string* unsafe_arena_release_string_value(); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - void unsafe_arena_set_allocated_string_value( - ::std::string* string_value); - - // bool bool_value = 4; - private: - bool has_bool_value() const; - public: - void clear_bool_value(); - static const int kBoolValueFieldNumber = 4; - bool bool_value() const; - void set_bool_value(bool value); - - // .google.protobuf.Struct struct_value = 5; - bool has_struct_value() const; - void clear_struct_value(); - static const int kStructValueFieldNumber = 5; - private: - void _slow_mutable_struct_value(); - public: - const ::google::protobuf::Struct& struct_value() const; - ::google::protobuf::Struct* release_struct_value(); - ::google::protobuf::Struct* mutable_struct_value(); - void set_allocated_struct_value(::google::protobuf::Struct* struct_value); - void unsafe_arena_set_allocated_struct_value( - ::google::protobuf::Struct* struct_value); - ::google::protobuf::Struct* unsafe_arena_release_struct_value(); - - // .google.protobuf.ListValue list_value = 6; - bool has_list_value() const; - void clear_list_value(); - static const int kListValueFieldNumber = 6; - private: - void _slow_mutable_list_value(); - public: - const ::google::protobuf::ListValue& list_value() const; - ::google::protobuf::ListValue* release_list_value(); - ::google::protobuf::ListValue* mutable_list_value(); - void set_allocated_list_value(::google::protobuf::ListValue* list_value); - void unsafe_arena_set_allocated_list_value( - ::google::protobuf::ListValue* list_value); - ::google::protobuf::ListValue* unsafe_arena_release_list_value(); - - KindCase kind_case() const; - // @@protoc_insertion_point(class_scope:google.protobuf.Value) - private: - void set_has_null_value(); - void set_has_number_value(); - void set_has_string_value(); - void set_has_bool_value(); - void set_has_struct_value(); - void set_has_list_value(); - - inline bool has_kind() const; - void clear_kind(); - inline void clear_has_kind(); - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - union KindUnion { - KindUnion() {} - int null_value_; - double number_value_; - ::google::protobuf::internal::ArenaStringPtr string_value_; - bool bool_value_; - ::google::protobuf::Struct* struct_value_; - ::google::protobuf::ListValue* list_value_; - } kind_; - mutable int _cached_size_; - ::google::protobuf::uint32 _oneof_case_[1]; - - friend struct ::protobuf_google_2fprotobuf_2fstruct_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValueImpl(); -}; -// ------------------------------------------------------------------- - -class ListValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.ListValue) */ { - public: - ListValue(); - virtual ~ListValue(); - - ListValue(const ListValue& from); - - inline ListValue& operator=(const ListValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - ListValue(ListValue&& from) noexcept - : ListValue() { - *this = ::std::move(from); - } - - inline ListValue& operator=(ListValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const ListValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const ListValue* internal_default_instance() { - return reinterpret_cast( - &_ListValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 3; - - void UnsafeArenaSwap(ListValue* other); - void Swap(ListValue* other); - friend void swap(ListValue& a, ListValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline ListValue* New() const PROTOBUF_FINAL { return New(NULL); } - - ListValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const ListValue& from); - void MergeFrom(const ListValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(ListValue* other); - protected: - explicit ListValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // repeated .google.protobuf.Value values = 1; - int values_size() const; - void clear_values(); - static const int kValuesFieldNumber = 1; - const ::google::protobuf::Value& values(int index) const; - ::google::protobuf::Value* mutable_values(int index); - ::google::protobuf::Value* add_values(); - ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >* - mutable_values(); - const ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >& - values() const; - - // @@protoc_insertion_point(class_scope:google.protobuf.ListValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value > values_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fstruct_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fstruct_2eproto::InitDefaultsListValueImpl(); -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// ------------------------------------------------------------------- - -// Struct - -// map fields = 1; -inline int Struct::fields_size() const { - return fields_.size(); -} -inline void Struct::clear_fields() { - fields_.Clear(); -} -inline const ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >& -Struct::fields() const { - // @@protoc_insertion_point(field_map:google.protobuf.Struct.fields) - return fields_.GetMap(); -} -inline ::google::protobuf::Map< ::std::string, ::google::protobuf::Value >* -Struct::mutable_fields() { - // @@protoc_insertion_point(field_mutable_map:google.protobuf.Struct.fields) - return fields_.MutableMap(); -} - -// ------------------------------------------------------------------- - -// Value - -// .google.protobuf.NullValue null_value = 1; -inline bool Value::has_null_value() const { - return kind_case() == kNullValue; -} -inline void Value::set_has_null_value() { - _oneof_case_[0] = kNullValue; -} -inline void Value::clear_null_value() { - if (has_null_value()) { - kind_.null_value_ = 0; - clear_has_kind(); - } -} -inline ::google::protobuf::NullValue Value::null_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.null_value) - if (has_null_value()) { - return static_cast< ::google::protobuf::NullValue >(kind_.null_value_); - } - return static_cast< ::google::protobuf::NullValue >(0); -} -inline void Value::set_null_value(::google::protobuf::NullValue value) { - if (!has_null_value()) { - clear_kind(); - set_has_null_value(); - } - kind_.null_value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Value.null_value) -} - -// double number_value = 2; -inline bool Value::has_number_value() const { - return kind_case() == kNumberValue; -} -inline void Value::set_has_number_value() { - _oneof_case_[0] = kNumberValue; -} -inline void Value::clear_number_value() { - if (has_number_value()) { - kind_.number_value_ = 0; - clear_has_kind(); - } -} -inline double Value::number_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.number_value) - if (has_number_value()) { - return kind_.number_value_; - } - return 0; -} -inline void Value::set_number_value(double value) { - if (!has_number_value()) { - clear_kind(); - set_has_number_value(); - } - kind_.number_value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Value.number_value) -} - -// string string_value = 3; -inline bool Value::has_string_value() const { - return kind_case() == kStringValue; -} -inline void Value::set_has_string_value() { - _oneof_case_[0] = kStringValue; -} -inline void Value::clear_string_value() { - if (has_string_value()) { - kind_.string_value_.Destroy(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); - clear_has_kind(); - } -} -inline const ::std::string& Value::string_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.string_value) - if (has_string_value()) { - return kind_.string_value_.Get(); - } - return *&::google::protobuf::internal::GetEmptyStringAlreadyInited(); -} -inline void Value::set_string_value(const ::std::string& value) { - if (!has_string_value()) { - clear_kind(); - set_has_string_value(); - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - kind_.string_value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value, - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) -} -#if LANG_CXX11 -inline void Value::set_string_value(::std::string&& value) { - // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) - if (!has_string_value()) { - clear_kind(); - set_has_string_value(); - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - kind_.string_value_.Set( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_rvalue:google.protobuf.Value.string_value) -} -#endif -inline void Value::set_string_value(const char* value) { - GOOGLE_DCHECK(value != NULL); - if (!has_string_value()) { - clear_kind(); - set_has_string_value(); - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - kind_.string_value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - ::std::string(value), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_char:google.protobuf.Value.string_value) -} -inline void Value::set_string_value(const char* value, - size_t size) { - if (!has_string_value()) { - clear_kind(); - set_has_string_value(); - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - kind_.string_value_.Set( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string( - reinterpret_cast(value), size), - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_pointer:google.protobuf.Value.string_value) -} -inline ::std::string* Value::mutable_string_value() { - if (!has_string_value()) { - clear_kind(); - set_has_string_value(); - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - return kind_.string_value_.Mutable(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_mutable:google.protobuf.Value.string_value) -} -inline ::std::string* Value::release_string_value() { - // @@protoc_insertion_point(field_release:google.protobuf.Value.string_value) - if (has_string_value()) { - clear_has_kind(); - return kind_.string_value_.Release(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); - } else { - return NULL; - } -} -inline void Value::set_allocated_string_value(::std::string* string_value) { - if (!has_string_value()) { - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - clear_kind(); - if (string_value != NULL) { - set_has_string_value(); - kind_.string_value_.SetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), string_value, - GetArenaNoVirtual()); - } - // @@protoc_insertion_point(field_set_allocated:google.protobuf.Value.string_value) -} -inline ::std::string* Value::unsafe_arena_release_string_value() { - // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.string_value) - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - if (has_string_value()) { - clear_has_kind(); - return kind_.string_value_.UnsafeArenaRelease( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); - } else { - return NULL; - } -} -inline void Value::unsafe_arena_set_allocated_string_value(::std::string* string_value) { - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - if (!has_string_value()) { - kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - } - clear_kind(); - if (string_value) { - set_has_string_value(); - kind_.string_value_.UnsafeArenaSetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), string_value, GetArenaNoVirtual()); - } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.Value.string_value) -} - -// bool bool_value = 4; -inline bool Value::has_bool_value() const { - return kind_case() == kBoolValue; -} -inline void Value::set_has_bool_value() { - _oneof_case_[0] = kBoolValue; -} -inline void Value::clear_bool_value() { - if (has_bool_value()) { - kind_.bool_value_ = false; - clear_has_kind(); - } -} -inline bool Value::bool_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.bool_value) - if (has_bool_value()) { - return kind_.bool_value_; - } - return false; -} -inline void Value::set_bool_value(bool value) { - if (!has_bool_value()) { - clear_kind(); - set_has_bool_value(); - } - kind_.bool_value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Value.bool_value) -} - -// .google.protobuf.Struct struct_value = 5; -inline bool Value::has_struct_value() const { - return kind_case() == kStructValue; -} -inline void Value::set_has_struct_value() { - _oneof_case_[0] = kStructValue; -} -inline void Value::clear_struct_value() { - if (has_struct_value()) { - if (GetArenaNoVirtual() == NULL) { - delete kind_.struct_value_; - } - clear_has_kind(); - } -} -inline ::google::protobuf::Struct* Value::release_struct_value() { - // @@protoc_insertion_point(field_release:google.protobuf.Value.struct_value) - if (has_struct_value()) { - clear_has_kind(); - ::google::protobuf::Struct* temp = kind_.struct_value_; - if (GetArenaNoVirtual() != NULL) { - temp = ::google::protobuf::internal::DuplicateIfNonNull(temp, NULL); - } - kind_.struct_value_ = NULL; - return temp; - } else { - return NULL; - } -} -inline const ::google::protobuf::Struct& Value::struct_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.struct_value) - return has_struct_value() - ? *kind_.struct_value_ - : *reinterpret_cast< ::google::protobuf::Struct*>(&::google::protobuf::_Struct_default_instance_); -} -inline ::google::protobuf::Struct* Value::unsafe_arena_release_struct_value() { - // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.struct_value) - if (has_struct_value()) { - clear_has_kind(); - ::google::protobuf::Struct* temp = kind_.struct_value_; - kind_.struct_value_ = NULL; - return temp; - } else { - return NULL; - } -} -inline void Value::unsafe_arena_set_allocated_struct_value(::google::protobuf::Struct* struct_value) { - clear_kind(); - if (struct_value) { - set_has_struct_value(); - kind_.struct_value_ = struct_value; - } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.Value.struct_value) -} -inline ::google::protobuf::Struct* Value::mutable_struct_value() { - if (!has_struct_value()) { - clear_kind(); - set_has_struct_value(); - kind_.struct_value_ = - ::google::protobuf::Arena::CreateMessage< ::google::protobuf::Struct >( - GetArenaNoVirtual()); - } - // @@protoc_insertion_point(field_mutable:google.protobuf.Value.struct_value) - return kind_.struct_value_; -} - -// .google.protobuf.ListValue list_value = 6; -inline bool Value::has_list_value() const { - return kind_case() == kListValue; -} -inline void Value::set_has_list_value() { - _oneof_case_[0] = kListValue; -} -inline void Value::clear_list_value() { - if (has_list_value()) { - if (GetArenaNoVirtual() == NULL) { - delete kind_.list_value_; - } - clear_has_kind(); - } -} -inline ::google::protobuf::ListValue* Value::release_list_value() { - // @@protoc_insertion_point(field_release:google.protobuf.Value.list_value) - if (has_list_value()) { - clear_has_kind(); - ::google::protobuf::ListValue* temp = kind_.list_value_; - if (GetArenaNoVirtual() != NULL) { - temp = ::google::protobuf::internal::DuplicateIfNonNull(temp, NULL); - } - kind_.list_value_ = NULL; - return temp; - } else { - return NULL; - } -} -inline const ::google::protobuf::ListValue& Value::list_value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Value.list_value) - return has_list_value() - ? *kind_.list_value_ - : *reinterpret_cast< ::google::protobuf::ListValue*>(&::google::protobuf::_ListValue_default_instance_); -} -inline ::google::protobuf::ListValue* Value::unsafe_arena_release_list_value() { - // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.Value.list_value) - if (has_list_value()) { - clear_has_kind(); - ::google::protobuf::ListValue* temp = kind_.list_value_; - kind_.list_value_ = NULL; - return temp; - } else { - return NULL; - } -} -inline void Value::unsafe_arena_set_allocated_list_value(::google::protobuf::ListValue* list_value) { - clear_kind(); - if (list_value) { - set_has_list_value(); - kind_.list_value_ = list_value; - } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.Value.list_value) -} -inline ::google::protobuf::ListValue* Value::mutable_list_value() { - if (!has_list_value()) { - clear_kind(); - set_has_list_value(); - kind_.list_value_ = - ::google::protobuf::Arena::CreateMessage< ::google::protobuf::ListValue >( - GetArenaNoVirtual()); - } - // @@protoc_insertion_point(field_mutable:google.protobuf.Value.list_value) - return kind_.list_value_; -} - -inline bool Value::has_kind() const { - return kind_case() != KIND_NOT_SET; -} -inline void Value::clear_has_kind() { - _oneof_case_[0] = KIND_NOT_SET; -} -inline Value::KindCase Value::kind_case() const { - return Value::KindCase(_oneof_case_[0]); -} -// ------------------------------------------------------------------- - -// ListValue - -// repeated .google.protobuf.Value values = 1; -inline int ListValue::values_size() const { - return values_.size(); -} -inline void ListValue::clear_values() { - values_.Clear(); -} -inline const ::google::protobuf::Value& ListValue::values(int index) const { - // @@protoc_insertion_point(field_get:google.protobuf.ListValue.values) - return values_.Get(index); -} -inline ::google::protobuf::Value* ListValue::mutable_values(int index) { - // @@protoc_insertion_point(field_mutable:google.protobuf.ListValue.values) - return values_.Mutable(index); -} -inline ::google::protobuf::Value* ListValue::add_values() { - // @@protoc_insertion_point(field_add:google.protobuf.ListValue.values) - return values_.Add(); -} -inline ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >* -ListValue::mutable_values() { - // @@protoc_insertion_point(field_mutable_list:google.protobuf.ListValue.values) - return &values_; -} -inline const ::google::protobuf::RepeatedPtrField< ::google::protobuf::Value >& -ListValue::values() const { - // @@protoc_insertion_point(field_list:google.protobuf.ListValue.values) - return values_; -} - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - - -// @@protoc_insertion_point(namespace_scope) - -} // namespace protobuf -} // namespace google - -namespace google { -namespace protobuf { - -template <> struct is_proto_enum< ::google::protobuf::NullValue> : ::google::protobuf::internal::true_type {}; -template <> -inline const EnumDescriptor* GetEnumDescriptor< ::google::protobuf::NullValue>() { - return ::google::protobuf::NullValue_descriptor(); -} - -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) - -#endif // PROTOBUF_google_2fprotobuf_2fstruct_2eproto__INCLUDED diff --git a/Firestore/Protos/cpp/google/protobuf/timestamp.pb.cc b/Firestore/Protos/cpp/google/protobuf/timestamp.pb.cc deleted file mode 100644 index 7f0ea38..0000000 --- a/Firestore/Protos/cpp/google/protobuf/timestamp.pb.cc +++ /dev/null @@ -1,447 +0,0 @@ -/* - * 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/protobuf/timestamp.proto - -#include - -#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 protobuf { -class TimestampDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Timestamp_default_instance_; -} // namespace protobuf -} // namespace google -namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto { -void InitDefaultsTimestampImpl() { - 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::protobuf::_Timestamp_default_instance_; - new (ptr) ::google::protobuf::Timestamp(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Timestamp::InitAsDefaultInstance(); -} - -void InitDefaultsTimestamp() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsTimestampImpl); -} - -::google::protobuf::Metadata file_level_metadata[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::protobuf::Timestamp, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Timestamp, seconds_), - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Timestamp, nanos_), -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - { 0, -1, sizeof(::google::protobuf::Timestamp)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::google::protobuf::_Timestamp_default_instance_), -}; - -void protobuf_AssignDescriptors() { - AddDescriptors(); - ::google::protobuf::MessageFactory* factory = NULL; - AssignDescriptors( - "google/protobuf/timestamp.proto", schemas, file_default_instances, TableStruct::offsets, factory, - file_level_metadata, NULL, 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, 1); -} - -void AddDescriptorsImpl() { - InitDefaults(); - static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - "\n\037google/protobuf/timestamp.proto\022\017googl" - "e.protobuf\"+\n\tTimestamp\022\017\n\007seconds\030\001 \001(\003" - "\022\r\n\005nanos\030\002 \001(\005B~\n\023com.google.protobufB\016" - "TimestampProtoP\001Z+github.com/golang/prot" - "obuf/ptypes/timestamp\370\001\001\242\002\003GPB\252\002\036Google." - "Protobuf.WellKnownTypesb\006proto3" - }; - ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( - descriptor, 231); - ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( - "google/protobuf/timestamp.proto", &protobuf_RegisterTypes); -} - -void AddDescriptors() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); -} -// Force AddDescriptors() to be called at dynamic initialization time. -struct StaticDescriptorInitializer { - StaticDescriptorInitializer() { - AddDescriptors(); - } -} static_descriptor_initializer; -} // namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto -namespace google { -namespace protobuf { - -// =================================================================== - -void Timestamp::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Timestamp::kSecondsFieldNumber; -const int Timestamp::kNanosFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Timestamp::Timestamp() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Timestamp) -} -Timestamp::Timestamp(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Timestamp) -} -Timestamp::Timestamp(const Timestamp& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::memcpy(&seconds_, &from.seconds_, - static_cast(reinterpret_cast(&nanos_) - - reinterpret_cast(&seconds_)) + sizeof(nanos_)); - // @@protoc_insertion_point(copy_constructor:google.protobuf.Timestamp) -} - -void Timestamp::SharedCtor() { - ::memset(&seconds_, 0, static_cast( - reinterpret_cast(&nanos_) - - reinterpret_cast(&seconds_)) + sizeof(nanos_)); - _cached_size_ = 0; -} - -Timestamp::~Timestamp() { - // @@protoc_insertion_point(destructor:google.protobuf.Timestamp) - SharedDtor(); -} - -void Timestamp::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void Timestamp::ArenaDtor(void* object) { - Timestamp* _this = reinterpret_cast< Timestamp* >(object); - (void)_this; -} -void Timestamp::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Timestamp::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Timestamp::descriptor() { - ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Timestamp& Timestamp::default_instance() { - ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestamp(); - return *internal_default_instance(); -} - -Timestamp* Timestamp::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Timestamp::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Timestamp) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - ::memset(&seconds_, 0, static_cast( - reinterpret_cast(&nanos_) - - reinterpret_cast(&seconds_)) + sizeof(nanos_)); - _internal_metadata_.Clear(); -} - -bool Timestamp::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.protobuf.Timestamp) - 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)) { - // int64 seconds = 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::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( - input, &seconds_))); - } else { - goto handle_unusual; - } - break; - } - - // int32 nanos = 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, &nanos_))); - } 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.protobuf.Timestamp) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Timestamp) - return false; -#undef DO_ -} - -void Timestamp::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Timestamp) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int64 seconds = 1; - if (this->seconds() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->seconds(), output); - } - - // int32 nanos = 2; - if (this->nanos() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->nanos(), 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.protobuf.Timestamp) -} - -::google::protobuf::uint8* Timestamp::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Timestamp) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int64 seconds = 1; - if (this->seconds() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(1, this->seconds(), target); - } - - // int32 nanos = 2; - if (this->nanos() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->nanos(), 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.protobuf.Timestamp) - return target; -} - -size_t Timestamp::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Timestamp) - 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())); - } - // int64 seconds = 1; - if (this->seconds() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::Int64Size( - this->seconds()); - } - - // int32 nanos = 2; - if (this->nanos() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::Int32Size( - this->nanos()); - } - - 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 Timestamp::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Timestamp) - GOOGLE_DCHECK_NE(&from, this); - const Timestamp* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Timestamp) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Timestamp) - MergeFrom(*source); - } -} - -void Timestamp::MergeFrom(const Timestamp& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Timestamp) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.seconds() != 0) { - set_seconds(from.seconds()); - } - if (from.nanos() != 0) { - set_nanos(from.nanos()); - } -} - -void Timestamp::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Timestamp) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Timestamp::CopyFrom(const Timestamp& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Timestamp) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Timestamp::IsInitialized() const { - return true; -} - -void Timestamp::Swap(Timestamp* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Timestamp* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Timestamp::UnsafeArenaSwap(Timestamp* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Timestamp::InternalSwap(Timestamp* other) { - using std::swap; - swap(seconds_, other->seconds_); - swap(nanos_, other->nanos_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Timestamp::GetMetadata() const { - protobuf_google_2fprotobuf_2ftimestamp_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) diff --git a/Firestore/Protos/cpp/google/protobuf/timestamp.pb.h b/Firestore/Protos/cpp/google/protobuf/timestamp.pb.h deleted file mode 100644 index 0047b39..0000000 --- a/Firestore/Protos/cpp/google/protobuf/timestamp.pb.h +++ /dev/null @@ -1,248 +0,0 @@ -/* - * 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/protobuf/timestamp.proto - -#ifndef PROTOBUF_google_2fprotobuf_2ftimestamp_2eproto__INCLUDED -#define PROTOBUF_google_2fprotobuf_2ftimestamp_2eproto__INCLUDED - -#include - -#include - -#if GOOGLE_PROTOBUF_VERSION < 3005000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -// @@protoc_insertion_point(includes) - -namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto { -// Internal implementation detail -- do not use these members. -struct TableStruct { - static const ::google::protobuf::internal::ParseTableField entries[]; - static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; - static const ::google::protobuf::internal::ParseTable schema[1]; - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors(); -void InitDefaultsTimestampImpl(); -void InitDefaultsTimestamp(); -inline void InitDefaults() { - InitDefaultsTimestamp(); -} -} // namespace protobuf_google_2fprotobuf_2ftimestamp_2eproto -namespace google { -namespace protobuf { -class Timestamp; -class TimestampDefaultTypeInternal; -extern TimestampDefaultTypeInternal _Timestamp_default_instance_; -} // namespace protobuf -} // namespace google -namespace google { -namespace protobuf { - -// =================================================================== - -class Timestamp : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Timestamp) */ { - public: - Timestamp(); - virtual ~Timestamp(); - - Timestamp(const Timestamp& from); - - inline Timestamp& operator=(const Timestamp& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Timestamp(Timestamp&& from) noexcept - : Timestamp() { - *this = ::std::move(from); - } - - inline Timestamp& operator=(Timestamp&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Timestamp& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Timestamp* internal_default_instance() { - return reinterpret_cast( - &_Timestamp_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 0; - - void UnsafeArenaSwap(Timestamp* other); - void Swap(Timestamp* other); - friend void swap(Timestamp& a, Timestamp& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Timestamp* New() const PROTOBUF_FINAL { return New(NULL); } - - Timestamp* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Timestamp& from); - void MergeFrom(const Timestamp& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Timestamp* other); - protected: - explicit Timestamp(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // int64 seconds = 1; - void clear_seconds(); - static const int kSecondsFieldNumber = 1; - ::google::protobuf::int64 seconds() const; - void set_seconds(::google::protobuf::int64 value); - - // int32 nanos = 2; - void clear_nanos(); - static const int kNanosFieldNumber = 2; - ::google::protobuf::int32 nanos() const; - void set_nanos(::google::protobuf::int32 value); - - // @@protoc_insertion_point(class_scope:google.protobuf.Timestamp) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::int64 seconds_; - ::google::protobuf::int32 nanos_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2ftimestamp_2eproto::InitDefaultsTimestampImpl(); -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// Timestamp - -// int64 seconds = 1; -inline void Timestamp::clear_seconds() { - seconds_ = GOOGLE_LONGLONG(0); -} -inline ::google::protobuf::int64 Timestamp::seconds() const { - // @@protoc_insertion_point(field_get:google.protobuf.Timestamp.seconds) - return seconds_; -} -inline void Timestamp::set_seconds(::google::protobuf::int64 value) { - - seconds_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Timestamp.seconds) -} - -// int32 nanos = 2; -inline void Timestamp::clear_nanos() { - nanos_ = 0; -} -inline ::google::protobuf::int32 Timestamp::nanos() const { - // @@protoc_insertion_point(field_get:google.protobuf.Timestamp.nanos) - return nanos_; -} -inline void Timestamp::set_nanos(::google::protobuf::int32 value) { - - nanos_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Timestamp.nanos) -} - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ - -// @@protoc_insertion_point(namespace_scope) - -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) - -#endif // PROTOBUF_google_2fprotobuf_2ftimestamp_2eproto__INCLUDED diff --git a/Firestore/Protos/cpp/google/protobuf/wrappers.pb.cc b/Firestore/Protos/cpp/google/protobuf/wrappers.pb.cc deleted file mode 100644 index b44c5c2..0000000 --- a/Firestore/Protos/cpp/google/protobuf/wrappers.pb.cc +++ /dev/null @@ -1,2812 +0,0 @@ -/* - * 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/protobuf/wrappers.proto - -#include - -#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 protobuf { -class DoubleValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _DoubleValue_default_instance_; -class FloatValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _FloatValue_default_instance_; -class Int64ValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Int64Value_default_instance_; -class UInt64ValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _UInt64Value_default_instance_; -class Int32ValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _Int32Value_default_instance_; -class UInt32ValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _UInt32Value_default_instance_; -class BoolValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _BoolValue_default_instance_; -class StringValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _StringValue_default_instance_; -class BytesValueDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed - _instance; -} _BytesValue_default_instance_; -} // namespace protobuf -} // namespace google -namespace protobuf_google_2fprotobuf_2fwrappers_2eproto { -void InitDefaultsDoubleValueImpl() { - 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::protobuf::_DoubleValue_default_instance_; - new (ptr) ::google::protobuf::DoubleValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::DoubleValue::InitAsDefaultInstance(); -} - -void InitDefaultsDoubleValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsDoubleValueImpl); -} - -void InitDefaultsFloatValueImpl() { - 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::protobuf::_FloatValue_default_instance_; - new (ptr) ::google::protobuf::FloatValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::FloatValue::InitAsDefaultInstance(); -} - -void InitDefaultsFloatValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsFloatValueImpl); -} - -void InitDefaultsInt64ValueImpl() { - 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::protobuf::_Int64Value_default_instance_; - new (ptr) ::google::protobuf::Int64Value(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Int64Value::InitAsDefaultInstance(); -} - -void InitDefaultsInt64Value() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsInt64ValueImpl); -} - -void InitDefaultsUInt64ValueImpl() { - 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::protobuf::_UInt64Value_default_instance_; - new (ptr) ::google::protobuf::UInt64Value(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::UInt64Value::InitAsDefaultInstance(); -} - -void InitDefaultsUInt64Value() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsUInt64ValueImpl); -} - -void InitDefaultsInt32ValueImpl() { - 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::protobuf::_Int32Value_default_instance_; - new (ptr) ::google::protobuf::Int32Value(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::Int32Value::InitAsDefaultInstance(); -} - -void InitDefaultsInt32Value() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsInt32ValueImpl); -} - -void InitDefaultsUInt32ValueImpl() { - 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::protobuf::_UInt32Value_default_instance_; - new (ptr) ::google::protobuf::UInt32Value(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::UInt32Value::InitAsDefaultInstance(); -} - -void InitDefaultsUInt32Value() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsUInt32ValueImpl); -} - -void InitDefaultsBoolValueImpl() { - 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::protobuf::_BoolValue_default_instance_; - new (ptr) ::google::protobuf::BoolValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::BoolValue::InitAsDefaultInstance(); -} - -void InitDefaultsBoolValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsBoolValueImpl); -} - -void InitDefaultsStringValueImpl() { - 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::protobuf::_StringValue_default_instance_; - new (ptr) ::google::protobuf::StringValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::StringValue::InitAsDefaultInstance(); -} - -void InitDefaultsStringValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsStringValueImpl); -} - -void InitDefaultsBytesValueImpl() { - 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::protobuf::_BytesValue_default_instance_; - new (ptr) ::google::protobuf::BytesValue(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::google::protobuf::BytesValue::InitAsDefaultInstance(); -} - -void InitDefaultsBytesValue() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &InitDefaultsBytesValueImpl); -} - -::google::protobuf::Metadata file_level_metadata[9]; - -const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::DoubleValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::DoubleValue, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::FloatValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::FloatValue, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Int64Value, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Int64Value, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::UInt64Value, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::UInt64Value, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Int32Value, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::Int32Value, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::UInt32Value, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::UInt32Value, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::BoolValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::BoolValue, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::StringValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::StringValue, value_), - ~0u, // no _has_bits_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::BytesValue, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(::google::protobuf::BytesValue, value_), -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - { 0, -1, sizeof(::google::protobuf::DoubleValue)}, - { 6, -1, sizeof(::google::protobuf::FloatValue)}, - { 12, -1, sizeof(::google::protobuf::Int64Value)}, - { 18, -1, sizeof(::google::protobuf::UInt64Value)}, - { 24, -1, sizeof(::google::protobuf::Int32Value)}, - { 30, -1, sizeof(::google::protobuf::UInt32Value)}, - { 36, -1, sizeof(::google::protobuf::BoolValue)}, - { 42, -1, sizeof(::google::protobuf::StringValue)}, - { 48, -1, sizeof(::google::protobuf::BytesValue)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::google::protobuf::_DoubleValue_default_instance_), - reinterpret_cast(&::google::protobuf::_FloatValue_default_instance_), - reinterpret_cast(&::google::protobuf::_Int64Value_default_instance_), - reinterpret_cast(&::google::protobuf::_UInt64Value_default_instance_), - reinterpret_cast(&::google::protobuf::_Int32Value_default_instance_), - reinterpret_cast(&::google::protobuf::_UInt32Value_default_instance_), - reinterpret_cast(&::google::protobuf::_BoolValue_default_instance_), - reinterpret_cast(&::google::protobuf::_StringValue_default_instance_), - reinterpret_cast(&::google::protobuf::_BytesValue_default_instance_), -}; - -void protobuf_AssignDescriptors() { - AddDescriptors(); - ::google::protobuf::MessageFactory* factory = NULL; - AssignDescriptors( - "google/protobuf/wrappers.proto", schemas, file_default_instances, TableStruct::offsets, factory, - file_level_metadata, NULL, 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, 9); -} - -void AddDescriptorsImpl() { - InitDefaults(); - static const char descriptor[] GOOGLE_PROTOBUF_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { - "\n\036google/protobuf/wrappers.proto\022\017google" - ".protobuf\"\034\n\013DoubleValue\022\r\n\005value\030\001 \001(\001\"" - "\033\n\nFloatValue\022\r\n\005value\030\001 \001(\002\"\033\n\nInt64Val" - "ue\022\r\n\005value\030\001 \001(\003\"\034\n\013UInt64Value\022\r\n\005valu" - "e\030\001 \001(\004\"\033\n\nInt32Value\022\r\n\005value\030\001 \001(\005\"\034\n\013" - "UInt32Value\022\r\n\005value\030\001 \001(\r\"\032\n\tBoolValue\022" - "\r\n\005value\030\001 \001(\010\"\034\n\013StringValue\022\r\n\005value\030\001" - " \001(\t\"\033\n\nBytesValue\022\r\n\005value\030\001 \001(\014B|\n\023com" - ".google.protobufB\rWrappersProtoP\001Z*githu" - "b.com/golang/protobuf/ptypes/wrappers\370\001\001" - "\242\002\003GPB\252\002\036Google.Protobuf.WellKnownTypesb" - "\006proto3" - }; - ::google::protobuf::DescriptorPool::InternalAddGeneratedFile( - descriptor, 447); - ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( - "google/protobuf/wrappers.proto", &protobuf_RegisterTypes); -} - -void AddDescriptors() { - static GOOGLE_PROTOBUF_DECLARE_ONCE(once); - ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl); -} -// Force AddDescriptors() to be called at dynamic initialization time. -struct StaticDescriptorInitializer { - StaticDescriptorInitializer() { - AddDescriptors(); - } -} static_descriptor_initializer; -} // namespace protobuf_google_2fprotobuf_2fwrappers_2eproto -namespace google { -namespace protobuf { - -// =================================================================== - -void DoubleValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int DoubleValue::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -DoubleValue::DoubleValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsDoubleValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.DoubleValue) -} -DoubleValue::DoubleValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsDoubleValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.DoubleValue) -} -DoubleValue::DoubleValue(const DoubleValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.DoubleValue) -} - -void DoubleValue::SharedCtor() { - value_ = 0; - _cached_size_ = 0; -} - -DoubleValue::~DoubleValue() { - // @@protoc_insertion_point(destructor:google.protobuf.DoubleValue) - SharedDtor(); -} - -void DoubleValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void DoubleValue::ArenaDtor(void* object) { - DoubleValue* _this = reinterpret_cast< DoubleValue* >(object); - (void)_this; -} -void DoubleValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void DoubleValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* DoubleValue::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const DoubleValue& DoubleValue::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsDoubleValue(); - return *internal_default_instance(); -} - -DoubleValue* DoubleValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void DoubleValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.DoubleValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = 0; - _internal_metadata_.Clear(); -} - -bool DoubleValue::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.protobuf.DoubleValue) - 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)) { - // double value = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(9u /* 9 & 0xFF */)) { - - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>( - input, &value_))); - } 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.protobuf.DoubleValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.DoubleValue) - return false; -#undef DO_ -} - -void DoubleValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.DoubleValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // double value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteDouble(1, this->value(), 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.protobuf.DoubleValue) -} - -::google::protobuf::uint8* DoubleValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.DoubleValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // double value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(1, this->value(), 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.protobuf.DoubleValue) - return target; -} - -size_t DoubleValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.DoubleValue) - 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())); - } - // double value = 1; - if (this->value() != 0) { - total_size += 1 + 8; - } - - 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 DoubleValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.DoubleValue) - GOOGLE_DCHECK_NE(&from, this); - const DoubleValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.DoubleValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.DoubleValue) - MergeFrom(*source); - } -} - -void DoubleValue::MergeFrom(const DoubleValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.DoubleValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void DoubleValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.DoubleValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void DoubleValue::CopyFrom(const DoubleValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.DoubleValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool DoubleValue::IsInitialized() const { - return true; -} - -void DoubleValue::Swap(DoubleValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - DoubleValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void DoubleValue::UnsafeArenaSwap(DoubleValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void DoubleValue::InternalSwap(DoubleValue* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata DoubleValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void FloatValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int FloatValue::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -FloatValue::FloatValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsFloatValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.FloatValue) -} -FloatValue::FloatValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsFloatValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.FloatValue) -} -FloatValue::FloatValue(const FloatValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.FloatValue) -} - -void FloatValue::SharedCtor() { - value_ = 0; - _cached_size_ = 0; -} - -FloatValue::~FloatValue() { - // @@protoc_insertion_point(destructor:google.protobuf.FloatValue) - SharedDtor(); -} - -void FloatValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void FloatValue::ArenaDtor(void* object) { - FloatValue* _this = reinterpret_cast< FloatValue* >(object); - (void)_this; -} -void FloatValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void FloatValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* FloatValue::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const FloatValue& FloatValue::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsFloatValue(); - return *internal_default_instance(); -} - -FloatValue* FloatValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void FloatValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.FloatValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = 0; - _internal_metadata_.Clear(); -} - -bool FloatValue::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.protobuf.FloatValue) - 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)) { - // float value = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(13u /* 13 & 0xFF */)) { - - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>( - input, &value_))); - } 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.protobuf.FloatValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.FloatValue) - return false; -#undef DO_ -} - -void FloatValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.FloatValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // float value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->value(), 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.protobuf.FloatValue) -} - -::google::protobuf::uint8* FloatValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.FloatValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // float value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->value(), 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.protobuf.FloatValue) - return target; -} - -size_t FloatValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.FloatValue) - 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())); - } - // float value = 1; - if (this->value() != 0) { - total_size += 1 + 4; - } - - 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 FloatValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.FloatValue) - GOOGLE_DCHECK_NE(&from, this); - const FloatValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.FloatValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.FloatValue) - MergeFrom(*source); - } -} - -void FloatValue::MergeFrom(const FloatValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.FloatValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void FloatValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.FloatValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void FloatValue::CopyFrom(const FloatValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.FloatValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool FloatValue::IsInitialized() const { - return true; -} - -void FloatValue::Swap(FloatValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - FloatValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void FloatValue::UnsafeArenaSwap(FloatValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void FloatValue::InternalSwap(FloatValue* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata FloatValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void Int64Value::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Int64Value::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Int64Value::Int64Value() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt64Value(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Int64Value) -} -Int64Value::Int64Value(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt64Value(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Int64Value) -} -Int64Value::Int64Value(const Int64Value& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.Int64Value) -} - -void Int64Value::SharedCtor() { - value_ = GOOGLE_LONGLONG(0); - _cached_size_ = 0; -} - -Int64Value::~Int64Value() { - // @@protoc_insertion_point(destructor:google.protobuf.Int64Value) - SharedDtor(); -} - -void Int64Value::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void Int64Value::ArenaDtor(void* object) { - Int64Value* _this = reinterpret_cast< Int64Value* >(object); - (void)_this; -} -void Int64Value::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Int64Value::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Int64Value::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Int64Value& Int64Value::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt64Value(); - return *internal_default_instance(); -} - -Int64Value* Int64Value::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Int64Value::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Int64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = GOOGLE_LONGLONG(0); - _internal_metadata_.Clear(); -} - -bool Int64Value::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.protobuf.Int64Value) - 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)) { - // int64 value = 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::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>( - input, &value_))); - } 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.protobuf.Int64Value) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Int64Value) - return false; -#undef DO_ -} - -void Int64Value::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Int64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int64 value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteInt64(1, this->value(), 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.protobuf.Int64Value) -} - -::google::protobuf::uint8* Int64Value::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Int64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int64 value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(1, this->value(), 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.protobuf.Int64Value) - return target; -} - -size_t Int64Value::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Int64Value) - 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())); - } - // int64 value = 1; - if (this->value() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::Int64Size( - this->value()); - } - - 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 Int64Value::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Int64Value) - GOOGLE_DCHECK_NE(&from, this); - const Int64Value* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Int64Value) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Int64Value) - MergeFrom(*source); - } -} - -void Int64Value::MergeFrom(const Int64Value& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Int64Value) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void Int64Value::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Int64Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Int64Value::CopyFrom(const Int64Value& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Int64Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Int64Value::IsInitialized() const { - return true; -} - -void Int64Value::Swap(Int64Value* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Int64Value* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Int64Value::UnsafeArenaSwap(Int64Value* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Int64Value::InternalSwap(Int64Value* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Int64Value::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void UInt64Value::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int UInt64Value::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -UInt64Value::UInt64Value() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt64Value(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.UInt64Value) -} -UInt64Value::UInt64Value(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt64Value(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.UInt64Value) -} -UInt64Value::UInt64Value(const UInt64Value& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.UInt64Value) -} - -void UInt64Value::SharedCtor() { - value_ = GOOGLE_ULONGLONG(0); - _cached_size_ = 0; -} - -UInt64Value::~UInt64Value() { - // @@protoc_insertion_point(destructor:google.protobuf.UInt64Value) - SharedDtor(); -} - -void UInt64Value::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void UInt64Value::ArenaDtor(void* object) { - UInt64Value* _this = reinterpret_cast< UInt64Value* >(object); - (void)_this; -} -void UInt64Value::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void UInt64Value::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* UInt64Value::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const UInt64Value& UInt64Value::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt64Value(); - return *internal_default_instance(); -} - -UInt64Value* UInt64Value::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void UInt64Value::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.UInt64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = GOOGLE_ULONGLONG(0); - _internal_metadata_.Clear(); -} - -bool UInt64Value::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.protobuf.UInt64Value) - 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)) { - // uint64 value = 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::uint64, ::google::protobuf::internal::WireFormatLite::TYPE_UINT64>( - input, &value_))); - } 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.protobuf.UInt64Value) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.UInt64Value) - return false; -#undef DO_ -} - -void UInt64Value::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.UInt64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // uint64 value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteUInt64(1, this->value(), 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.protobuf.UInt64Value) -} - -::google::protobuf::uint8* UInt64Value::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.UInt64Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // uint64 value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteUInt64ToArray(1, this->value(), 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.protobuf.UInt64Value) - return target; -} - -size_t UInt64Value::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.UInt64Value) - 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())); - } - // uint64 value = 1; - if (this->value() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::UInt64Size( - this->value()); - } - - 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 UInt64Value::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.UInt64Value) - GOOGLE_DCHECK_NE(&from, this); - const UInt64Value* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.UInt64Value) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.UInt64Value) - MergeFrom(*source); - } -} - -void UInt64Value::MergeFrom(const UInt64Value& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.UInt64Value) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void UInt64Value::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.UInt64Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void UInt64Value::CopyFrom(const UInt64Value& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.UInt64Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool UInt64Value::IsInitialized() const { - return true; -} - -void UInt64Value::Swap(UInt64Value* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - UInt64Value* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void UInt64Value::UnsafeArenaSwap(UInt64Value* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void UInt64Value::InternalSwap(UInt64Value* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata UInt64Value::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void Int32Value::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int Int32Value::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -Int32Value::Int32Value() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt32Value(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.Int32Value) -} -Int32Value::Int32Value(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt32Value(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.Int32Value) -} -Int32Value::Int32Value(const Int32Value& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.Int32Value) -} - -void Int32Value::SharedCtor() { - value_ = 0; - _cached_size_ = 0; -} - -Int32Value::~Int32Value() { - // @@protoc_insertion_point(destructor:google.protobuf.Int32Value) - SharedDtor(); -} - -void Int32Value::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void Int32Value::ArenaDtor(void* object) { - Int32Value* _this = reinterpret_cast< Int32Value* >(object); - (void)_this; -} -void Int32Value::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void Int32Value::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* Int32Value::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const Int32Value& Int32Value::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt32Value(); - return *internal_default_instance(); -} - -Int32Value* Int32Value::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void Int32Value::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.Int32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = 0; - _internal_metadata_.Clear(); -} - -bool Int32Value::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.protobuf.Int32Value) - 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 value = 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, &value_))); - } 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.protobuf.Int32Value) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.Int32Value) - return false; -#undef DO_ -} - -void Int32Value::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.Int32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int32 value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->value(), 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.protobuf.Int32Value) -} - -::google::protobuf::uint8* Int32Value::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.Int32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // int32 value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->value(), 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.protobuf.Int32Value) - return target; -} - -size_t Int32Value::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.Int32Value) - 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 value = 1; - if (this->value() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::Int32Size( - this->value()); - } - - 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 Int32Value::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.Int32Value) - GOOGLE_DCHECK_NE(&from, this); - const Int32Value* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.Int32Value) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.Int32Value) - MergeFrom(*source); - } -} - -void Int32Value::MergeFrom(const Int32Value& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.Int32Value) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void Int32Value::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.Int32Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void Int32Value::CopyFrom(const Int32Value& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.Int32Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool Int32Value::IsInitialized() const { - return true; -} - -void Int32Value::Swap(Int32Value* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - Int32Value* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void Int32Value::UnsafeArenaSwap(Int32Value* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void Int32Value::InternalSwap(Int32Value* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata Int32Value::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void UInt32Value::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int UInt32Value::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -UInt32Value::UInt32Value() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt32Value(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.UInt32Value) -} -UInt32Value::UInt32Value(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt32Value(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.UInt32Value) -} -UInt32Value::UInt32Value(const UInt32Value& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.UInt32Value) -} - -void UInt32Value::SharedCtor() { - value_ = 0u; - _cached_size_ = 0; -} - -UInt32Value::~UInt32Value() { - // @@protoc_insertion_point(destructor:google.protobuf.UInt32Value) - SharedDtor(); -} - -void UInt32Value::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void UInt32Value::ArenaDtor(void* object) { - UInt32Value* _this = reinterpret_cast< UInt32Value* >(object); - (void)_this; -} -void UInt32Value::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void UInt32Value::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* UInt32Value::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const UInt32Value& UInt32Value::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt32Value(); - return *internal_default_instance(); -} - -UInt32Value* UInt32Value::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void UInt32Value::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.UInt32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = 0u; - _internal_metadata_.Clear(); -} - -bool UInt32Value::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.protobuf.UInt32Value) - 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)) { - // uint32 value = 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::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>( - input, &value_))); - } 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.protobuf.UInt32Value) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.UInt32Value) - return false; -#undef DO_ -} - -void UInt32Value::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.UInt32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // uint32 value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->value(), 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.protobuf.UInt32Value) -} - -::google::protobuf::uint8* UInt32Value::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.UInt32Value) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // uint32 value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->value(), 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.protobuf.UInt32Value) - return target; -} - -size_t UInt32Value::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.UInt32Value) - 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())); - } - // uint32 value = 1; - if (this->value() != 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::UInt32Size( - this->value()); - } - - 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 UInt32Value::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.UInt32Value) - GOOGLE_DCHECK_NE(&from, this); - const UInt32Value* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.UInt32Value) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.UInt32Value) - MergeFrom(*source); - } -} - -void UInt32Value::MergeFrom(const UInt32Value& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.UInt32Value) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void UInt32Value::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.UInt32Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void UInt32Value::CopyFrom(const UInt32Value& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.UInt32Value) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool UInt32Value::IsInitialized() const { - return true; -} - -void UInt32Value::Swap(UInt32Value* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - UInt32Value* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void UInt32Value::UnsafeArenaSwap(UInt32Value* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void UInt32Value::InternalSwap(UInt32Value* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata UInt32Value::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void BoolValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int BoolValue::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -BoolValue::BoolValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBoolValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.BoolValue) -} -BoolValue::BoolValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBoolValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.BoolValue) -} -BoolValue::BoolValue(const BoolValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_ = from.value_; - // @@protoc_insertion_point(copy_constructor:google.protobuf.BoolValue) -} - -void BoolValue::SharedCtor() { - value_ = false; - _cached_size_ = 0; -} - -BoolValue::~BoolValue() { - // @@protoc_insertion_point(destructor:google.protobuf.BoolValue) - SharedDtor(); -} - -void BoolValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); -} - -void BoolValue::ArenaDtor(void* object) { - BoolValue* _this = reinterpret_cast< BoolValue* >(object); - (void)_this; -} -void BoolValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void BoolValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* BoolValue::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const BoolValue& BoolValue::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBoolValue(); - return *internal_default_instance(); -} - -BoolValue* BoolValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void BoolValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.BoolValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_ = false; - _internal_metadata_.Clear(); -} - -bool BoolValue::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.protobuf.BoolValue) - 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)) { - // bool value = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { - - DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< - bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( - input, &value_))); - } 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.protobuf.BoolValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.BoolValue) - return false; -#undef DO_ -} - -void BoolValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.BoolValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // bool value = 1; - if (this->value() != 0) { - ::google::protobuf::internal::WireFormatLite::WriteBool(1, this->value(), 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.protobuf.BoolValue) -} - -::google::protobuf::uint8* BoolValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.BoolValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // bool value = 1; - if (this->value() != 0) { - target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->value(), 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.protobuf.BoolValue) - return target; -} - -size_t BoolValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.BoolValue) - 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())); - } - // bool value = 1; - if (this->value() != 0) { - total_size += 1 + 1; - } - - 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 BoolValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.BoolValue) - GOOGLE_DCHECK_NE(&from, this); - const BoolValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.BoolValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.BoolValue) - MergeFrom(*source); - } -} - -void BoolValue::MergeFrom(const BoolValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.BoolValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value() != 0) { - set_value(from.value()); - } -} - -void BoolValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.BoolValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void BoolValue::CopyFrom(const BoolValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.BoolValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool BoolValue::IsInitialized() const { - return true; -} - -void BoolValue::Swap(BoolValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - BoolValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void BoolValue::UnsafeArenaSwap(BoolValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void BoolValue::InternalSwap(BoolValue* other) { - using std::swap; - swap(value_, other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata BoolValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void StringValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int StringValue::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -StringValue::StringValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsStringValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.StringValue) -} -StringValue::StringValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsStringValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.StringValue) -} -StringValue::StringValue(const StringValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.value().size() > 0) { - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value(), - GetArenaNoVirtual()); - } - // @@protoc_insertion_point(copy_constructor:google.protobuf.StringValue) -} - -void StringValue::SharedCtor() { - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - _cached_size_ = 0; -} - -StringValue::~StringValue() { - // @@protoc_insertion_point(destructor:google.protobuf.StringValue) - SharedDtor(); -} - -void StringValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); - value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} - -void StringValue::ArenaDtor(void* object) { - StringValue* _this = reinterpret_cast< StringValue* >(object); - (void)_this; -} -void StringValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void StringValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* StringValue::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const StringValue& StringValue::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsStringValue(); - return *internal_default_instance(); -} - -StringValue* StringValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void StringValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.StringValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_.ClearToEmpty(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); - _internal_metadata_.Clear(); -} - -bool StringValue::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.protobuf.StringValue) - 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 value = 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_value())); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->value().data(), static_cast(this->value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "google.protobuf.StringValue.value")); - } 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.protobuf.StringValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.StringValue) - return false; -#undef DO_ -} - -void StringValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.StringValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // string value = 1; - if (this->value().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->value().data(), static_cast(this->value().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.StringValue.value"); - ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( - 1, this->value(), 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.protobuf.StringValue) -} - -::google::protobuf::uint8* StringValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.StringValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // string value = 1; - if (this->value().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->value().data(), static_cast(this->value().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "google.protobuf.StringValue.value"); - target = - ::google::protobuf::internal::WireFormatLite::WriteStringToArray( - 1, this->value(), 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.protobuf.StringValue) - return target; -} - -size_t StringValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.StringValue) - 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 value = 1; - if (this->value().size() > 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::StringSize( - this->value()); - } - - 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 StringValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.StringValue) - GOOGLE_DCHECK_NE(&from, this); - const StringValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.StringValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.StringValue) - MergeFrom(*source); - } -} - -void StringValue::MergeFrom(const StringValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.StringValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value().size() > 0) { - set_value(from.value()); - } -} - -void StringValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.StringValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void StringValue::CopyFrom(const StringValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.StringValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool StringValue::IsInitialized() const { - return true; -} - -void StringValue::Swap(StringValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - StringValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void StringValue::UnsafeArenaSwap(StringValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void StringValue::InternalSwap(StringValue* other) { - using std::swap; - value_.Swap(&other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata StringValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// =================================================================== - -void BytesValue::InitAsDefaultInstance() { -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int BytesValue::kValueFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -BytesValue::BytesValue() - : ::google::protobuf::Message(), _internal_metadata_(NULL) { - if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBytesValue(); - } - SharedCtor(); - // @@protoc_insertion_point(constructor:google.protobuf.BytesValue) -} -BytesValue::BytesValue(::google::protobuf::Arena* arena) - : ::google::protobuf::Message(), - _internal_metadata_(arena) { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBytesValue(); - SharedCtor(); - RegisterArenaDtor(arena); - // @@protoc_insertion_point(arena_constructor:google.protobuf.BytesValue) -} -BytesValue::BytesValue(const BytesValue& from) - : ::google::protobuf::Message(), - _internal_metadata_(NULL), - _cached_size_(0) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.value().size() > 0) { - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.value(), - GetArenaNoVirtual()); - } - // @@protoc_insertion_point(copy_constructor:google.protobuf.BytesValue) -} - -void BytesValue::SharedCtor() { - value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - _cached_size_ = 0; -} - -BytesValue::~BytesValue() { - // @@protoc_insertion_point(destructor:google.protobuf.BytesValue) - SharedDtor(); -} - -void BytesValue::SharedDtor() { - GOOGLE_DCHECK(GetArenaNoVirtual() == NULL); - value_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} - -void BytesValue::ArenaDtor(void* object) { - BytesValue* _this = reinterpret_cast< BytesValue* >(object); - (void)_this; -} -void BytesValue::RegisterArenaDtor(::google::protobuf::Arena* arena) { -} -void BytesValue::SetCachedSize(int size) const { - GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN(); - _cached_size_ = size; - GOOGLE_SAFE_CONCURRENT_WRITES_END(); -} -const ::google::protobuf::Descriptor* BytesValue::descriptor() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages].descriptor; -} - -const BytesValue& BytesValue::default_instance() { - ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBytesValue(); - return *internal_default_instance(); -} - -BytesValue* BytesValue::New(::google::protobuf::Arena* arena) const { - return ::google::protobuf::Arena::CreateMessage(arena); -} - -void BytesValue::Clear() { -// @@protoc_insertion_point(message_clear_start:google.protobuf.BytesValue) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - value_.ClearToEmpty(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); - _internal_metadata_.Clear(); -} - -bool BytesValue::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.protobuf.BytesValue) - 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)) { - // bytes value = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadBytes( - input, this->mutable_value())); - } 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.protobuf.BytesValue) - return true; -failure: - // @@protoc_insertion_point(parse_failure:google.protobuf.BytesValue) - return false; -#undef DO_ -} - -void BytesValue::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:google.protobuf.BytesValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // bytes value = 1; - if (this->value().size() > 0) { - ::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased( - 1, this->value(), 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.protobuf.BytesValue) -} - -::google::protobuf::uint8* BytesValue::InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const { - (void)deterministic; // Unused - // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.BytesValue) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // bytes value = 1; - if (this->value().size() > 0) { - target = - ::google::protobuf::internal::WireFormatLite::WriteBytesToArray( - 1, this->value(), 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.protobuf.BytesValue) - return target; -} - -size_t BytesValue::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:google.protobuf.BytesValue) - 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())); - } - // bytes value = 1; - if (this->value().size() > 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::BytesSize( - this->value()); - } - - 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 BytesValue::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:google.protobuf.BytesValue) - GOOGLE_DCHECK_NE(&from, this); - const BytesValue* source = - ::google::protobuf::internal::DynamicCastToGenerated( - &from); - if (source == NULL) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:google.protobuf.BytesValue) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:google.protobuf.BytesValue) - MergeFrom(*source); - } -} - -void BytesValue::MergeFrom(const BytesValue& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.BytesValue) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - if (from.value().size() > 0) { - set_value(from.value()); - } -} - -void BytesValue::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:google.protobuf.BytesValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void BytesValue::CopyFrom(const BytesValue& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.BytesValue) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool BytesValue::IsInitialized() const { - return true; -} - -void BytesValue::Swap(BytesValue* other) { - if (other == this) return; - if (GetArenaNoVirtual() == other->GetArenaNoVirtual()) { - InternalSwap(other); - } else { - BytesValue* temp = New(GetArenaNoVirtual()); - temp->MergeFrom(*other); - other->CopyFrom(*this); - InternalSwap(temp); - if (GetArenaNoVirtual() == NULL) { - delete temp; - } - } -} -void BytesValue::UnsafeArenaSwap(BytesValue* other) { - if (other == this) return; - GOOGLE_DCHECK(GetArenaNoVirtual() == other->GetArenaNoVirtual()); - InternalSwap(other); -} -void BytesValue::InternalSwap(BytesValue* other) { - using std::swap; - value_.Swap(&other->value_); - _internal_metadata_.Swap(&other->_internal_metadata_); - swap(_cached_size_, other->_cached_size_); -} - -::google::protobuf::Metadata BytesValue::GetMetadata() const { - protobuf_google_2fprotobuf_2fwrappers_2eproto::protobuf_AssignDescriptorsOnce(); - return ::protobuf_google_2fprotobuf_2fwrappers_2eproto::file_level_metadata[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) diff --git a/Firestore/Protos/cpp/google/protobuf/wrappers.pb.h b/Firestore/Protos/cpp/google/protobuf/wrappers.pb.h deleted file mode 100644 index a43c27b..0000000 --- a/Firestore/Protos/cpp/google/protobuf/wrappers.pb.h +++ /dev/null @@ -1,1503 +0,0 @@ -/* - * 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/protobuf/wrappers.proto - -#ifndef PROTOBUF_google_2fprotobuf_2fwrappers_2eproto__INCLUDED -#define PROTOBUF_google_2fprotobuf_2fwrappers_2eproto__INCLUDED - -#include - -#include - -#if GOOGLE_PROTOBUF_VERSION < 3005000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3005000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -// @@protoc_insertion_point(includes) - -namespace protobuf_google_2fprotobuf_2fwrappers_2eproto { -// Internal implementation detail -- do not use these members. -struct TableStruct { - static const ::google::protobuf::internal::ParseTableField entries[]; - static const ::google::protobuf::internal::AuxillaryParseTableField aux[]; - static const ::google::protobuf::internal::ParseTable schema[9]; - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors(); -void InitDefaultsDoubleValueImpl(); -void InitDefaultsDoubleValue(); -void InitDefaultsFloatValueImpl(); -void InitDefaultsFloatValue(); -void InitDefaultsInt64ValueImpl(); -void InitDefaultsInt64Value(); -void InitDefaultsUInt64ValueImpl(); -void InitDefaultsUInt64Value(); -void InitDefaultsInt32ValueImpl(); -void InitDefaultsInt32Value(); -void InitDefaultsUInt32ValueImpl(); -void InitDefaultsUInt32Value(); -void InitDefaultsBoolValueImpl(); -void InitDefaultsBoolValue(); -void InitDefaultsStringValueImpl(); -void InitDefaultsStringValue(); -void InitDefaultsBytesValueImpl(); -void InitDefaultsBytesValue(); -inline void InitDefaults() { - InitDefaultsDoubleValue(); - InitDefaultsFloatValue(); - InitDefaultsInt64Value(); - InitDefaultsUInt64Value(); - InitDefaultsInt32Value(); - InitDefaultsUInt32Value(); - InitDefaultsBoolValue(); - InitDefaultsStringValue(); - InitDefaultsBytesValue(); -} -} // namespace protobuf_google_2fprotobuf_2fwrappers_2eproto -namespace google { -namespace protobuf { -class BoolValue; -class BoolValueDefaultTypeInternal; -extern BoolValueDefaultTypeInternal _BoolValue_default_instance_; -class BytesValue; -class BytesValueDefaultTypeInternal; -extern BytesValueDefaultTypeInternal _BytesValue_default_instance_; -class DoubleValue; -class DoubleValueDefaultTypeInternal; -extern DoubleValueDefaultTypeInternal _DoubleValue_default_instance_; -class FloatValue; -class FloatValueDefaultTypeInternal; -extern FloatValueDefaultTypeInternal _FloatValue_default_instance_; -class Int32Value; -class Int32ValueDefaultTypeInternal; -extern Int32ValueDefaultTypeInternal _Int32Value_default_instance_; -class Int64Value; -class Int64ValueDefaultTypeInternal; -extern Int64ValueDefaultTypeInternal _Int64Value_default_instance_; -class StringValue; -class StringValueDefaultTypeInternal; -extern StringValueDefaultTypeInternal _StringValue_default_instance_; -class UInt32Value; -class UInt32ValueDefaultTypeInternal; -extern UInt32ValueDefaultTypeInternal _UInt32Value_default_instance_; -class UInt64Value; -class UInt64ValueDefaultTypeInternal; -extern UInt64ValueDefaultTypeInternal _UInt64Value_default_instance_; -} // namespace protobuf -} // namespace google -namespace google { -namespace protobuf { - -// =================================================================== - -class DoubleValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.DoubleValue) */ { - public: - DoubleValue(); - virtual ~DoubleValue(); - - DoubleValue(const DoubleValue& from); - - inline DoubleValue& operator=(const DoubleValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - DoubleValue(DoubleValue&& from) noexcept - : DoubleValue() { - *this = ::std::move(from); - } - - inline DoubleValue& operator=(DoubleValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const DoubleValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const DoubleValue* internal_default_instance() { - return reinterpret_cast( - &_DoubleValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 0; - - void UnsafeArenaSwap(DoubleValue* other); - void Swap(DoubleValue* other); - friend void swap(DoubleValue& a, DoubleValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline DoubleValue* New() const PROTOBUF_FINAL { return New(NULL); } - - DoubleValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const DoubleValue& from); - void MergeFrom(const DoubleValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(DoubleValue* other); - protected: - explicit DoubleValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // double value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - double value() const; - void set_value(double value); - - // @@protoc_insertion_point(class_scope:google.protobuf.DoubleValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - double value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsDoubleValueImpl(); -}; -// ------------------------------------------------------------------- - -class FloatValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.FloatValue) */ { - public: - FloatValue(); - virtual ~FloatValue(); - - FloatValue(const FloatValue& from); - - inline FloatValue& operator=(const FloatValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - FloatValue(FloatValue&& from) noexcept - : FloatValue() { - *this = ::std::move(from); - } - - inline FloatValue& operator=(FloatValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const FloatValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const FloatValue* internal_default_instance() { - return reinterpret_cast( - &_FloatValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 1; - - void UnsafeArenaSwap(FloatValue* other); - void Swap(FloatValue* other); - friend void swap(FloatValue& a, FloatValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline FloatValue* New() const PROTOBUF_FINAL { return New(NULL); } - - FloatValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const FloatValue& from); - void MergeFrom(const FloatValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(FloatValue* other); - protected: - explicit FloatValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // float value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - float value() const; - void set_value(float value); - - // @@protoc_insertion_point(class_scope:google.protobuf.FloatValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - float value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsFloatValueImpl(); -}; -// ------------------------------------------------------------------- - -class Int64Value : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Int64Value) */ { - public: - Int64Value(); - virtual ~Int64Value(); - - Int64Value(const Int64Value& from); - - inline Int64Value& operator=(const Int64Value& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Int64Value(Int64Value&& from) noexcept - : Int64Value() { - *this = ::std::move(from); - } - - inline Int64Value& operator=(Int64Value&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Int64Value& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Int64Value* internal_default_instance() { - return reinterpret_cast( - &_Int64Value_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 2; - - void UnsafeArenaSwap(Int64Value* other); - void Swap(Int64Value* other); - friend void swap(Int64Value& a, Int64Value& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Int64Value* New() const PROTOBUF_FINAL { return New(NULL); } - - Int64Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Int64Value& from); - void MergeFrom(const Int64Value& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Int64Value* other); - protected: - explicit Int64Value(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // int64 value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - ::google::protobuf::int64 value() const; - void set_value(::google::protobuf::int64 value); - - // @@protoc_insertion_point(class_scope:google.protobuf.Int64Value) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::int64 value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt64ValueImpl(); -}; -// ------------------------------------------------------------------- - -class UInt64Value : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.UInt64Value) */ { - public: - UInt64Value(); - virtual ~UInt64Value(); - - UInt64Value(const UInt64Value& from); - - inline UInt64Value& operator=(const UInt64Value& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - UInt64Value(UInt64Value&& from) noexcept - : UInt64Value() { - *this = ::std::move(from); - } - - inline UInt64Value& operator=(UInt64Value&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const UInt64Value& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const UInt64Value* internal_default_instance() { - return reinterpret_cast( - &_UInt64Value_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 3; - - void UnsafeArenaSwap(UInt64Value* other); - void Swap(UInt64Value* other); - friend void swap(UInt64Value& a, UInt64Value& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline UInt64Value* New() const PROTOBUF_FINAL { return New(NULL); } - - UInt64Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const UInt64Value& from); - void MergeFrom(const UInt64Value& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(UInt64Value* other); - protected: - explicit UInt64Value(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // uint64 value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - ::google::protobuf::uint64 value() const; - void set_value(::google::protobuf::uint64 value); - - // @@protoc_insertion_point(class_scope:google.protobuf.UInt64Value) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::uint64 value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt64ValueImpl(); -}; -// ------------------------------------------------------------------- - -class Int32Value : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.Int32Value) */ { - public: - Int32Value(); - virtual ~Int32Value(); - - Int32Value(const Int32Value& from); - - inline Int32Value& operator=(const Int32Value& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - Int32Value(Int32Value&& from) noexcept - : Int32Value() { - *this = ::std::move(from); - } - - inline Int32Value& operator=(Int32Value&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const Int32Value& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const Int32Value* internal_default_instance() { - return reinterpret_cast( - &_Int32Value_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 4; - - void UnsafeArenaSwap(Int32Value* other); - void Swap(Int32Value* other); - friend void swap(Int32Value& a, Int32Value& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline Int32Value* New() const PROTOBUF_FINAL { return New(NULL); } - - Int32Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const Int32Value& from); - void MergeFrom(const Int32Value& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(Int32Value* other); - protected: - explicit Int32Value(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // int32 value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - ::google::protobuf::int32 value() const; - void set_value(::google::protobuf::int32 value); - - // @@protoc_insertion_point(class_scope:google.protobuf.Int32Value) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::int32 value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsInt32ValueImpl(); -}; -// ------------------------------------------------------------------- - -class UInt32Value : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.UInt32Value) */ { - public: - UInt32Value(); - virtual ~UInt32Value(); - - UInt32Value(const UInt32Value& from); - - inline UInt32Value& operator=(const UInt32Value& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - UInt32Value(UInt32Value&& from) noexcept - : UInt32Value() { - *this = ::std::move(from); - } - - inline UInt32Value& operator=(UInt32Value&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const UInt32Value& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const UInt32Value* internal_default_instance() { - return reinterpret_cast( - &_UInt32Value_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 5; - - void UnsafeArenaSwap(UInt32Value* other); - void Swap(UInt32Value* other); - friend void swap(UInt32Value& a, UInt32Value& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline UInt32Value* New() const PROTOBUF_FINAL { return New(NULL); } - - UInt32Value* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const UInt32Value& from); - void MergeFrom(const UInt32Value& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(UInt32Value* other); - protected: - explicit UInt32Value(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // uint32 value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - ::google::protobuf::uint32 value() const; - void set_value(::google::protobuf::uint32 value); - - // @@protoc_insertion_point(class_scope:google.protobuf.UInt32Value) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::uint32 value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsUInt32ValueImpl(); -}; -// ------------------------------------------------------------------- - -class BoolValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.BoolValue) */ { - public: - BoolValue(); - virtual ~BoolValue(); - - BoolValue(const BoolValue& from); - - inline BoolValue& operator=(const BoolValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - BoolValue(BoolValue&& from) noexcept - : BoolValue() { - *this = ::std::move(from); - } - - inline BoolValue& operator=(BoolValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const BoolValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const BoolValue* internal_default_instance() { - return reinterpret_cast( - &_BoolValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 6; - - void UnsafeArenaSwap(BoolValue* other); - void Swap(BoolValue* other); - friend void swap(BoolValue& a, BoolValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline BoolValue* New() const PROTOBUF_FINAL { return New(NULL); } - - BoolValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const BoolValue& from); - void MergeFrom(const BoolValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(BoolValue* other); - protected: - explicit BoolValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // bool value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - bool value() const; - void set_value(bool value); - - // @@protoc_insertion_point(class_scope:google.protobuf.BoolValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - bool value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBoolValueImpl(); -}; -// ------------------------------------------------------------------- - -class StringValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.StringValue) */ { - public: - StringValue(); - virtual ~StringValue(); - - StringValue(const StringValue& from); - - inline StringValue& operator=(const StringValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - StringValue(StringValue&& from) noexcept - : StringValue() { - *this = ::std::move(from); - } - - inline StringValue& operator=(StringValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const StringValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const StringValue* internal_default_instance() { - return reinterpret_cast( - &_StringValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 7; - - void UnsafeArenaSwap(StringValue* other); - void Swap(StringValue* other); - friend void swap(StringValue& a, StringValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline StringValue* New() const PROTOBUF_FINAL { return New(NULL); } - - StringValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const StringValue& from); - void MergeFrom(const StringValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(StringValue* other); - protected: - explicit StringValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // string value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - const ::std::string& value() const; - void set_value(const ::std::string& value); - #if LANG_CXX11 - void set_value(::std::string&& value); - #endif - void set_value(const char* value); - void set_value(const char* value, size_t size); - ::std::string* mutable_value(); - ::std::string* release_value(); - void set_allocated_value(::std::string* value); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - ::std::string* unsafe_arena_release_value(); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - void unsafe_arena_set_allocated_value( - ::std::string* value); - - // @@protoc_insertion_point(class_scope:google.protobuf.StringValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::internal::ArenaStringPtr value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsStringValueImpl(); -}; -// ------------------------------------------------------------------- - -class BytesValue : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:google.protobuf.BytesValue) */ { - public: - BytesValue(); - virtual ~BytesValue(); - - BytesValue(const BytesValue& from); - - inline BytesValue& operator=(const BytesValue& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - BytesValue(BytesValue&& from) noexcept - : BytesValue() { - *this = ::std::move(from); - } - - inline BytesValue& operator=(BytesValue&& from) noexcept { - if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { - if (this != &from) InternalSwap(&from); - } else { - CopyFrom(from); - } - return *this; - } - #endif - inline ::google::protobuf::Arena* GetArena() const PROTOBUF_FINAL { - return GetArenaNoVirtual(); - } - inline void* GetMaybeArenaPointer() const PROTOBUF_FINAL { - return MaybeArenaPtr(); - } - static const ::google::protobuf::Descriptor* descriptor(); - static const BytesValue& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const BytesValue* internal_default_instance() { - return reinterpret_cast( - &_BytesValue_default_instance_); - } - static PROTOBUF_CONSTEXPR int const kIndexInFileMessages = - 8; - - void UnsafeArenaSwap(BytesValue* other); - void Swap(BytesValue* other); - friend void swap(BytesValue& a, BytesValue& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline BytesValue* New() const PROTOBUF_FINAL { return New(NULL); } - - BytesValue* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL; - void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL; - void CopyFrom(const BytesValue& from); - void MergeFrom(const BytesValue& from); - void Clear() PROTOBUF_FINAL; - bool IsInitialized() const PROTOBUF_FINAL; - - size_t ByteSizeLong() const PROTOBUF_FINAL; - bool MergePartialFromCodedStream( - ::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL; - void SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL; - ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( - bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL; - int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; } - private: - void SharedCtor(); - void SharedDtor(); - void SetCachedSize(int size) const PROTOBUF_FINAL; - void InternalSwap(BytesValue* other); - protected: - explicit BytesValue(::google::protobuf::Arena* arena); - private: - static void ArenaDtor(void* object); - inline void RegisterArenaDtor(::google::protobuf::Arena* arena); - private: - inline ::google::protobuf::Arena* GetArenaNoVirtual() const { - return _internal_metadata_.arena(); - } - inline void* MaybeArenaPtr() const { - return _internal_metadata_.raw_arena_ptr(); - } - public: - - ::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL; - - // nested types ---------------------------------------------------- - - // accessors ------------------------------------------------------- - - // bytes value = 1; - void clear_value(); - static const int kValueFieldNumber = 1; - const ::std::string& value() const; - void set_value(const ::std::string& value); - #if LANG_CXX11 - void set_value(::std::string&& value); - #endif - void set_value(const char* value); - void set_value(const void* value, size_t size); - ::std::string* mutable_value(); - ::std::string* release_value(); - void set_allocated_value(::std::string* value); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - ::std::string* unsafe_arena_release_value(); - PROTOBUF_RUNTIME_DEPRECATED("The unsafe_arena_ accessors for" - " string fields are deprecated and will be removed in a" - " future release.") - void unsafe_arena_set_allocated_value( - ::std::string* value); - - // @@protoc_insertion_point(class_scope:google.protobuf.BytesValue) - private: - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - template friend class ::google::protobuf::Arena::InternalHelper; - typedef void InternalArenaConstructable_; - typedef void DestructorSkippable_; - ::google::protobuf::internal::ArenaStringPtr value_; - mutable int _cached_size_; - friend struct ::protobuf_google_2fprotobuf_2fwrappers_2eproto::TableStruct; - friend void ::protobuf_google_2fprotobuf_2fwrappers_2eproto::InitDefaultsBytesValueImpl(); -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// DoubleValue - -// double value = 1; -inline void DoubleValue::clear_value() { - value_ = 0; -} -inline double DoubleValue::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.DoubleValue.value) - return value_; -} -inline void DoubleValue::set_value(double value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.DoubleValue.value) -} - -// ------------------------------------------------------------------- - -// FloatValue - -// float value = 1; -inline void FloatValue::clear_value() { - value_ = 0; -} -inline float FloatValue::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.FloatValue.value) - return value_; -} -inline void FloatValue::set_value(float value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.FloatValue.value) -} - -// ------------------------------------------------------------------- - -// Int64Value - -// int64 value = 1; -inline void Int64Value::clear_value() { - value_ = GOOGLE_LONGLONG(0); -} -inline ::google::protobuf::int64 Int64Value::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Int64Value.value) - return value_; -} -inline void Int64Value::set_value(::google::protobuf::int64 value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Int64Value.value) -} - -// ------------------------------------------------------------------- - -// UInt64Value - -// uint64 value = 1; -inline void UInt64Value::clear_value() { - value_ = GOOGLE_ULONGLONG(0); -} -inline ::google::protobuf::uint64 UInt64Value::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.UInt64Value.value) - return value_; -} -inline void UInt64Value::set_value(::google::protobuf::uint64 value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.UInt64Value.value) -} - -// ------------------------------------------------------------------- - -// Int32Value - -// int32 value = 1; -inline void Int32Value::clear_value() { - value_ = 0; -} -inline ::google::protobuf::int32 Int32Value::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.Int32Value.value) - return value_; -} -inline void Int32Value::set_value(::google::protobuf::int32 value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.Int32Value.value) -} - -// ------------------------------------------------------------------- - -// UInt32Value - -// uint32 value = 1; -inline void UInt32Value::clear_value() { - value_ = 0u; -} -inline ::google::protobuf::uint32 UInt32Value::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.UInt32Value.value) - return value_; -} -inline void UInt32Value::set_value(::google::protobuf::uint32 value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.UInt32Value.value) -} - -// ------------------------------------------------------------------- - -// BoolValue - -// bool value = 1; -inline void BoolValue::clear_value() { - value_ = false; -} -inline bool BoolValue::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.BoolValue.value) - return value_; -} -inline void BoolValue::set_value(bool value) { - - value_ = value; - // @@protoc_insertion_point(field_set:google.protobuf.BoolValue.value) -} - -// ------------------------------------------------------------------- - -// StringValue - -// string value = 1; -inline void StringValue::clear_value() { - value_.ClearToEmpty(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline const ::std::string& StringValue::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.StringValue.value) - return value_.Get(); -} -inline void StringValue::set_value(const ::std::string& value) { - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value, GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set:google.protobuf.StringValue.value) -} -#if LANG_CXX11 -inline void StringValue::set_value(::std::string&& value) { - - value_.Set( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_rvalue:google.protobuf.StringValue.value) -} -#endif -inline void StringValue::set_value(const char* value) { - GOOGLE_DCHECK(value != NULL); - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value), - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_char:google.protobuf.StringValue.value) -} -inline void StringValue::set_value(const char* value, - size_t size) { - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string( - reinterpret_cast(value), size), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_pointer:google.protobuf.StringValue.value) -} -inline ::std::string* StringValue::mutable_value() { - - // @@protoc_insertion_point(field_mutable:google.protobuf.StringValue.value) - return value_.Mutable(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline ::std::string* StringValue::release_value() { - // @@protoc_insertion_point(field_release:google.protobuf.StringValue.value) - - return value_.Release(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline void StringValue::set_allocated_value(::std::string* value) { - if (value != NULL) { - - } else { - - } - value_.SetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value, - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_allocated:google.protobuf.StringValue.value) -} -inline ::std::string* StringValue::unsafe_arena_release_value() { - // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.StringValue.value) - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - - return value_.UnsafeArenaRelease(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); -} -inline void StringValue::unsafe_arena_set_allocated_value( - ::std::string* value) { - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - if (value != NULL) { - - } else { - - } - value_.UnsafeArenaSetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - value, GetArenaNoVirtual()); - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.StringValue.value) -} - -// ------------------------------------------------------------------- - -// BytesValue - -// bytes value = 1; -inline void BytesValue::clear_value() { - value_.ClearToEmpty(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline const ::std::string& BytesValue::value() const { - // @@protoc_insertion_point(field_get:google.protobuf.BytesValue.value) - return value_.Get(); -} -inline void BytesValue::set_value(const ::std::string& value) { - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value, GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set:google.protobuf.BytesValue.value) -} -#if LANG_CXX11 -inline void BytesValue::set_value(::std::string&& value) { - - value_.Set( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_rvalue:google.protobuf.BytesValue.value) -} -#endif -inline void BytesValue::set_value(const char* value) { - GOOGLE_DCHECK(value != NULL); - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value), - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_char:google.protobuf.BytesValue.value) -} -inline void BytesValue::set_value(const void* value, - size_t size) { - - value_.Set(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string( - reinterpret_cast(value), size), GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_pointer:google.protobuf.BytesValue.value) -} -inline ::std::string* BytesValue::mutable_value() { - - // @@protoc_insertion_point(field_mutable:google.protobuf.BytesValue.value) - return value_.Mutable(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline ::std::string* BytesValue::release_value() { - // @@protoc_insertion_point(field_release:google.protobuf.BytesValue.value) - - return value_.Release(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), GetArenaNoVirtual()); -} -inline void BytesValue::set_allocated_value(::std::string* value) { - if (value != NULL) { - - } else { - - } - value_.SetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value, - GetArenaNoVirtual()); - // @@protoc_insertion_point(field_set_allocated:google.protobuf.BytesValue.value) -} -inline ::std::string* BytesValue::unsafe_arena_release_value() { - // @@protoc_insertion_point(field_unsafe_arena_release:google.protobuf.BytesValue.value) - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - - return value_.UnsafeArenaRelease(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); -} -inline void BytesValue::unsafe_arena_set_allocated_value( - ::std::string* value) { - GOOGLE_DCHECK(GetArenaNoVirtual() != NULL); - if (value != NULL) { - - } else { - - } - value_.UnsafeArenaSetAllocated(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - value, GetArenaNoVirtual()); - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:google.protobuf.BytesValue.value) -} - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - - -// @@protoc_insertion_point(namespace_scope) - -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) - -#endif // PROTOBUF_google_2fprotobuf_2fwrappers_2eproto__INCLUDED diff --git a/Firestore/Protos/nanopb/firestore/local/maybe_document.nanopb.h b/Firestore/Protos/nanopb/firestore/local/maybe_document.nanopb.h new file mode 100644 index 0000000..0b9aa68 --- /dev/null +++ b/Firestore/Protos/nanopb/firestore/local/maybe_document.nanopb.h @@ -0,0 +1,88 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_FIRESTORE_CLIENT_MAYBE_DOCUMENT_PB_H_INCLUDED +#define PB_FIRESTORE_CLIENT_MAYBE_DOCUMENT_PB_H_INCLUDED +#include + +#include "google/firestore/v1beta1/document.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _firestore_client_NoDocument { + pb_callback_t name; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:firestore_client_NoDocument) */ +} firestore_client_NoDocument; + +typedef struct _firestore_client_MaybeDocument { + pb_size_t which_document_type; + union { + firestore_client_NoDocument no_document; + google_firestore_v1beta1_Document document; + } document_type; +/* @@protoc_insertion_point(struct:firestore_client_MaybeDocument) */ +} firestore_client_MaybeDocument; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define firestore_client_NoDocument_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define firestore_client_MaybeDocument_init_default {0, {firestore_client_NoDocument_init_default}} +#define firestore_client_NoDocument_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define firestore_client_MaybeDocument_init_zero {0, {firestore_client_NoDocument_init_zero}} + +/* Field tags (for use in manual encoding/decoding) */ +#define firestore_client_NoDocument_name_tag 1 +#define firestore_client_NoDocument_read_time_tag 2 +#define firestore_client_MaybeDocument_no_document_tag 1 +#define firestore_client_MaybeDocument_document_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t firestore_client_NoDocument_fields[3]; +extern const pb_field_t firestore_client_MaybeDocument_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* firestore_client_NoDocument_size depends on runtime parameters */ +/* firestore_client_MaybeDocument_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define MAYBE_DOCUMENT_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.c b/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.c index 7cd4035..e528816 100644 --- a/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.c +++ b/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "maybe_document.pb.h" +#include "maybe_document.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.h b/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.h deleted file mode 100644 index b159cd1..0000000 --- a/Firestore/Protos/nanopb/firestore/local/maybe_document.pb.h +++ /dev/null @@ -1,88 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_FIRESTORE_CLIENT_MAYBE_DOCUMENT_PB_H_INCLUDED -#define PB_FIRESTORE_CLIENT_MAYBE_DOCUMENT_PB_H_INCLUDED -#include - -#include "google/firestore/v1beta1/document.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _firestore_client_NoDocument { - pb_callback_t name; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:firestore_client_NoDocument) */ -} firestore_client_NoDocument; - -typedef struct _firestore_client_MaybeDocument { - pb_size_t which_document_type; - union { - firestore_client_NoDocument no_document; - google_firestore_v1beta1_Document document; - } document_type; -/* @@protoc_insertion_point(struct:firestore_client_MaybeDocument) */ -} firestore_client_MaybeDocument; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define firestore_client_NoDocument_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define firestore_client_MaybeDocument_init_default {0, {firestore_client_NoDocument_init_default}} -#define firestore_client_NoDocument_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define firestore_client_MaybeDocument_init_zero {0, {firestore_client_NoDocument_init_zero}} - -/* Field tags (for use in manual encoding/decoding) */ -#define firestore_client_NoDocument_name_tag 1 -#define firestore_client_NoDocument_read_time_tag 2 -#define firestore_client_MaybeDocument_no_document_tag 1 -#define firestore_client_MaybeDocument_document_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t firestore_client_NoDocument_fields[3]; -extern const pb_field_t firestore_client_MaybeDocument_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* firestore_client_NoDocument_size depends on runtime parameters */ -/* firestore_client_MaybeDocument_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define MAYBE_DOCUMENT_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/firestore/local/mutation.nanopb.h b/Firestore/Protos/nanopb/firestore/local/mutation.nanopb.h new file mode 100644 index 0000000..c3b2b96 --- /dev/null +++ b/Firestore/Protos/nanopb/firestore/local/mutation.nanopb.h @@ -0,0 +1,87 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_FIRESTORE_CLIENT_MUTATION_PB_H_INCLUDED +#define PB_FIRESTORE_CLIENT_MUTATION_PB_H_INCLUDED +#include + +#include "google/firestore/v1beta1/write.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _firestore_client_MutationQueue { + int32_t last_acknowledged_batch_id; + pb_callback_t last_stream_token; +/* @@protoc_insertion_point(struct:firestore_client_MutationQueue) */ +} firestore_client_MutationQueue; + +typedef struct _firestore_client_WriteBatch { + int32_t batch_id; + pb_callback_t writes; + google_protobuf_Timestamp local_write_time; +/* @@protoc_insertion_point(struct:firestore_client_WriteBatch) */ +} firestore_client_WriteBatch; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define firestore_client_MutationQueue_init_default {0, {{NULL}, NULL}} +#define firestore_client_WriteBatch_init_default {0, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define firestore_client_MutationQueue_init_zero {0, {{NULL}, NULL}} +#define firestore_client_WriteBatch_init_zero {0, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} + +/* Field tags (for use in manual encoding/decoding) */ +#define firestore_client_MutationQueue_last_acknowledged_batch_id_tag 1 +#define firestore_client_MutationQueue_last_stream_token_tag 2 +#define firestore_client_WriteBatch_batch_id_tag 1 +#define firestore_client_WriteBatch_writes_tag 2 +#define firestore_client_WriteBatch_local_write_time_tag 3 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t firestore_client_MutationQueue_fields[3]; +extern const pb_field_t firestore_client_WriteBatch_fields[4]; + +/* Maximum encoded size of messages (where known) */ +/* firestore_client_MutationQueue_size depends on runtime parameters */ +/* firestore_client_WriteBatch_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define MUTATION_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/firestore/local/mutation.pb.c b/Firestore/Protos/nanopb/firestore/local/mutation.pb.c index 7dedb14..12725ce 100644 --- a/Firestore/Protos/nanopb/firestore/local/mutation.pb.c +++ b/Firestore/Protos/nanopb/firestore/local/mutation.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "mutation.pb.h" +#include "mutation.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/firestore/local/mutation.pb.h b/Firestore/Protos/nanopb/firestore/local/mutation.pb.h deleted file mode 100644 index 537d0cd..0000000 --- a/Firestore/Protos/nanopb/firestore/local/mutation.pb.h +++ /dev/null @@ -1,87 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_FIRESTORE_CLIENT_MUTATION_PB_H_INCLUDED -#define PB_FIRESTORE_CLIENT_MUTATION_PB_H_INCLUDED -#include - -#include "google/firestore/v1beta1/write.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _firestore_client_MutationQueue { - int32_t last_acknowledged_batch_id; - pb_callback_t last_stream_token; -/* @@protoc_insertion_point(struct:firestore_client_MutationQueue) */ -} firestore_client_MutationQueue; - -typedef struct _firestore_client_WriteBatch { - int32_t batch_id; - pb_callback_t writes; - google_protobuf_Timestamp local_write_time; -/* @@protoc_insertion_point(struct:firestore_client_WriteBatch) */ -} firestore_client_WriteBatch; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define firestore_client_MutationQueue_init_default {0, {{NULL}, NULL}} -#define firestore_client_WriteBatch_init_default {0, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define firestore_client_MutationQueue_init_zero {0, {{NULL}, NULL}} -#define firestore_client_WriteBatch_init_zero {0, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} - -/* Field tags (for use in manual encoding/decoding) */ -#define firestore_client_MutationQueue_last_acknowledged_batch_id_tag 1 -#define firestore_client_MutationQueue_last_stream_token_tag 2 -#define firestore_client_WriteBatch_batch_id_tag 1 -#define firestore_client_WriteBatch_writes_tag 2 -#define firestore_client_WriteBatch_local_write_time_tag 3 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t firestore_client_MutationQueue_fields[3]; -extern const pb_field_t firestore_client_WriteBatch_fields[4]; - -/* Maximum encoded size of messages (where known) */ -/* firestore_client_MutationQueue_size depends on runtime parameters */ -/* firestore_client_WriteBatch_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define MUTATION_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/firestore/local/target.nanopb.h b/Firestore/Protos/nanopb/firestore/local/target.nanopb.h new file mode 100644 index 0000000..af6cf9c --- /dev/null +++ b/Firestore/Protos/nanopb/firestore/local/target.nanopb.h @@ -0,0 +1,100 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_FIRESTORE_CLIENT_TARGET_PB_H_INCLUDED +#define PB_FIRESTORE_CLIENT_TARGET_PB_H_INCLUDED +#include + +#include "google/firestore/v1beta1/firestore.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _firestore_client_Target { + int32_t target_id; + google_protobuf_Timestamp snapshot_version; + pb_callback_t resume_token; + int64_t last_listen_sequence_number; + pb_size_t which_target_type; + union { + google_firestore_v1beta1_Target_QueryTarget query; + google_firestore_v1beta1_Target_DocumentsTarget documents; + } target_type; +/* @@protoc_insertion_point(struct:firestore_client_Target) */ +} firestore_client_Target; + +typedef struct _firestore_client_TargetGlobal { + int32_t highest_target_id; + int64_t highest_listen_sequence_number; + google_protobuf_Timestamp last_remote_snapshot_version; + int32_t target_count; +/* @@protoc_insertion_point(struct:firestore_client_TargetGlobal) */ +} firestore_client_TargetGlobal; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define firestore_client_Target_init_default {0, google_protobuf_Timestamp_init_default, {{NULL}, NULL}, 0, 0, {google_firestore_v1beta1_Target_QueryTarget_init_default}} +#define firestore_client_TargetGlobal_init_default {0, 0, google_protobuf_Timestamp_init_default, 0} +#define firestore_client_Target_init_zero {0, google_protobuf_Timestamp_init_zero, {{NULL}, NULL}, 0, 0, {google_firestore_v1beta1_Target_QueryTarget_init_zero}} +#define firestore_client_TargetGlobal_init_zero {0, 0, google_protobuf_Timestamp_init_zero, 0} + +/* Field tags (for use in manual encoding/decoding) */ +#define firestore_client_Target_query_tag 5 +#define firestore_client_Target_documents_tag 6 +#define firestore_client_Target_target_id_tag 1 +#define firestore_client_Target_snapshot_version_tag 2 +#define firestore_client_Target_resume_token_tag 3 +#define firestore_client_Target_last_listen_sequence_number_tag 4 +#define firestore_client_TargetGlobal_highest_target_id_tag 1 +#define firestore_client_TargetGlobal_highest_listen_sequence_number_tag 2 +#define firestore_client_TargetGlobal_last_remote_snapshot_version_tag 3 +#define firestore_client_TargetGlobal_target_count_tag 4 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t firestore_client_Target_fields[7]; +extern const pb_field_t firestore_client_TargetGlobal_fields[5]; + +/* Maximum encoded size of messages (where known) */ +/* firestore_client_Target_size depends on runtime parameters */ +#define firestore_client_TargetGlobal_size 57 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define TARGET_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/firestore/local/target.pb.c b/Firestore/Protos/nanopb/firestore/local/target.pb.c index d00d4a6..7a68c4a 100644 --- a/Firestore/Protos/nanopb/firestore/local/target.pb.c +++ b/Firestore/Protos/nanopb/firestore/local/target.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Mon Apr 9 15:08:47 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "target.pb.h" +#include "target.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/firestore/local/target.pb.h b/Firestore/Protos/nanopb/firestore/local/target.pb.h deleted file mode 100644 index 37b64a2..0000000 --- a/Firestore/Protos/nanopb/firestore/local/target.pb.h +++ /dev/null @@ -1,100 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Mon Apr 9 15:08:47 2018. */ - -#ifndef PB_FIRESTORE_CLIENT_TARGET_PB_H_INCLUDED -#define PB_FIRESTORE_CLIENT_TARGET_PB_H_INCLUDED -#include - -#include "google/firestore/v1beta1/firestore.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _firestore_client_Target { - int32_t target_id; - google_protobuf_Timestamp snapshot_version; - pb_callback_t resume_token; - int64_t last_listen_sequence_number; - pb_size_t which_target_type; - union { - google_firestore_v1beta1_Target_QueryTarget query; - google_firestore_v1beta1_Target_DocumentsTarget documents; - } target_type; -/* @@protoc_insertion_point(struct:firestore_client_Target) */ -} firestore_client_Target; - -typedef struct _firestore_client_TargetGlobal { - int32_t highest_target_id; - int64_t highest_listen_sequence_number; - google_protobuf_Timestamp last_remote_snapshot_version; - int32_t target_count; -/* @@protoc_insertion_point(struct:firestore_client_TargetGlobal) */ -} firestore_client_TargetGlobal; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define firestore_client_Target_init_default {0, google_protobuf_Timestamp_init_default, {{NULL}, NULL}, 0, 0, {google_firestore_v1beta1_Target_QueryTarget_init_default}} -#define firestore_client_TargetGlobal_init_default {0, 0, google_protobuf_Timestamp_init_default, 0} -#define firestore_client_Target_init_zero {0, google_protobuf_Timestamp_init_zero, {{NULL}, NULL}, 0, 0, {google_firestore_v1beta1_Target_QueryTarget_init_zero}} -#define firestore_client_TargetGlobal_init_zero {0, 0, google_protobuf_Timestamp_init_zero, 0} - -/* Field tags (for use in manual encoding/decoding) */ -#define firestore_client_Target_query_tag 5 -#define firestore_client_Target_documents_tag 6 -#define firestore_client_Target_target_id_tag 1 -#define firestore_client_Target_snapshot_version_tag 2 -#define firestore_client_Target_resume_token_tag 3 -#define firestore_client_Target_last_listen_sequence_number_tag 4 -#define firestore_client_TargetGlobal_highest_target_id_tag 1 -#define firestore_client_TargetGlobal_highest_listen_sequence_number_tag 2 -#define firestore_client_TargetGlobal_last_remote_snapshot_version_tag 3 -#define firestore_client_TargetGlobal_target_count_tag 4 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t firestore_client_Target_fields[7]; -extern const pb_field_t firestore_client_TargetGlobal_fields[5]; - -/* Maximum encoded size of messages (where known) */ -/* firestore_client_Target_size depends on runtime parameters */ -#define firestore_client_TargetGlobal_size 57 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define TARGET_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/api/annotations.nanopb.h b/Firestore/Protos/nanopb/google/api/annotations.nanopb.h new file mode 100644 index 0000000..9a7854d --- /dev/null +++ b/Firestore/Protos/nanopb/google/api/annotations.nanopb.h @@ -0,0 +1,44 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_API_ANNOTATIONS_PB_H_INCLUDED +#define PB_GOOGLE_API_ANNOTATIONS_PB_H_INCLUDED +#include + +#include "google/api/http.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Extensions */ +/* Extension field google_api_http was skipped because only "optional" + type of extension fields is currently supported. */ + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/api/annotations.pb.c b/Firestore/Protos/nanopb/google/api/annotations.pb.c index 6da5206..ff6f44b 100644 --- a/Firestore/Protos/nanopb/google/api/annotations.pb.c +++ b/Firestore/Protos/nanopb/google/api/annotations.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "annotations.pb.h" +#include "annotations.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/api/annotations.pb.h b/Firestore/Protos/nanopb/google/api/annotations.pb.h deleted file mode 100644 index 33c9ba8..0000000 --- a/Firestore/Protos/nanopb/google/api/annotations.pb.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_API_ANNOTATIONS_PB_H_INCLUDED -#define PB_GOOGLE_API_ANNOTATIONS_PB_H_INCLUDED -#include - -#include "google/api/http.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Extensions */ -/* Extension field google_api_http was skipped because only "optional" - type of extension fields is currently supported. */ - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/api/http.nanopb.h b/Firestore/Protos/nanopb/google/api/http.nanopb.h new file mode 100644 index 0000000..4ff3efe --- /dev/null +++ b/Firestore/Protos/nanopb/google/api/http.nanopb.h @@ -0,0 +1,107 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_API_HTTP_PB_H_INCLUDED +#define PB_GOOGLE_API_HTTP_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_api_CustomHttpPattern { + pb_callback_t kind; + pb_callback_t path; +/* @@protoc_insertion_point(struct:google_api_CustomHttpPattern) */ +} google_api_CustomHttpPattern; + +typedef struct _google_api_Http { + pb_callback_t rules; + bool fully_decode_reserved_expansion; +/* @@protoc_insertion_point(struct:google_api_Http) */ +} google_api_Http; + +typedef struct _google_api_HttpRule { + pb_callback_t selector; + pb_callback_t get; + pb_callback_t put; + pb_callback_t post; + pb_callback_t delete_; + pb_callback_t patch; + pb_callback_t body; + google_api_CustomHttpPattern custom; + pb_callback_t additional_bindings; +/* @@protoc_insertion_point(struct:google_api_HttpRule) */ +} google_api_HttpRule; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_api_Http_init_default {{{NULL}, NULL}, 0} +#define google_api_HttpRule_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_api_CustomHttpPattern_init_default, {{NULL}, NULL}} +#define google_api_CustomHttpPattern_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_api_Http_init_zero {{{NULL}, NULL}, 0} +#define google_api_HttpRule_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_api_CustomHttpPattern_init_zero, {{NULL}, NULL}} +#define google_api_CustomHttpPattern_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_api_CustomHttpPattern_kind_tag 1 +#define google_api_CustomHttpPattern_path_tag 2 +#define google_api_Http_rules_tag 1 +#define google_api_Http_fully_decode_reserved_expansion_tag 2 +#define google_api_HttpRule_selector_tag 1 +#define google_api_HttpRule_get_tag 2 +#define google_api_HttpRule_put_tag 3 +#define google_api_HttpRule_post_tag 4 +#define google_api_HttpRule_delete_tag 5 +#define google_api_HttpRule_patch_tag 6 +#define google_api_HttpRule_custom_tag 8 +#define google_api_HttpRule_body_tag 7 +#define google_api_HttpRule_additional_bindings_tag 11 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_api_Http_fields[3]; +extern const pb_field_t google_api_HttpRule_fields[10]; +extern const pb_field_t google_api_CustomHttpPattern_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_api_Http_size depends on runtime parameters */ +/* google_api_HttpRule_size depends on runtime parameters */ +/* google_api_CustomHttpPattern_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define HTTP_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/api/http.pb.c b/Firestore/Protos/nanopb/google/api/http.pb.c index 7a2cd21..c0d1114 100644 --- a/Firestore/Protos/nanopb/google/api/http.pb.c +++ b/Firestore/Protos/nanopb/google/api/http.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Thu Apr 12 07:27:15 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "http.pb.h" +#include "http.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/api/http.pb.h b/Firestore/Protos/nanopb/google/api/http.pb.h deleted file mode 100644 index a7bbc46..0000000 --- a/Firestore/Protos/nanopb/google/api/http.pb.h +++ /dev/null @@ -1,107 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Thu Apr 12 07:27:15 2018. */ - -#ifndef PB_GOOGLE_API_HTTP_PB_H_INCLUDED -#define PB_GOOGLE_API_HTTP_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_api_CustomHttpPattern { - pb_callback_t kind; - pb_callback_t path; -/* @@protoc_insertion_point(struct:google_api_CustomHttpPattern) */ -} google_api_CustomHttpPattern; - -typedef struct _google_api_Http { - pb_callback_t rules; - bool fully_decode_reserved_expansion; -/* @@protoc_insertion_point(struct:google_api_Http) */ -} google_api_Http; - -typedef struct _google_api_HttpRule { - pb_callback_t selector; - pb_callback_t get; - pb_callback_t put; - pb_callback_t post; - pb_callback_t delete_; - pb_callback_t patch; - pb_callback_t body; - google_api_CustomHttpPattern custom; - pb_callback_t additional_bindings; -/* @@protoc_insertion_point(struct:google_api_HttpRule) */ -} google_api_HttpRule; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_api_Http_init_default {{{NULL}, NULL}, 0} -#define google_api_HttpRule_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_api_CustomHttpPattern_init_default, {{NULL}, NULL}} -#define google_api_CustomHttpPattern_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_api_Http_init_zero {{{NULL}, NULL}, 0} -#define google_api_HttpRule_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_api_CustomHttpPattern_init_zero, {{NULL}, NULL}} -#define google_api_CustomHttpPattern_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_api_CustomHttpPattern_kind_tag 1 -#define google_api_CustomHttpPattern_path_tag 2 -#define google_api_Http_rules_tag 1 -#define google_api_Http_fully_decode_reserved_expansion_tag 2 -#define google_api_HttpRule_selector_tag 1 -#define google_api_HttpRule_get_tag 2 -#define google_api_HttpRule_put_tag 3 -#define google_api_HttpRule_post_tag 4 -#define google_api_HttpRule_delete_tag 5 -#define google_api_HttpRule_patch_tag 6 -#define google_api_HttpRule_custom_tag 8 -#define google_api_HttpRule_body_tag 7 -#define google_api_HttpRule_additional_bindings_tag 11 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_api_Http_fields[3]; -extern const pb_field_t google_api_HttpRule_fields[10]; -extern const pb_field_t google_api_CustomHttpPattern_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_api_Http_size depends on runtime parameters */ -/* google_api_HttpRule_size depends on runtime parameters */ -/* google_api_CustomHttpPattern_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define HTTP_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/common.nanopb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/common.nanopb.h new file mode 100644 index 0000000..d0095bc --- /dev/null +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/common.nanopb.h @@ -0,0 +1,124 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_COMMON_PB_H_INCLUDED +#define PB_GOOGLE_FIRESTORE_V1BETA1_COMMON_PB_H_INCLUDED +#include + +#include "google/api/annotations.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_firestore_v1beta1_DocumentMask { + pb_callback_t field_paths; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentMask) */ +} google_firestore_v1beta1_DocumentMask; + +typedef struct _google_firestore_v1beta1_TransactionOptions_ReadWrite { + pb_callback_t retry_transaction; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions_ReadWrite) */ +} google_firestore_v1beta1_TransactionOptions_ReadWrite; + +typedef struct _google_firestore_v1beta1_Precondition { + pb_size_t which_condition_type; + union { + bool exists; + google_protobuf_Timestamp update_time; + } condition_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Precondition) */ +} google_firestore_v1beta1_Precondition; + +typedef struct _google_firestore_v1beta1_TransactionOptions_ReadOnly { + pb_size_t which_consistency_selector; + union { + google_protobuf_Timestamp read_time; + } consistency_selector; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions_ReadOnly) */ +} google_firestore_v1beta1_TransactionOptions_ReadOnly; + +typedef struct _google_firestore_v1beta1_TransactionOptions { + pb_size_t which_mode; + union { + google_firestore_v1beta1_TransactionOptions_ReadOnly read_only; + google_firestore_v1beta1_TransactionOptions_ReadWrite read_write; + } mode; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions) */ +} google_firestore_v1beta1_TransactionOptions; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_firestore_v1beta1_DocumentMask_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_Precondition_init_default {0, {0}} +#define google_firestore_v1beta1_TransactionOptions_init_default {0, {google_firestore_v1beta1_TransactionOptions_ReadOnly_init_default}} +#define google_firestore_v1beta1_TransactionOptions_ReadWrite_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_TransactionOptions_ReadOnly_init_default {0, {google_protobuf_Timestamp_init_default}} +#define google_firestore_v1beta1_DocumentMask_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_Precondition_init_zero {0, {0}} +#define google_firestore_v1beta1_TransactionOptions_init_zero {0, {google_firestore_v1beta1_TransactionOptions_ReadOnly_init_zero}} +#define google_firestore_v1beta1_TransactionOptions_ReadWrite_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_TransactionOptions_ReadOnly_init_zero {0, {google_protobuf_Timestamp_init_zero}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_firestore_v1beta1_DocumentMask_field_paths_tag 1 +#define google_firestore_v1beta1_TransactionOptions_ReadWrite_retry_transaction_tag 1 +#define google_firestore_v1beta1_Precondition_exists_tag 1 +#define google_firestore_v1beta1_Precondition_update_time_tag 2 +#define google_firestore_v1beta1_TransactionOptions_ReadOnly_read_time_tag 2 +#define google_firestore_v1beta1_TransactionOptions_read_only_tag 2 +#define google_firestore_v1beta1_TransactionOptions_read_write_tag 3 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_firestore_v1beta1_DocumentMask_fields[2]; +extern const pb_field_t google_firestore_v1beta1_Precondition_fields[3]; +extern const pb_field_t google_firestore_v1beta1_TransactionOptions_fields[3]; +extern const pb_field_t google_firestore_v1beta1_TransactionOptions_ReadWrite_fields[2]; +extern const pb_field_t google_firestore_v1beta1_TransactionOptions_ReadOnly_fields[2]; + +/* Maximum encoded size of messages (where known) */ +/* google_firestore_v1beta1_DocumentMask_size depends on runtime parameters */ +#define google_firestore_v1beta1_Precondition_size 24 +/* google_firestore_v1beta1_TransactionOptions_size depends on runtime parameters */ +/* google_firestore_v1beta1_TransactionOptions_ReadWrite_size depends on runtime parameters */ +#define google_firestore_v1beta1_TransactionOptions_ReadOnly_size 24 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define COMMON_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.c b/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.c index de2cf65..e740870 100644 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.c +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "common.pb.h" +#include "common.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.h deleted file mode 100644 index 277d9b8..0000000 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/common.pb.h +++ /dev/null @@ -1,124 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_COMMON_PB_H_INCLUDED -#define PB_GOOGLE_FIRESTORE_V1BETA1_COMMON_PB_H_INCLUDED -#include - -#include "google/api/annotations.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_firestore_v1beta1_DocumentMask { - pb_callback_t field_paths; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentMask) */ -} google_firestore_v1beta1_DocumentMask; - -typedef struct _google_firestore_v1beta1_TransactionOptions_ReadWrite { - pb_callback_t retry_transaction; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions_ReadWrite) */ -} google_firestore_v1beta1_TransactionOptions_ReadWrite; - -typedef struct _google_firestore_v1beta1_Precondition { - pb_size_t which_condition_type; - union { - bool exists; - google_protobuf_Timestamp update_time; - } condition_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Precondition) */ -} google_firestore_v1beta1_Precondition; - -typedef struct _google_firestore_v1beta1_TransactionOptions_ReadOnly { - pb_size_t which_consistency_selector; - union { - google_protobuf_Timestamp read_time; - } consistency_selector; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions_ReadOnly) */ -} google_firestore_v1beta1_TransactionOptions_ReadOnly; - -typedef struct _google_firestore_v1beta1_TransactionOptions { - pb_size_t which_mode; - union { - google_firestore_v1beta1_TransactionOptions_ReadOnly read_only; - google_firestore_v1beta1_TransactionOptions_ReadWrite read_write; - } mode; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TransactionOptions) */ -} google_firestore_v1beta1_TransactionOptions; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_firestore_v1beta1_DocumentMask_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_Precondition_init_default {0, {0}} -#define google_firestore_v1beta1_TransactionOptions_init_default {0, {google_firestore_v1beta1_TransactionOptions_ReadOnly_init_default}} -#define google_firestore_v1beta1_TransactionOptions_ReadWrite_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_TransactionOptions_ReadOnly_init_default {0, {google_protobuf_Timestamp_init_default}} -#define google_firestore_v1beta1_DocumentMask_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_Precondition_init_zero {0, {0}} -#define google_firestore_v1beta1_TransactionOptions_init_zero {0, {google_firestore_v1beta1_TransactionOptions_ReadOnly_init_zero}} -#define google_firestore_v1beta1_TransactionOptions_ReadWrite_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_TransactionOptions_ReadOnly_init_zero {0, {google_protobuf_Timestamp_init_zero}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_firestore_v1beta1_DocumentMask_field_paths_tag 1 -#define google_firestore_v1beta1_TransactionOptions_ReadWrite_retry_transaction_tag 1 -#define google_firestore_v1beta1_Precondition_exists_tag 1 -#define google_firestore_v1beta1_Precondition_update_time_tag 2 -#define google_firestore_v1beta1_TransactionOptions_ReadOnly_read_time_tag 2 -#define google_firestore_v1beta1_TransactionOptions_read_only_tag 2 -#define google_firestore_v1beta1_TransactionOptions_read_write_tag 3 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_firestore_v1beta1_DocumentMask_fields[2]; -extern const pb_field_t google_firestore_v1beta1_Precondition_fields[3]; -extern const pb_field_t google_firestore_v1beta1_TransactionOptions_fields[3]; -extern const pb_field_t google_firestore_v1beta1_TransactionOptions_ReadWrite_fields[2]; -extern const pb_field_t google_firestore_v1beta1_TransactionOptions_ReadOnly_fields[2]; - -/* Maximum encoded size of messages (where known) */ -/* google_firestore_v1beta1_DocumentMask_size depends on runtime parameters */ -#define google_firestore_v1beta1_Precondition_size 24 -/* google_firestore_v1beta1_TransactionOptions_size depends on runtime parameters */ -/* google_firestore_v1beta1_TransactionOptions_ReadWrite_size depends on runtime parameters */ -#define google_firestore_v1beta1_TransactionOptions_ReadOnly_size 24 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define COMMON_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h new file mode 100644 index 0000000..f8fdd55 --- /dev/null +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h @@ -0,0 +1,155 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_DOCUMENT_PB_H_INCLUDED +#define PB_GOOGLE_FIRESTORE_V1BETA1_DOCUMENT_PB_H_INCLUDED +#include + +#include "google/api/annotations.nanopb.h" + +#include "google/protobuf/struct.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +#include "google/type/latlng.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_firestore_v1beta1_ArrayValue { + pb_callback_t values; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ArrayValue) */ +} google_firestore_v1beta1_ArrayValue; + +typedef struct _google_firestore_v1beta1_MapValue { + pb_callback_t fields; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_MapValue) */ +} google_firestore_v1beta1_MapValue; + +typedef struct _google_firestore_v1beta1_Document { + pb_callback_t name; + pb_callback_t fields; + google_protobuf_Timestamp create_time; + google_protobuf_Timestamp update_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Document) */ +} google_firestore_v1beta1_Document; + +typedef struct _google_firestore_v1beta1_Value { + bool boolean_value; + int64_t integer_value; + double double_value; + pb_callback_t reference_value; + google_firestore_v1beta1_MapValue map_value; + google_type_LatLng geo_point_value; + google_firestore_v1beta1_ArrayValue array_value; + google_protobuf_Timestamp timestamp_value; + google_protobuf_NullValue null_value; + pb_callback_t string_value; + pb_callback_t bytes_value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Value) */ +} google_firestore_v1beta1_Value; + +typedef struct _google_firestore_v1beta1_Document_FieldsEntry { + pb_callback_t key; + google_firestore_v1beta1_Value value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Document_FieldsEntry) */ +} google_firestore_v1beta1_Document_FieldsEntry; + +typedef struct _google_firestore_v1beta1_MapValue_FieldsEntry { + pb_callback_t key; + google_firestore_v1beta1_Value value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_MapValue_FieldsEntry) */ +} google_firestore_v1beta1_MapValue_FieldsEntry; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_firestore_v1beta1_Document_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_Document_FieldsEntry_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_default} +#define google_firestore_v1beta1_Value_init_default {0, 0, 0, {{NULL}, NULL}, google_firestore_v1beta1_MapValue_init_default, google_type_LatLng_init_default, google_firestore_v1beta1_ArrayValue_init_default, google_protobuf_Timestamp_init_default, (google_protobuf_NullValue)0, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ArrayValue_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_MapValue_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_MapValue_FieldsEntry_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_default} +#define google_firestore_v1beta1_Document_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_Document_FieldsEntry_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_zero} +#define google_firestore_v1beta1_Value_init_zero {0, 0, 0, {{NULL}, NULL}, google_firestore_v1beta1_MapValue_init_zero, google_type_LatLng_init_zero, google_firestore_v1beta1_ArrayValue_init_zero, google_protobuf_Timestamp_init_zero, (google_protobuf_NullValue)0, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ArrayValue_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_MapValue_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_MapValue_FieldsEntry_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_zero} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_firestore_v1beta1_ArrayValue_values_tag 1 +#define google_firestore_v1beta1_MapValue_fields_tag 1 +#define google_firestore_v1beta1_Document_name_tag 1 +#define google_firestore_v1beta1_Document_fields_tag 2 +#define google_firestore_v1beta1_Document_create_time_tag 3 +#define google_firestore_v1beta1_Document_update_time_tag 4 +#define google_firestore_v1beta1_Value_null_value_tag 11 +#define google_firestore_v1beta1_Value_boolean_value_tag 1 +#define google_firestore_v1beta1_Value_integer_value_tag 2 +#define google_firestore_v1beta1_Value_double_value_tag 3 +#define google_firestore_v1beta1_Value_timestamp_value_tag 10 +#define google_firestore_v1beta1_Value_string_value_tag 17 +#define google_firestore_v1beta1_Value_bytes_value_tag 18 +#define google_firestore_v1beta1_Value_reference_value_tag 5 +#define google_firestore_v1beta1_Value_geo_point_value_tag 8 +#define google_firestore_v1beta1_Value_array_value_tag 9 +#define google_firestore_v1beta1_Value_map_value_tag 6 +#define google_firestore_v1beta1_Document_FieldsEntry_key_tag 1 +#define google_firestore_v1beta1_Document_FieldsEntry_value_tag 2 +#define google_firestore_v1beta1_MapValue_FieldsEntry_key_tag 1 +#define google_firestore_v1beta1_MapValue_FieldsEntry_value_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_firestore_v1beta1_Document_fields[5]; +extern const pb_field_t google_firestore_v1beta1_Document_FieldsEntry_fields[3]; +extern const pb_field_t google_firestore_v1beta1_Value_fields[12]; +extern const pb_field_t google_firestore_v1beta1_ArrayValue_fields[2]; +extern const pb_field_t google_firestore_v1beta1_MapValue_fields[2]; +extern const pb_field_t google_firestore_v1beta1_MapValue_FieldsEntry_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_firestore_v1beta1_Document_size depends on runtime parameters */ +/* google_firestore_v1beta1_Document_FieldsEntry_size depends on runtime parameters */ +/* google_firestore_v1beta1_Value_size depends on runtime parameters */ +/* google_firestore_v1beta1_ArrayValue_size depends on runtime parameters */ +/* google_firestore_v1beta1_MapValue_size depends on runtime parameters */ +/* google_firestore_v1beta1_MapValue_FieldsEntry_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define DOCUMENT_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.c b/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.c index 862c884..23d62aa 100644 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.c +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "document.pb.h" +#include "document.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h deleted file mode 100644 index 180c1af..0000000 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h +++ /dev/null @@ -1,155 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_DOCUMENT_PB_H_INCLUDED -#define PB_GOOGLE_FIRESTORE_V1BETA1_DOCUMENT_PB_H_INCLUDED -#include - -#include "google/api/annotations.pb.h" - -#include "google/protobuf/struct.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -#include "google/type/latlng.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_firestore_v1beta1_ArrayValue { - pb_callback_t values; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ArrayValue) */ -} google_firestore_v1beta1_ArrayValue; - -typedef struct _google_firestore_v1beta1_MapValue { - pb_callback_t fields; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_MapValue) */ -} google_firestore_v1beta1_MapValue; - -typedef struct _google_firestore_v1beta1_Document { - pb_callback_t name; - pb_callback_t fields; - google_protobuf_Timestamp create_time; - google_protobuf_Timestamp update_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Document) */ -} google_firestore_v1beta1_Document; - -typedef struct _google_firestore_v1beta1_Value { - bool boolean_value; - int64_t integer_value; - double double_value; - pb_callback_t reference_value; - google_firestore_v1beta1_MapValue map_value; - google_type_LatLng geo_point_value; - google_firestore_v1beta1_ArrayValue array_value; - google_protobuf_Timestamp timestamp_value; - google_protobuf_NullValue null_value; - pb_callback_t string_value; - pb_callback_t bytes_value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Value) */ -} google_firestore_v1beta1_Value; - -typedef struct _google_firestore_v1beta1_Document_FieldsEntry { - pb_callback_t key; - google_firestore_v1beta1_Value value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Document_FieldsEntry) */ -} google_firestore_v1beta1_Document_FieldsEntry; - -typedef struct _google_firestore_v1beta1_MapValue_FieldsEntry { - pb_callback_t key; - google_firestore_v1beta1_Value value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_MapValue_FieldsEntry) */ -} google_firestore_v1beta1_MapValue_FieldsEntry; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_firestore_v1beta1_Document_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_Document_FieldsEntry_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_default} -#define google_firestore_v1beta1_Value_init_default {0, 0, 0, {{NULL}, NULL}, google_firestore_v1beta1_MapValue_init_default, google_type_LatLng_init_default, google_firestore_v1beta1_ArrayValue_init_default, google_protobuf_Timestamp_init_default, (google_protobuf_NullValue)0, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ArrayValue_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_MapValue_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_MapValue_FieldsEntry_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_default} -#define google_firestore_v1beta1_Document_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_Document_FieldsEntry_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_zero} -#define google_firestore_v1beta1_Value_init_zero {0, 0, 0, {{NULL}, NULL}, google_firestore_v1beta1_MapValue_init_zero, google_type_LatLng_init_zero, google_firestore_v1beta1_ArrayValue_init_zero, google_protobuf_Timestamp_init_zero, (google_protobuf_NullValue)0, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ArrayValue_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_MapValue_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_MapValue_FieldsEntry_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Value_init_zero} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_firestore_v1beta1_ArrayValue_values_tag 1 -#define google_firestore_v1beta1_MapValue_fields_tag 1 -#define google_firestore_v1beta1_Document_name_tag 1 -#define google_firestore_v1beta1_Document_fields_tag 2 -#define google_firestore_v1beta1_Document_create_time_tag 3 -#define google_firestore_v1beta1_Document_update_time_tag 4 -#define google_firestore_v1beta1_Value_null_value_tag 11 -#define google_firestore_v1beta1_Value_boolean_value_tag 1 -#define google_firestore_v1beta1_Value_integer_value_tag 2 -#define google_firestore_v1beta1_Value_double_value_tag 3 -#define google_firestore_v1beta1_Value_timestamp_value_tag 10 -#define google_firestore_v1beta1_Value_string_value_tag 17 -#define google_firestore_v1beta1_Value_bytes_value_tag 18 -#define google_firestore_v1beta1_Value_reference_value_tag 5 -#define google_firestore_v1beta1_Value_geo_point_value_tag 8 -#define google_firestore_v1beta1_Value_array_value_tag 9 -#define google_firestore_v1beta1_Value_map_value_tag 6 -#define google_firestore_v1beta1_Document_FieldsEntry_key_tag 1 -#define google_firestore_v1beta1_Document_FieldsEntry_value_tag 2 -#define google_firestore_v1beta1_MapValue_FieldsEntry_key_tag 1 -#define google_firestore_v1beta1_MapValue_FieldsEntry_value_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_firestore_v1beta1_Document_fields[5]; -extern const pb_field_t google_firestore_v1beta1_Document_FieldsEntry_fields[3]; -extern const pb_field_t google_firestore_v1beta1_Value_fields[12]; -extern const pb_field_t google_firestore_v1beta1_ArrayValue_fields[2]; -extern const pb_field_t google_firestore_v1beta1_MapValue_fields[2]; -extern const pb_field_t google_firestore_v1beta1_MapValue_FieldsEntry_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_firestore_v1beta1_Document_size depends on runtime parameters */ -/* google_firestore_v1beta1_Document_FieldsEntry_size depends on runtime parameters */ -/* google_firestore_v1beta1_Value_size depends on runtime parameters */ -/* google_firestore_v1beta1_ArrayValue_size depends on runtime parameters */ -/* google_firestore_v1beta1_MapValue_size depends on runtime parameters */ -/* google_firestore_v1beta1_MapValue_FieldsEntry_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define DOCUMENT_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.nanopb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.nanopb.h new file mode 100644 index 0000000..c8b2132 --- /dev/null +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.nanopb.h @@ -0,0 +1,508 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_FIRESTORE_PB_H_INCLUDED +#define PB_GOOGLE_FIRESTORE_V1BETA1_FIRESTORE_PB_H_INCLUDED +#include + +#include "google/api/annotations.nanopb.h" + +#include "google/firestore/v1beta1/common.nanopb.h" + +#include "google/firestore/v1beta1/document.nanopb.h" + +#include "google/firestore/v1beta1/query.nanopb.h" + +#include "google/firestore/v1beta1/write.nanopb.h" + +#include "google/protobuf/empty.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +#include "google/rpc/status.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Enum definitions */ +typedef enum _google_firestore_v1beta1_TargetChange_TargetChangeType { + google_firestore_v1beta1_TargetChange_TargetChangeType_NO_CHANGE = 0, + google_firestore_v1beta1_TargetChange_TargetChangeType_ADD = 1, + google_firestore_v1beta1_TargetChange_TargetChangeType_REMOVE = 2, + google_firestore_v1beta1_TargetChange_TargetChangeType_CURRENT = 3, + google_firestore_v1beta1_TargetChange_TargetChangeType_RESET = 4 +} google_firestore_v1beta1_TargetChange_TargetChangeType; +#define _google_firestore_v1beta1_TargetChange_TargetChangeType_MIN google_firestore_v1beta1_TargetChange_TargetChangeType_NO_CHANGE +#define _google_firestore_v1beta1_TargetChange_TargetChangeType_MAX google_firestore_v1beta1_TargetChange_TargetChangeType_RESET +#define _google_firestore_v1beta1_TargetChange_TargetChangeType_ARRAYSIZE ((google_firestore_v1beta1_TargetChange_TargetChangeType)(google_firestore_v1beta1_TargetChange_TargetChangeType_RESET+1)) + +/* Struct definitions */ +typedef struct _google_firestore_v1beta1_BeginTransactionResponse { + pb_callback_t transaction; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BeginTransactionResponse) */ +} google_firestore_v1beta1_BeginTransactionResponse; + +typedef struct _google_firestore_v1beta1_CommitRequest { + pb_callback_t database; + pb_callback_t writes; + pb_callback_t transaction; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CommitRequest) */ +} google_firestore_v1beta1_CommitRequest; + +typedef struct _google_firestore_v1beta1_ListCollectionIdsResponse { + pb_callback_t collection_ids; + pb_callback_t next_page_token; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListCollectionIdsResponse) */ +} google_firestore_v1beta1_ListCollectionIdsResponse; + +typedef struct _google_firestore_v1beta1_ListDocumentsResponse { + pb_callback_t documents; + pb_callback_t next_page_token; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListDocumentsResponse) */ +} google_firestore_v1beta1_ListDocumentsResponse; + +typedef struct _google_firestore_v1beta1_ListenRequest_LabelsEntry { + pb_callback_t key; + pb_callback_t value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenRequest_LabelsEntry) */ +} google_firestore_v1beta1_ListenRequest_LabelsEntry; + +typedef struct _google_firestore_v1beta1_RollbackRequest { + pb_callback_t database; + pb_callback_t transaction; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RollbackRequest) */ +} google_firestore_v1beta1_RollbackRequest; + +typedef struct _google_firestore_v1beta1_Target_DocumentsTarget { + pb_callback_t documents; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target_DocumentsTarget) */ +} google_firestore_v1beta1_Target_DocumentsTarget; + +typedef struct _google_firestore_v1beta1_WriteRequest { + pb_callback_t database; + pb_callback_t stream_id; + pb_callback_t writes; + pb_callback_t stream_token; + pb_callback_t labels; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteRequest) */ +} google_firestore_v1beta1_WriteRequest; + +typedef struct _google_firestore_v1beta1_WriteRequest_LabelsEntry { + pb_callback_t key; + pb_callback_t value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteRequest_LabelsEntry) */ +} google_firestore_v1beta1_WriteRequest_LabelsEntry; + +typedef struct _google_firestore_v1beta1_BatchGetDocumentsRequest { + pb_callback_t database; + pb_callback_t documents; + google_firestore_v1beta1_DocumentMask mask; + pb_callback_t transaction; + google_firestore_v1beta1_TransactionOptions new_transaction; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BatchGetDocumentsRequest) */ +} google_firestore_v1beta1_BatchGetDocumentsRequest; + +typedef struct _google_firestore_v1beta1_BatchGetDocumentsResponse { + google_firestore_v1beta1_Document found; + pb_callback_t missing; + pb_callback_t transaction; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BatchGetDocumentsResponse) */ +} google_firestore_v1beta1_BatchGetDocumentsResponse; + +typedef struct _google_firestore_v1beta1_BeginTransactionRequest { + pb_callback_t database; + google_firestore_v1beta1_TransactionOptions options; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BeginTransactionRequest) */ +} google_firestore_v1beta1_BeginTransactionRequest; + +typedef struct _google_firestore_v1beta1_CommitResponse { + pb_callback_t write_results; + google_protobuf_Timestamp commit_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CommitResponse) */ +} google_firestore_v1beta1_CommitResponse; + +typedef struct _google_firestore_v1beta1_CreateDocumentRequest { + pb_callback_t parent; + pb_callback_t collection_id; + pb_callback_t document_id; + google_firestore_v1beta1_Document document; + google_firestore_v1beta1_DocumentMask mask; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CreateDocumentRequest) */ +} google_firestore_v1beta1_CreateDocumentRequest; + +typedef struct _google_firestore_v1beta1_DeleteDocumentRequest { + pb_callback_t name; + google_firestore_v1beta1_Precondition current_document; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DeleteDocumentRequest) */ +} google_firestore_v1beta1_DeleteDocumentRequest; + +typedef struct _google_firestore_v1beta1_GetDocumentRequest { + pb_callback_t name; + google_firestore_v1beta1_DocumentMask mask; + pb_callback_t transaction; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_GetDocumentRequest) */ +} google_firestore_v1beta1_GetDocumentRequest; + +typedef struct _google_firestore_v1beta1_ListCollectionIdsRequest { + pb_callback_t parent; + int32_t page_size; + pb_callback_t page_token; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListCollectionIdsRequest) */ +} google_firestore_v1beta1_ListCollectionIdsRequest; + +typedef struct _google_firestore_v1beta1_ListDocumentsRequest { + pb_callback_t parent; + pb_callback_t collection_id; + int32_t page_size; + pb_callback_t page_token; + pb_callback_t order_by; + google_firestore_v1beta1_DocumentMask mask; + pb_callback_t transaction; + google_protobuf_Timestamp read_time; + bool show_missing; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListDocumentsRequest) */ +} google_firestore_v1beta1_ListDocumentsRequest; + +typedef struct _google_firestore_v1beta1_RunQueryRequest { + pb_callback_t parent; + pb_size_t which_query_type; + union { + google_firestore_v1beta1_StructuredQuery structured_query; + } query_type; + pb_callback_t transaction; + google_firestore_v1beta1_TransactionOptions new_transaction; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RunQueryRequest) */ +} google_firestore_v1beta1_RunQueryRequest; + +typedef struct _google_firestore_v1beta1_RunQueryResponse { + google_firestore_v1beta1_Document document; + pb_callback_t transaction; + google_protobuf_Timestamp read_time; + int32_t skipped_results; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RunQueryResponse) */ +} google_firestore_v1beta1_RunQueryResponse; + +typedef struct _google_firestore_v1beta1_TargetChange { + google_firestore_v1beta1_TargetChange_TargetChangeType target_change_type; + pb_callback_t target_ids; + google_rpc_Status cause; + pb_callback_t resume_token; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TargetChange) */ +} google_firestore_v1beta1_TargetChange; + +typedef struct _google_firestore_v1beta1_Target_QueryTarget { + pb_callback_t parent; + pb_size_t which_query_type; + union { + google_firestore_v1beta1_StructuredQuery structured_query; + } query_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target_QueryTarget) */ +} google_firestore_v1beta1_Target_QueryTarget; + +typedef struct _google_firestore_v1beta1_UpdateDocumentRequest { + google_firestore_v1beta1_Document document; + google_firestore_v1beta1_DocumentMask update_mask; + google_firestore_v1beta1_DocumentMask mask; + google_firestore_v1beta1_Precondition current_document; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_UpdateDocumentRequest) */ +} google_firestore_v1beta1_UpdateDocumentRequest; + +typedef struct _google_firestore_v1beta1_WriteResponse { + pb_callback_t stream_id; + pb_callback_t stream_token; + pb_callback_t write_results; + google_protobuf_Timestamp commit_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteResponse) */ +} google_firestore_v1beta1_WriteResponse; + +typedef struct _google_firestore_v1beta1_ListenResponse { + pb_size_t which_response_type; + union { + google_firestore_v1beta1_TargetChange target_change; + google_firestore_v1beta1_DocumentChange document_change; + google_firestore_v1beta1_DocumentDelete document_delete; + google_firestore_v1beta1_ExistenceFilter filter; + google_firestore_v1beta1_DocumentRemove document_remove; + } response_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenResponse) */ +} google_firestore_v1beta1_ListenResponse; + +typedef struct _google_firestore_v1beta1_Target { + pb_size_t which_target_type; + union { + google_firestore_v1beta1_Target_QueryTarget query; + google_firestore_v1beta1_Target_DocumentsTarget documents; + } target_type; + pb_callback_t resume_token; + int32_t target_id; + bool once; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target) */ +} google_firestore_v1beta1_Target; + +typedef struct _google_firestore_v1beta1_ListenRequest { + pb_callback_t database; + pb_size_t which_target_change; + union { + google_firestore_v1beta1_Target add_target; + int32_t remove_target; + } target_change; + pb_callback_t labels; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenRequest) */ +} google_firestore_v1beta1_ListenRequest; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_firestore_v1beta1_GetDocumentRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_ListDocumentsRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, 0, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, 0} +#define google_firestore_v1beta1_ListDocumentsResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_CreateDocumentRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_Document_init_default, google_firestore_v1beta1_DocumentMask_init_default} +#define google_firestore_v1beta1_UpdateDocumentRequest_init_default {google_firestore_v1beta1_Document_init_default, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_Precondition_init_default} +#define google_firestore_v1beta1_DeleteDocumentRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Precondition_init_default} +#define google_firestore_v1beta1_BatchGetDocumentsRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_BatchGetDocumentsResponse_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_BeginTransactionRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default} +#define google_firestore_v1beta1_BeginTransactionResponse_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_CommitRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_CommitResponse_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_RollbackRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_RunQueryRequest_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_default}, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_RunQueryResponse_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, 0} +#define google_firestore_v1beta1_WriteRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_WriteRequest_LabelsEntry_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_WriteResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_ListenRequest_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_Target_init_default}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListenRequest_LabelsEntry_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListenResponse_init_default {0, {google_firestore_v1beta1_TargetChange_init_default}} +#define google_firestore_v1beta1_Target_init_default {0, {google_firestore_v1beta1_Target_QueryTarget_init_default}, {{NULL}, NULL}, 0, 0, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_Target_DocumentsTarget_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_Target_QueryTarget_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_default}} +#define google_firestore_v1beta1_TargetChange_init_default {(google_firestore_v1beta1_TargetChange_TargetChangeType)0, {{NULL}, NULL}, google_rpc_Status_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_ListCollectionIdsRequest_init_default {{{NULL}, NULL}, 0, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListCollectionIdsResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_GetDocumentRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_ListDocumentsRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, 0, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, 0} +#define google_firestore_v1beta1_ListDocumentsResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_CreateDocumentRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_Document_init_zero, google_firestore_v1beta1_DocumentMask_init_zero} +#define google_firestore_v1beta1_UpdateDocumentRequest_init_zero {google_firestore_v1beta1_Document_init_zero, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_Precondition_init_zero} +#define google_firestore_v1beta1_DeleteDocumentRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Precondition_init_zero} +#define google_firestore_v1beta1_BatchGetDocumentsRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_BatchGetDocumentsResponse_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_BeginTransactionRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero} +#define google_firestore_v1beta1_BeginTransactionResponse_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_CommitRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_CommitResponse_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_RollbackRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_RunQueryRequest_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_zero}, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_RunQueryResponse_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, 0} +#define google_firestore_v1beta1_WriteRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_WriteRequest_LabelsEntry_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_WriteResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_ListenRequest_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_Target_init_zero}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListenRequest_LabelsEntry_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListenResponse_init_zero {0, {google_firestore_v1beta1_TargetChange_init_zero}} +#define google_firestore_v1beta1_Target_init_zero {0, {google_firestore_v1beta1_Target_QueryTarget_init_zero}, {{NULL}, NULL}, 0, 0, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_Target_DocumentsTarget_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_Target_QueryTarget_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_zero}} +#define google_firestore_v1beta1_TargetChange_init_zero {(google_firestore_v1beta1_TargetChange_TargetChangeType)0, {{NULL}, NULL}, google_rpc_Status_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_ListCollectionIdsRequest_init_zero {{{NULL}, NULL}, 0, {{NULL}, NULL}} +#define google_firestore_v1beta1_ListCollectionIdsResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_firestore_v1beta1_BeginTransactionResponse_transaction_tag 1 +#define google_firestore_v1beta1_CommitRequest_database_tag 1 +#define google_firestore_v1beta1_CommitRequest_writes_tag 2 +#define google_firestore_v1beta1_CommitRequest_transaction_tag 3 +#define google_firestore_v1beta1_ListCollectionIdsResponse_collection_ids_tag 1 +#define google_firestore_v1beta1_ListCollectionIdsResponse_next_page_token_tag 2 +#define google_firestore_v1beta1_ListDocumentsResponse_documents_tag 1 +#define google_firestore_v1beta1_ListDocumentsResponse_next_page_token_tag 2 +#define google_firestore_v1beta1_ListenRequest_LabelsEntry_key_tag 1 +#define google_firestore_v1beta1_ListenRequest_LabelsEntry_value_tag 2 +#define google_firestore_v1beta1_RollbackRequest_database_tag 1 +#define google_firestore_v1beta1_RollbackRequest_transaction_tag 2 +#define google_firestore_v1beta1_Target_DocumentsTarget_documents_tag 2 +#define google_firestore_v1beta1_WriteRequest_database_tag 1 +#define google_firestore_v1beta1_WriteRequest_stream_id_tag 2 +#define google_firestore_v1beta1_WriteRequest_writes_tag 3 +#define google_firestore_v1beta1_WriteRequest_stream_token_tag 4 +#define google_firestore_v1beta1_WriteRequest_labels_tag 5 +#define google_firestore_v1beta1_WriteRequest_LabelsEntry_key_tag 1 +#define google_firestore_v1beta1_WriteRequest_LabelsEntry_value_tag 2 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_database_tag 1 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_documents_tag 2 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_mask_tag 3 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_transaction_tag 4 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_new_transaction_tag 5 +#define google_firestore_v1beta1_BatchGetDocumentsRequest_read_time_tag 7 +#define google_firestore_v1beta1_BatchGetDocumentsResponse_found_tag 1 +#define google_firestore_v1beta1_BatchGetDocumentsResponse_missing_tag 2 +#define google_firestore_v1beta1_BatchGetDocumentsResponse_transaction_tag 3 +#define google_firestore_v1beta1_BatchGetDocumentsResponse_read_time_tag 4 +#define google_firestore_v1beta1_BeginTransactionRequest_database_tag 1 +#define google_firestore_v1beta1_BeginTransactionRequest_options_tag 2 +#define google_firestore_v1beta1_CommitResponse_write_results_tag 1 +#define google_firestore_v1beta1_CommitResponse_commit_time_tag 2 +#define google_firestore_v1beta1_CreateDocumentRequest_parent_tag 1 +#define google_firestore_v1beta1_CreateDocumentRequest_collection_id_tag 2 +#define google_firestore_v1beta1_CreateDocumentRequest_document_id_tag 3 +#define google_firestore_v1beta1_CreateDocumentRequest_document_tag 4 +#define google_firestore_v1beta1_CreateDocumentRequest_mask_tag 5 +#define google_firestore_v1beta1_DeleteDocumentRequest_name_tag 1 +#define google_firestore_v1beta1_DeleteDocumentRequest_current_document_tag 2 +#define google_firestore_v1beta1_GetDocumentRequest_name_tag 1 +#define google_firestore_v1beta1_GetDocumentRequest_mask_tag 2 +#define google_firestore_v1beta1_GetDocumentRequest_transaction_tag 3 +#define google_firestore_v1beta1_GetDocumentRequest_read_time_tag 5 +#define google_firestore_v1beta1_ListCollectionIdsRequest_parent_tag 1 +#define google_firestore_v1beta1_ListCollectionIdsRequest_page_size_tag 2 +#define google_firestore_v1beta1_ListCollectionIdsRequest_page_token_tag 3 +#define google_firestore_v1beta1_ListDocumentsRequest_parent_tag 1 +#define google_firestore_v1beta1_ListDocumentsRequest_collection_id_tag 2 +#define google_firestore_v1beta1_ListDocumentsRequest_page_size_tag 3 +#define google_firestore_v1beta1_ListDocumentsRequest_page_token_tag 4 +#define google_firestore_v1beta1_ListDocumentsRequest_order_by_tag 6 +#define google_firestore_v1beta1_ListDocumentsRequest_mask_tag 7 +#define google_firestore_v1beta1_ListDocumentsRequest_transaction_tag 8 +#define google_firestore_v1beta1_ListDocumentsRequest_read_time_tag 10 +#define google_firestore_v1beta1_ListDocumentsRequest_show_missing_tag 12 +#define google_firestore_v1beta1_RunQueryRequest_structured_query_tag 2 +#define google_firestore_v1beta1_RunQueryRequest_parent_tag 1 +#define google_firestore_v1beta1_RunQueryRequest_transaction_tag 5 +#define google_firestore_v1beta1_RunQueryRequest_new_transaction_tag 6 +#define google_firestore_v1beta1_RunQueryRequest_read_time_tag 7 +#define google_firestore_v1beta1_RunQueryResponse_transaction_tag 2 +#define google_firestore_v1beta1_RunQueryResponse_document_tag 1 +#define google_firestore_v1beta1_RunQueryResponse_read_time_tag 3 +#define google_firestore_v1beta1_RunQueryResponse_skipped_results_tag 4 +#define google_firestore_v1beta1_TargetChange_target_change_type_tag 1 +#define google_firestore_v1beta1_TargetChange_target_ids_tag 2 +#define google_firestore_v1beta1_TargetChange_cause_tag 3 +#define google_firestore_v1beta1_TargetChange_resume_token_tag 4 +#define google_firestore_v1beta1_TargetChange_read_time_tag 6 +#define google_firestore_v1beta1_Target_QueryTarget_structured_query_tag 2 +#define google_firestore_v1beta1_Target_QueryTarget_parent_tag 1 +#define google_firestore_v1beta1_UpdateDocumentRequest_document_tag 1 +#define google_firestore_v1beta1_UpdateDocumentRequest_update_mask_tag 2 +#define google_firestore_v1beta1_UpdateDocumentRequest_mask_tag 3 +#define google_firestore_v1beta1_UpdateDocumentRequest_current_document_tag 4 +#define google_firestore_v1beta1_WriteResponse_stream_id_tag 1 +#define google_firestore_v1beta1_WriteResponse_stream_token_tag 2 +#define google_firestore_v1beta1_WriteResponse_write_results_tag 3 +#define google_firestore_v1beta1_WriteResponse_commit_time_tag 4 +#define google_firestore_v1beta1_ListenResponse_target_change_tag 2 +#define google_firestore_v1beta1_ListenResponse_document_change_tag 3 +#define google_firestore_v1beta1_ListenResponse_document_delete_tag 4 +#define google_firestore_v1beta1_ListenResponse_filter_tag 5 +#define google_firestore_v1beta1_ListenResponse_document_remove_tag 6 +#define google_firestore_v1beta1_Target_query_tag 2 +#define google_firestore_v1beta1_Target_documents_tag 3 +#define google_firestore_v1beta1_Target_resume_token_tag 4 +#define google_firestore_v1beta1_Target_read_time_tag 11 +#define google_firestore_v1beta1_Target_target_id_tag 5 +#define google_firestore_v1beta1_Target_once_tag 6 +#define google_firestore_v1beta1_ListenRequest_add_target_tag 2 +#define google_firestore_v1beta1_ListenRequest_remove_target_tag 3 +#define google_firestore_v1beta1_ListenRequest_database_tag 1 +#define google_firestore_v1beta1_ListenRequest_labels_tag 4 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_firestore_v1beta1_GetDocumentRequest_fields[5]; +extern const pb_field_t google_firestore_v1beta1_ListDocumentsRequest_fields[10]; +extern const pb_field_t google_firestore_v1beta1_ListDocumentsResponse_fields[3]; +extern const pb_field_t google_firestore_v1beta1_CreateDocumentRequest_fields[6]; +extern const pb_field_t google_firestore_v1beta1_UpdateDocumentRequest_fields[5]; +extern const pb_field_t google_firestore_v1beta1_DeleteDocumentRequest_fields[3]; +extern const pb_field_t google_firestore_v1beta1_BatchGetDocumentsRequest_fields[7]; +extern const pb_field_t google_firestore_v1beta1_BatchGetDocumentsResponse_fields[5]; +extern const pb_field_t google_firestore_v1beta1_BeginTransactionRequest_fields[3]; +extern const pb_field_t google_firestore_v1beta1_BeginTransactionResponse_fields[2]; +extern const pb_field_t google_firestore_v1beta1_CommitRequest_fields[4]; +extern const pb_field_t google_firestore_v1beta1_CommitResponse_fields[3]; +extern const pb_field_t google_firestore_v1beta1_RollbackRequest_fields[3]; +extern const pb_field_t google_firestore_v1beta1_RunQueryRequest_fields[6]; +extern const pb_field_t google_firestore_v1beta1_RunQueryResponse_fields[5]; +extern const pb_field_t google_firestore_v1beta1_WriteRequest_fields[6]; +extern const pb_field_t google_firestore_v1beta1_WriteRequest_LabelsEntry_fields[3]; +extern const pb_field_t google_firestore_v1beta1_WriteResponse_fields[5]; +extern const pb_field_t google_firestore_v1beta1_ListenRequest_fields[5]; +extern const pb_field_t google_firestore_v1beta1_ListenRequest_LabelsEntry_fields[3]; +extern const pb_field_t google_firestore_v1beta1_ListenResponse_fields[6]; +extern const pb_field_t google_firestore_v1beta1_Target_fields[7]; +extern const pb_field_t google_firestore_v1beta1_Target_DocumentsTarget_fields[2]; +extern const pb_field_t google_firestore_v1beta1_Target_QueryTarget_fields[3]; +extern const pb_field_t google_firestore_v1beta1_TargetChange_fields[6]; +extern const pb_field_t google_firestore_v1beta1_ListCollectionIdsRequest_fields[4]; +extern const pb_field_t google_firestore_v1beta1_ListCollectionIdsResponse_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_firestore_v1beta1_GetDocumentRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListDocumentsRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListDocumentsResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_CreateDocumentRequest_size depends on runtime parameters */ +#define google_firestore_v1beta1_UpdateDocumentRequest_size (44 + google_firestore_v1beta1_Document_size + google_firestore_v1beta1_DocumentMask_size + google_firestore_v1beta1_DocumentMask_size) +/* google_firestore_v1beta1_DeleteDocumentRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_BatchGetDocumentsRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_BatchGetDocumentsResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_BeginTransactionRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_BeginTransactionResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_CommitRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_CommitResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_RollbackRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_RunQueryRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_RunQueryResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_WriteRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_WriteRequest_LabelsEntry_size depends on runtime parameters */ +/* google_firestore_v1beta1_WriteResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListenRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListenRequest_LabelsEntry_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListenResponse_size depends on runtime parameters */ +/* google_firestore_v1beta1_Target_size depends on runtime parameters */ +/* google_firestore_v1beta1_Target_DocumentsTarget_size depends on runtime parameters */ +/* google_firestore_v1beta1_Target_QueryTarget_size depends on runtime parameters */ +/* google_firestore_v1beta1_TargetChange_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListCollectionIdsRequest_size depends on runtime parameters */ +/* google_firestore_v1beta1_ListCollectionIdsResponse_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define FIRESTORE_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.c b/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.c index bc8eca9..56b114a 100644 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.c +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "firestore.pb.h" +#include "firestore.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.h deleted file mode 100644 index 5bfbcf8..0000000 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.h +++ /dev/null @@ -1,508 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_FIRESTORE_PB_H_INCLUDED -#define PB_GOOGLE_FIRESTORE_V1BETA1_FIRESTORE_PB_H_INCLUDED -#include - -#include "google/api/annotations.pb.h" - -#include "google/firestore/v1beta1/common.pb.h" - -#include "google/firestore/v1beta1/document.pb.h" - -#include "google/firestore/v1beta1/query.pb.h" - -#include "google/firestore/v1beta1/write.pb.h" - -#include "google/protobuf/empty.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -#include "google/rpc/status.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Enum definitions */ -typedef enum _google_firestore_v1beta1_TargetChange_TargetChangeType { - google_firestore_v1beta1_TargetChange_TargetChangeType_NO_CHANGE = 0, - google_firestore_v1beta1_TargetChange_TargetChangeType_ADD = 1, - google_firestore_v1beta1_TargetChange_TargetChangeType_REMOVE = 2, - google_firestore_v1beta1_TargetChange_TargetChangeType_CURRENT = 3, - google_firestore_v1beta1_TargetChange_TargetChangeType_RESET = 4 -} google_firestore_v1beta1_TargetChange_TargetChangeType; -#define _google_firestore_v1beta1_TargetChange_TargetChangeType_MIN google_firestore_v1beta1_TargetChange_TargetChangeType_NO_CHANGE -#define _google_firestore_v1beta1_TargetChange_TargetChangeType_MAX google_firestore_v1beta1_TargetChange_TargetChangeType_RESET -#define _google_firestore_v1beta1_TargetChange_TargetChangeType_ARRAYSIZE ((google_firestore_v1beta1_TargetChange_TargetChangeType)(google_firestore_v1beta1_TargetChange_TargetChangeType_RESET+1)) - -/* Struct definitions */ -typedef struct _google_firestore_v1beta1_BeginTransactionResponse { - pb_callback_t transaction; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BeginTransactionResponse) */ -} google_firestore_v1beta1_BeginTransactionResponse; - -typedef struct _google_firestore_v1beta1_CommitRequest { - pb_callback_t database; - pb_callback_t writes; - pb_callback_t transaction; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CommitRequest) */ -} google_firestore_v1beta1_CommitRequest; - -typedef struct _google_firestore_v1beta1_ListCollectionIdsResponse { - pb_callback_t collection_ids; - pb_callback_t next_page_token; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListCollectionIdsResponse) */ -} google_firestore_v1beta1_ListCollectionIdsResponse; - -typedef struct _google_firestore_v1beta1_ListDocumentsResponse { - pb_callback_t documents; - pb_callback_t next_page_token; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListDocumentsResponse) */ -} google_firestore_v1beta1_ListDocumentsResponse; - -typedef struct _google_firestore_v1beta1_ListenRequest_LabelsEntry { - pb_callback_t key; - pb_callback_t value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenRequest_LabelsEntry) */ -} google_firestore_v1beta1_ListenRequest_LabelsEntry; - -typedef struct _google_firestore_v1beta1_RollbackRequest { - pb_callback_t database; - pb_callback_t transaction; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RollbackRequest) */ -} google_firestore_v1beta1_RollbackRequest; - -typedef struct _google_firestore_v1beta1_Target_DocumentsTarget { - pb_callback_t documents; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target_DocumentsTarget) */ -} google_firestore_v1beta1_Target_DocumentsTarget; - -typedef struct _google_firestore_v1beta1_WriteRequest { - pb_callback_t database; - pb_callback_t stream_id; - pb_callback_t writes; - pb_callback_t stream_token; - pb_callback_t labels; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteRequest) */ -} google_firestore_v1beta1_WriteRequest; - -typedef struct _google_firestore_v1beta1_WriteRequest_LabelsEntry { - pb_callback_t key; - pb_callback_t value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteRequest_LabelsEntry) */ -} google_firestore_v1beta1_WriteRequest_LabelsEntry; - -typedef struct _google_firestore_v1beta1_BatchGetDocumentsRequest { - pb_callback_t database; - pb_callback_t documents; - google_firestore_v1beta1_DocumentMask mask; - pb_callback_t transaction; - google_firestore_v1beta1_TransactionOptions new_transaction; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BatchGetDocumentsRequest) */ -} google_firestore_v1beta1_BatchGetDocumentsRequest; - -typedef struct _google_firestore_v1beta1_BatchGetDocumentsResponse { - google_firestore_v1beta1_Document found; - pb_callback_t missing; - pb_callback_t transaction; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BatchGetDocumentsResponse) */ -} google_firestore_v1beta1_BatchGetDocumentsResponse; - -typedef struct _google_firestore_v1beta1_BeginTransactionRequest { - pb_callback_t database; - google_firestore_v1beta1_TransactionOptions options; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_BeginTransactionRequest) */ -} google_firestore_v1beta1_BeginTransactionRequest; - -typedef struct _google_firestore_v1beta1_CommitResponse { - pb_callback_t write_results; - google_protobuf_Timestamp commit_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CommitResponse) */ -} google_firestore_v1beta1_CommitResponse; - -typedef struct _google_firestore_v1beta1_CreateDocumentRequest { - pb_callback_t parent; - pb_callback_t collection_id; - pb_callback_t document_id; - google_firestore_v1beta1_Document document; - google_firestore_v1beta1_DocumentMask mask; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_CreateDocumentRequest) */ -} google_firestore_v1beta1_CreateDocumentRequest; - -typedef struct _google_firestore_v1beta1_DeleteDocumentRequest { - pb_callback_t name; - google_firestore_v1beta1_Precondition current_document; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DeleteDocumentRequest) */ -} google_firestore_v1beta1_DeleteDocumentRequest; - -typedef struct _google_firestore_v1beta1_GetDocumentRequest { - pb_callback_t name; - google_firestore_v1beta1_DocumentMask mask; - pb_callback_t transaction; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_GetDocumentRequest) */ -} google_firestore_v1beta1_GetDocumentRequest; - -typedef struct _google_firestore_v1beta1_ListCollectionIdsRequest { - pb_callback_t parent; - int32_t page_size; - pb_callback_t page_token; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListCollectionIdsRequest) */ -} google_firestore_v1beta1_ListCollectionIdsRequest; - -typedef struct _google_firestore_v1beta1_ListDocumentsRequest { - pb_callback_t parent; - pb_callback_t collection_id; - int32_t page_size; - pb_callback_t page_token; - pb_callback_t order_by; - google_firestore_v1beta1_DocumentMask mask; - pb_callback_t transaction; - google_protobuf_Timestamp read_time; - bool show_missing; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListDocumentsRequest) */ -} google_firestore_v1beta1_ListDocumentsRequest; - -typedef struct _google_firestore_v1beta1_RunQueryRequest { - pb_callback_t parent; - pb_size_t which_query_type; - union { - google_firestore_v1beta1_StructuredQuery structured_query; - } query_type; - pb_callback_t transaction; - google_firestore_v1beta1_TransactionOptions new_transaction; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RunQueryRequest) */ -} google_firestore_v1beta1_RunQueryRequest; - -typedef struct _google_firestore_v1beta1_RunQueryResponse { - google_firestore_v1beta1_Document document; - pb_callback_t transaction; - google_protobuf_Timestamp read_time; - int32_t skipped_results; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_RunQueryResponse) */ -} google_firestore_v1beta1_RunQueryResponse; - -typedef struct _google_firestore_v1beta1_TargetChange { - google_firestore_v1beta1_TargetChange_TargetChangeType target_change_type; - pb_callback_t target_ids; - google_rpc_Status cause; - pb_callback_t resume_token; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_TargetChange) */ -} google_firestore_v1beta1_TargetChange; - -typedef struct _google_firestore_v1beta1_Target_QueryTarget { - pb_callback_t parent; - pb_size_t which_query_type; - union { - google_firestore_v1beta1_StructuredQuery structured_query; - } query_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target_QueryTarget) */ -} google_firestore_v1beta1_Target_QueryTarget; - -typedef struct _google_firestore_v1beta1_UpdateDocumentRequest { - google_firestore_v1beta1_Document document; - google_firestore_v1beta1_DocumentMask update_mask; - google_firestore_v1beta1_DocumentMask mask; - google_firestore_v1beta1_Precondition current_document; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_UpdateDocumentRequest) */ -} google_firestore_v1beta1_UpdateDocumentRequest; - -typedef struct _google_firestore_v1beta1_WriteResponse { - pb_callback_t stream_id; - pb_callback_t stream_token; - pb_callback_t write_results; - google_protobuf_Timestamp commit_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteResponse) */ -} google_firestore_v1beta1_WriteResponse; - -typedef struct _google_firestore_v1beta1_ListenResponse { - pb_size_t which_response_type; - union { - google_firestore_v1beta1_TargetChange target_change; - google_firestore_v1beta1_DocumentChange document_change; - google_firestore_v1beta1_DocumentDelete document_delete; - google_firestore_v1beta1_ExistenceFilter filter; - google_firestore_v1beta1_DocumentRemove document_remove; - } response_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenResponse) */ -} google_firestore_v1beta1_ListenResponse; - -typedef struct _google_firestore_v1beta1_Target { - pb_size_t which_target_type; - union { - google_firestore_v1beta1_Target_QueryTarget query; - google_firestore_v1beta1_Target_DocumentsTarget documents; - } target_type; - pb_callback_t resume_token; - int32_t target_id; - bool once; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Target) */ -} google_firestore_v1beta1_Target; - -typedef struct _google_firestore_v1beta1_ListenRequest { - pb_callback_t database; - pb_size_t which_target_change; - union { - google_firestore_v1beta1_Target add_target; - int32_t remove_target; - } target_change; - pb_callback_t labels; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ListenRequest) */ -} google_firestore_v1beta1_ListenRequest; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_firestore_v1beta1_GetDocumentRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_ListDocumentsRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, 0, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, 0} -#define google_firestore_v1beta1_ListDocumentsResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_CreateDocumentRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_Document_init_default, google_firestore_v1beta1_DocumentMask_init_default} -#define google_firestore_v1beta1_UpdateDocumentRequest_init_default {google_firestore_v1beta1_Document_init_default, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_Precondition_init_default} -#define google_firestore_v1beta1_DeleteDocumentRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_Precondition_init_default} -#define google_firestore_v1beta1_BatchGetDocumentsRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_BatchGetDocumentsResponse_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_BeginTransactionRequest_init_default {{{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default} -#define google_firestore_v1beta1_BeginTransactionResponse_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_CommitRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_CommitResponse_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_RollbackRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_RunQueryRequest_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_default}, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_default, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_RunQueryResponse_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default, 0} -#define google_firestore_v1beta1_WriteRequest_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_WriteRequest_LabelsEntry_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_WriteResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_ListenRequest_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_Target_init_default}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListenRequest_LabelsEntry_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListenResponse_init_default {0, {google_firestore_v1beta1_TargetChange_init_default}} -#define google_firestore_v1beta1_Target_init_default {0, {google_firestore_v1beta1_Target_QueryTarget_init_default}, {{NULL}, NULL}, 0, 0, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_Target_DocumentsTarget_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_Target_QueryTarget_init_default {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_default}} -#define google_firestore_v1beta1_TargetChange_init_default {(google_firestore_v1beta1_TargetChange_TargetChangeType)0, {{NULL}, NULL}, google_rpc_Status_init_default, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_ListCollectionIdsRequest_init_default {{{NULL}, NULL}, 0, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListCollectionIdsResponse_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_GetDocumentRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_ListDocumentsRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, 0, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, 0} -#define google_firestore_v1beta1_ListDocumentsResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_CreateDocumentRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_Document_init_zero, google_firestore_v1beta1_DocumentMask_init_zero} -#define google_firestore_v1beta1_UpdateDocumentRequest_init_zero {google_firestore_v1beta1_Document_init_zero, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_Precondition_init_zero} -#define google_firestore_v1beta1_DeleteDocumentRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_Precondition_init_zero} -#define google_firestore_v1beta1_BatchGetDocumentsRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_BatchGetDocumentsResponse_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_BeginTransactionRequest_init_zero {{{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero} -#define google_firestore_v1beta1_BeginTransactionResponse_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_CommitRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_CommitResponse_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_RollbackRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_RunQueryRequest_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_zero}, {{NULL}, NULL}, google_firestore_v1beta1_TransactionOptions_init_zero, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_RunQueryResponse_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero, 0} -#define google_firestore_v1beta1_WriteRequest_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_WriteRequest_LabelsEntry_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_WriteResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_ListenRequest_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_Target_init_zero}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListenRequest_LabelsEntry_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListenResponse_init_zero {0, {google_firestore_v1beta1_TargetChange_init_zero}} -#define google_firestore_v1beta1_Target_init_zero {0, {google_firestore_v1beta1_Target_QueryTarget_init_zero}, {{NULL}, NULL}, 0, 0, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_Target_DocumentsTarget_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_Target_QueryTarget_init_zero {{{NULL}, NULL}, 0, {google_firestore_v1beta1_StructuredQuery_init_zero}} -#define google_firestore_v1beta1_TargetChange_init_zero {(google_firestore_v1beta1_TargetChange_TargetChangeType)0, {{NULL}, NULL}, google_rpc_Status_init_zero, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_ListCollectionIdsRequest_init_zero {{{NULL}, NULL}, 0, {{NULL}, NULL}} -#define google_firestore_v1beta1_ListCollectionIdsResponse_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_firestore_v1beta1_BeginTransactionResponse_transaction_tag 1 -#define google_firestore_v1beta1_CommitRequest_database_tag 1 -#define google_firestore_v1beta1_CommitRequest_writes_tag 2 -#define google_firestore_v1beta1_CommitRequest_transaction_tag 3 -#define google_firestore_v1beta1_ListCollectionIdsResponse_collection_ids_tag 1 -#define google_firestore_v1beta1_ListCollectionIdsResponse_next_page_token_tag 2 -#define google_firestore_v1beta1_ListDocumentsResponse_documents_tag 1 -#define google_firestore_v1beta1_ListDocumentsResponse_next_page_token_tag 2 -#define google_firestore_v1beta1_ListenRequest_LabelsEntry_key_tag 1 -#define google_firestore_v1beta1_ListenRequest_LabelsEntry_value_tag 2 -#define google_firestore_v1beta1_RollbackRequest_database_tag 1 -#define google_firestore_v1beta1_RollbackRequest_transaction_tag 2 -#define google_firestore_v1beta1_Target_DocumentsTarget_documents_tag 2 -#define google_firestore_v1beta1_WriteRequest_database_tag 1 -#define google_firestore_v1beta1_WriteRequest_stream_id_tag 2 -#define google_firestore_v1beta1_WriteRequest_writes_tag 3 -#define google_firestore_v1beta1_WriteRequest_stream_token_tag 4 -#define google_firestore_v1beta1_WriteRequest_labels_tag 5 -#define google_firestore_v1beta1_WriteRequest_LabelsEntry_key_tag 1 -#define google_firestore_v1beta1_WriteRequest_LabelsEntry_value_tag 2 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_database_tag 1 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_documents_tag 2 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_mask_tag 3 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_transaction_tag 4 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_new_transaction_tag 5 -#define google_firestore_v1beta1_BatchGetDocumentsRequest_read_time_tag 7 -#define google_firestore_v1beta1_BatchGetDocumentsResponse_found_tag 1 -#define google_firestore_v1beta1_BatchGetDocumentsResponse_missing_tag 2 -#define google_firestore_v1beta1_BatchGetDocumentsResponse_transaction_tag 3 -#define google_firestore_v1beta1_BatchGetDocumentsResponse_read_time_tag 4 -#define google_firestore_v1beta1_BeginTransactionRequest_database_tag 1 -#define google_firestore_v1beta1_BeginTransactionRequest_options_tag 2 -#define google_firestore_v1beta1_CommitResponse_write_results_tag 1 -#define google_firestore_v1beta1_CommitResponse_commit_time_tag 2 -#define google_firestore_v1beta1_CreateDocumentRequest_parent_tag 1 -#define google_firestore_v1beta1_CreateDocumentRequest_collection_id_tag 2 -#define google_firestore_v1beta1_CreateDocumentRequest_document_id_tag 3 -#define google_firestore_v1beta1_CreateDocumentRequest_document_tag 4 -#define google_firestore_v1beta1_CreateDocumentRequest_mask_tag 5 -#define google_firestore_v1beta1_DeleteDocumentRequest_name_tag 1 -#define google_firestore_v1beta1_DeleteDocumentRequest_current_document_tag 2 -#define google_firestore_v1beta1_GetDocumentRequest_name_tag 1 -#define google_firestore_v1beta1_GetDocumentRequest_mask_tag 2 -#define google_firestore_v1beta1_GetDocumentRequest_transaction_tag 3 -#define google_firestore_v1beta1_GetDocumentRequest_read_time_tag 5 -#define google_firestore_v1beta1_ListCollectionIdsRequest_parent_tag 1 -#define google_firestore_v1beta1_ListCollectionIdsRequest_page_size_tag 2 -#define google_firestore_v1beta1_ListCollectionIdsRequest_page_token_tag 3 -#define google_firestore_v1beta1_ListDocumentsRequest_parent_tag 1 -#define google_firestore_v1beta1_ListDocumentsRequest_collection_id_tag 2 -#define google_firestore_v1beta1_ListDocumentsRequest_page_size_tag 3 -#define google_firestore_v1beta1_ListDocumentsRequest_page_token_tag 4 -#define google_firestore_v1beta1_ListDocumentsRequest_order_by_tag 6 -#define google_firestore_v1beta1_ListDocumentsRequest_mask_tag 7 -#define google_firestore_v1beta1_ListDocumentsRequest_transaction_tag 8 -#define google_firestore_v1beta1_ListDocumentsRequest_read_time_tag 10 -#define google_firestore_v1beta1_ListDocumentsRequest_show_missing_tag 12 -#define google_firestore_v1beta1_RunQueryRequest_structured_query_tag 2 -#define google_firestore_v1beta1_RunQueryRequest_parent_tag 1 -#define google_firestore_v1beta1_RunQueryRequest_transaction_tag 5 -#define google_firestore_v1beta1_RunQueryRequest_new_transaction_tag 6 -#define google_firestore_v1beta1_RunQueryRequest_read_time_tag 7 -#define google_firestore_v1beta1_RunQueryResponse_transaction_tag 2 -#define google_firestore_v1beta1_RunQueryResponse_document_tag 1 -#define google_firestore_v1beta1_RunQueryResponse_read_time_tag 3 -#define google_firestore_v1beta1_RunQueryResponse_skipped_results_tag 4 -#define google_firestore_v1beta1_TargetChange_target_change_type_tag 1 -#define google_firestore_v1beta1_TargetChange_target_ids_tag 2 -#define google_firestore_v1beta1_TargetChange_cause_tag 3 -#define google_firestore_v1beta1_TargetChange_resume_token_tag 4 -#define google_firestore_v1beta1_TargetChange_read_time_tag 6 -#define google_firestore_v1beta1_Target_QueryTarget_structured_query_tag 2 -#define google_firestore_v1beta1_Target_QueryTarget_parent_tag 1 -#define google_firestore_v1beta1_UpdateDocumentRequest_document_tag 1 -#define google_firestore_v1beta1_UpdateDocumentRequest_update_mask_tag 2 -#define google_firestore_v1beta1_UpdateDocumentRequest_mask_tag 3 -#define google_firestore_v1beta1_UpdateDocumentRequest_current_document_tag 4 -#define google_firestore_v1beta1_WriteResponse_stream_id_tag 1 -#define google_firestore_v1beta1_WriteResponse_stream_token_tag 2 -#define google_firestore_v1beta1_WriteResponse_write_results_tag 3 -#define google_firestore_v1beta1_WriteResponse_commit_time_tag 4 -#define google_firestore_v1beta1_ListenResponse_target_change_tag 2 -#define google_firestore_v1beta1_ListenResponse_document_change_tag 3 -#define google_firestore_v1beta1_ListenResponse_document_delete_tag 4 -#define google_firestore_v1beta1_ListenResponse_filter_tag 5 -#define google_firestore_v1beta1_ListenResponse_document_remove_tag 6 -#define google_firestore_v1beta1_Target_query_tag 2 -#define google_firestore_v1beta1_Target_documents_tag 3 -#define google_firestore_v1beta1_Target_resume_token_tag 4 -#define google_firestore_v1beta1_Target_read_time_tag 11 -#define google_firestore_v1beta1_Target_target_id_tag 5 -#define google_firestore_v1beta1_Target_once_tag 6 -#define google_firestore_v1beta1_ListenRequest_add_target_tag 2 -#define google_firestore_v1beta1_ListenRequest_remove_target_tag 3 -#define google_firestore_v1beta1_ListenRequest_database_tag 1 -#define google_firestore_v1beta1_ListenRequest_labels_tag 4 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_firestore_v1beta1_GetDocumentRequest_fields[5]; -extern const pb_field_t google_firestore_v1beta1_ListDocumentsRequest_fields[10]; -extern const pb_field_t google_firestore_v1beta1_ListDocumentsResponse_fields[3]; -extern const pb_field_t google_firestore_v1beta1_CreateDocumentRequest_fields[6]; -extern const pb_field_t google_firestore_v1beta1_UpdateDocumentRequest_fields[5]; -extern const pb_field_t google_firestore_v1beta1_DeleteDocumentRequest_fields[3]; -extern const pb_field_t google_firestore_v1beta1_BatchGetDocumentsRequest_fields[7]; -extern const pb_field_t google_firestore_v1beta1_BatchGetDocumentsResponse_fields[5]; -extern const pb_field_t google_firestore_v1beta1_BeginTransactionRequest_fields[3]; -extern const pb_field_t google_firestore_v1beta1_BeginTransactionResponse_fields[2]; -extern const pb_field_t google_firestore_v1beta1_CommitRequest_fields[4]; -extern const pb_field_t google_firestore_v1beta1_CommitResponse_fields[3]; -extern const pb_field_t google_firestore_v1beta1_RollbackRequest_fields[3]; -extern const pb_field_t google_firestore_v1beta1_RunQueryRequest_fields[6]; -extern const pb_field_t google_firestore_v1beta1_RunQueryResponse_fields[5]; -extern const pb_field_t google_firestore_v1beta1_WriteRequest_fields[6]; -extern const pb_field_t google_firestore_v1beta1_WriteRequest_LabelsEntry_fields[3]; -extern const pb_field_t google_firestore_v1beta1_WriteResponse_fields[5]; -extern const pb_field_t google_firestore_v1beta1_ListenRequest_fields[5]; -extern const pb_field_t google_firestore_v1beta1_ListenRequest_LabelsEntry_fields[3]; -extern const pb_field_t google_firestore_v1beta1_ListenResponse_fields[6]; -extern const pb_field_t google_firestore_v1beta1_Target_fields[7]; -extern const pb_field_t google_firestore_v1beta1_Target_DocumentsTarget_fields[2]; -extern const pb_field_t google_firestore_v1beta1_Target_QueryTarget_fields[3]; -extern const pb_field_t google_firestore_v1beta1_TargetChange_fields[6]; -extern const pb_field_t google_firestore_v1beta1_ListCollectionIdsRequest_fields[4]; -extern const pb_field_t google_firestore_v1beta1_ListCollectionIdsResponse_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_firestore_v1beta1_GetDocumentRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListDocumentsRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListDocumentsResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_CreateDocumentRequest_size depends on runtime parameters */ -#define google_firestore_v1beta1_UpdateDocumentRequest_size (44 + google_firestore_v1beta1_Document_size + google_firestore_v1beta1_DocumentMask_size + google_firestore_v1beta1_DocumentMask_size) -/* google_firestore_v1beta1_DeleteDocumentRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_BatchGetDocumentsRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_BatchGetDocumentsResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_BeginTransactionRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_BeginTransactionResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_CommitRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_CommitResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_RollbackRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_RunQueryRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_RunQueryResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_WriteRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_WriteRequest_LabelsEntry_size depends on runtime parameters */ -/* google_firestore_v1beta1_WriteResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListenRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListenRequest_LabelsEntry_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListenResponse_size depends on runtime parameters */ -/* google_firestore_v1beta1_Target_size depends on runtime parameters */ -/* google_firestore_v1beta1_Target_DocumentsTarget_size depends on runtime parameters */ -/* google_firestore_v1beta1_Target_QueryTarget_size depends on runtime parameters */ -/* google_firestore_v1beta1_TargetChange_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListCollectionIdsRequest_size depends on runtime parameters */ -/* google_firestore_v1beta1_ListCollectionIdsResponse_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define FIRESTORE_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/query.nanopb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/query.nanopb.h new file mode 100644 index 0000000..68ac2a5 --- /dev/null +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/query.nanopb.h @@ -0,0 +1,241 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_QUERY_PB_H_INCLUDED +#define PB_GOOGLE_FIRESTORE_V1BETA1_QUERY_PB_H_INCLUDED +#include + +#include "google/api/annotations.nanopb.h" + +#include "google/firestore/v1beta1/document.nanopb.h" + +#include "google/protobuf/wrappers.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Enum definitions */ +typedef enum _google_firestore_v1beta1_StructuredQuery_Direction { + google_firestore_v1beta1_StructuredQuery_Direction_DIRECTION_UNSPECIFIED = 0, + google_firestore_v1beta1_StructuredQuery_Direction_ASCENDING = 1, + google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING = 2 +} google_firestore_v1beta1_StructuredQuery_Direction; +#define _google_firestore_v1beta1_StructuredQuery_Direction_MIN google_firestore_v1beta1_StructuredQuery_Direction_DIRECTION_UNSPECIFIED +#define _google_firestore_v1beta1_StructuredQuery_Direction_MAX google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING +#define _google_firestore_v1beta1_StructuredQuery_Direction_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_Direction)(google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING+1)) + +typedef enum _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator { + google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_OPERATOR_UNSPECIFIED = 0, + google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND = 1 +} google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator; +#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_OPERATOR_UNSPECIFIED +#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND +#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND+1)) + +typedef enum _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator { + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_OPERATOR_UNSPECIFIED = 0, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_LESS_THAN = 1, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_LESS_THAN_OR_EQUAL = 2, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_GREATER_THAN = 3, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_GREATER_THAN_OR_EQUAL = 4, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_EQUAL = 5, + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS = 7 +} google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator; +#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_OPERATOR_UNSPECIFIED +#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS +#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)(google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS+1)) + +typedef enum _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator { + google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_OPERATOR_UNSPECIFIED = 0, + google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NAN = 2, + google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL = 3 +} google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator; +#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_OPERATOR_UNSPECIFIED +#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL +#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL+1)) + +/* Struct definitions */ +typedef struct _google_firestore_v1beta1_StructuredQuery_FieldReference { + pb_callback_t field_path; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_FieldReference) */ +} google_firestore_v1beta1_StructuredQuery_FieldReference; + +typedef struct _google_firestore_v1beta1_StructuredQuery_Projection { + pb_callback_t fields; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Projection) */ +} google_firestore_v1beta1_StructuredQuery_Projection; + +typedef struct _google_firestore_v1beta1_Cursor { + pb_callback_t values; + bool before; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Cursor) */ +} google_firestore_v1beta1_Cursor; + +typedef struct _google_firestore_v1beta1_StructuredQuery_CollectionSelector { + pb_callback_t collection_id; + bool all_descendants; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_CollectionSelector) */ +} google_firestore_v1beta1_StructuredQuery_CollectionSelector; + +typedef struct _google_firestore_v1beta1_StructuredQuery_CompositeFilter { + google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator op; + pb_callback_t filters; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_CompositeFilter) */ +} google_firestore_v1beta1_StructuredQuery_CompositeFilter; + +typedef struct _google_firestore_v1beta1_StructuredQuery_FieldFilter { + google_firestore_v1beta1_StructuredQuery_FieldReference field; + google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator op; + google_firestore_v1beta1_Value value; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_FieldFilter) */ +} google_firestore_v1beta1_StructuredQuery_FieldFilter; + +typedef struct _google_firestore_v1beta1_StructuredQuery_Order { + google_firestore_v1beta1_StructuredQuery_FieldReference field; + google_firestore_v1beta1_StructuredQuery_Direction direction; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Order) */ +} google_firestore_v1beta1_StructuredQuery_Order; + +typedef struct _google_firestore_v1beta1_StructuredQuery_UnaryFilter { + google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator op; + pb_size_t which_operand_type; + union { + google_firestore_v1beta1_StructuredQuery_FieldReference field; + } operand_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_UnaryFilter) */ +} google_firestore_v1beta1_StructuredQuery_UnaryFilter; + +typedef struct _google_firestore_v1beta1_StructuredQuery_Filter { + pb_size_t which_filter_type; + union { + google_firestore_v1beta1_StructuredQuery_CompositeFilter composite_filter; + google_firestore_v1beta1_StructuredQuery_FieldFilter field_filter; + google_firestore_v1beta1_StructuredQuery_UnaryFilter unary_filter; + } filter_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Filter) */ +} google_firestore_v1beta1_StructuredQuery_Filter; + +typedef struct _google_firestore_v1beta1_StructuredQuery { + google_firestore_v1beta1_StructuredQuery_Projection select; + pb_callback_t from; + google_firestore_v1beta1_StructuredQuery_Filter where; + pb_callback_t order_by; + google_protobuf_Int32Value limit; + int32_t offset; + google_firestore_v1beta1_Cursor start_at; + google_firestore_v1beta1_Cursor end_at; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery) */ +} google_firestore_v1beta1_StructuredQuery; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_firestore_v1beta1_StructuredQuery_init_default {google_firestore_v1beta1_StructuredQuery_Projection_init_default, {{NULL}, NULL}, google_firestore_v1beta1_StructuredQuery_Filter_init_default, {{NULL}, NULL}, google_protobuf_Int32Value_init_default, 0, google_firestore_v1beta1_Cursor_init_default, google_firestore_v1beta1_Cursor_init_default} +#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_init_default {{{NULL}, NULL}, 0} +#define google_firestore_v1beta1_StructuredQuery_Filter_init_default {0, {google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_default}} +#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_default {(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)0, {{NULL}, NULL}} +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_init_default {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default, (google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)0, google_firestore_v1beta1_Value_init_default} +#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_init_default {(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)0, 0, {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default}} +#define google_firestore_v1beta1_StructuredQuery_Order_init_default {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default, (google_firestore_v1beta1_StructuredQuery_Direction)0} +#define google_firestore_v1beta1_StructuredQuery_FieldReference_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_StructuredQuery_Projection_init_default {{{NULL}, NULL}} +#define google_firestore_v1beta1_Cursor_init_default {{{NULL}, NULL}, 0} +#define google_firestore_v1beta1_StructuredQuery_init_zero {google_firestore_v1beta1_StructuredQuery_Projection_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_StructuredQuery_Filter_init_zero, {{NULL}, NULL}, google_protobuf_Int32Value_init_zero, 0, google_firestore_v1beta1_Cursor_init_zero, google_firestore_v1beta1_Cursor_init_zero} +#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_init_zero {{{NULL}, NULL}, 0} +#define google_firestore_v1beta1_StructuredQuery_Filter_init_zero {0, {google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_zero}} +#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_zero {(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)0, {{NULL}, NULL}} +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_init_zero {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero, (google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)0, google_firestore_v1beta1_Value_init_zero} +#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_init_zero {(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)0, 0, {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero}} +#define google_firestore_v1beta1_StructuredQuery_Order_init_zero {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero, (google_firestore_v1beta1_StructuredQuery_Direction)0} +#define google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_StructuredQuery_Projection_init_zero {{{NULL}, NULL}} +#define google_firestore_v1beta1_Cursor_init_zero {{{NULL}, NULL}, 0} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_firestore_v1beta1_StructuredQuery_FieldReference_field_path_tag 2 +#define google_firestore_v1beta1_StructuredQuery_Projection_fields_tag 2 +#define google_firestore_v1beta1_Cursor_values_tag 1 +#define google_firestore_v1beta1_Cursor_before_tag 2 +#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_collection_id_tag 2 +#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_all_descendants_tag 3 +#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_op_tag 1 +#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_filters_tag 2 +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_field_tag 1 +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_op_tag 2 +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_value_tag 3 +#define google_firestore_v1beta1_StructuredQuery_Order_field_tag 1 +#define google_firestore_v1beta1_StructuredQuery_Order_direction_tag 2 +#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_field_tag 2 +#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_op_tag 1 +#define google_firestore_v1beta1_StructuredQuery_Filter_composite_filter_tag 1 +#define google_firestore_v1beta1_StructuredQuery_Filter_field_filter_tag 2 +#define google_firestore_v1beta1_StructuredQuery_Filter_unary_filter_tag 3 +#define google_firestore_v1beta1_StructuredQuery_select_tag 1 +#define google_firestore_v1beta1_StructuredQuery_from_tag 2 +#define google_firestore_v1beta1_StructuredQuery_where_tag 3 +#define google_firestore_v1beta1_StructuredQuery_order_by_tag 4 +#define google_firestore_v1beta1_StructuredQuery_start_at_tag 7 +#define google_firestore_v1beta1_StructuredQuery_end_at_tag 8 +#define google_firestore_v1beta1_StructuredQuery_offset_tag 6 +#define google_firestore_v1beta1_StructuredQuery_limit_tag 5 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_fields[9]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_CollectionSelector_fields[3]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Filter_fields[4]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_CompositeFilter_fields[3]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_FieldFilter_fields[4]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_UnaryFilter_fields[3]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Order_fields[3]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_FieldReference_fields[2]; +extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Projection_fields[2]; +extern const pb_field_t google_firestore_v1beta1_Cursor_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_firestore_v1beta1_StructuredQuery_size depends on runtime parameters */ +/* google_firestore_v1beta1_StructuredQuery_CollectionSelector_size depends on runtime parameters */ +/* google_firestore_v1beta1_StructuredQuery_Filter_size depends on runtime parameters */ +/* google_firestore_v1beta1_StructuredQuery_CompositeFilter_size depends on runtime parameters */ +#define google_firestore_v1beta1_StructuredQuery_FieldFilter_size (14 + google_firestore_v1beta1_StructuredQuery_FieldReference_size + google_firestore_v1beta1_Value_size) +/* google_firestore_v1beta1_StructuredQuery_UnaryFilter_size depends on runtime parameters */ +#define google_firestore_v1beta1_StructuredQuery_Order_size (8 + google_firestore_v1beta1_StructuredQuery_FieldReference_size) +/* google_firestore_v1beta1_StructuredQuery_FieldReference_size depends on runtime parameters */ +/* google_firestore_v1beta1_StructuredQuery_Projection_size depends on runtime parameters */ +/* google_firestore_v1beta1_Cursor_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define QUERY_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.c b/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.c index 4e68490..a392327 100644 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.c +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "query.pb.h" +#include "query.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.h deleted file mode 100644 index 75b8168..0000000 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/query.pb.h +++ /dev/null @@ -1,241 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Thu Apr 12 07:27:15 2018. */ - -#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_QUERY_PB_H_INCLUDED -#define PB_GOOGLE_FIRESTORE_V1BETA1_QUERY_PB_H_INCLUDED -#include - -#include "google/api/annotations.pb.h" - -#include "google/firestore/v1beta1/document.pb.h" - -#include "google/protobuf/wrappers.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Enum definitions */ -typedef enum _google_firestore_v1beta1_StructuredQuery_Direction { - google_firestore_v1beta1_StructuredQuery_Direction_DIRECTION_UNSPECIFIED = 0, - google_firestore_v1beta1_StructuredQuery_Direction_ASCENDING = 1, - google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING = 2 -} google_firestore_v1beta1_StructuredQuery_Direction; -#define _google_firestore_v1beta1_StructuredQuery_Direction_MIN google_firestore_v1beta1_StructuredQuery_Direction_DIRECTION_UNSPECIFIED -#define _google_firestore_v1beta1_StructuredQuery_Direction_MAX google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING -#define _google_firestore_v1beta1_StructuredQuery_Direction_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_Direction)(google_firestore_v1beta1_StructuredQuery_Direction_DESCENDING+1)) - -typedef enum _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator { - google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_OPERATOR_UNSPECIFIED = 0, - google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND = 1 -} google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator; -#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_OPERATOR_UNSPECIFIED -#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND -#define _google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator_AND+1)) - -typedef enum _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator { - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_OPERATOR_UNSPECIFIED = 0, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_LESS_THAN = 1, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_LESS_THAN_OR_EQUAL = 2, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_GREATER_THAN = 3, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_GREATER_THAN_OR_EQUAL = 4, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_EQUAL = 5, - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS = 7 -} google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator; -#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_OPERATOR_UNSPECIFIED -#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS -#define _google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)(google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator_ARRAY_CONTAINS+1)) - -typedef enum _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator { - google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_OPERATOR_UNSPECIFIED = 0, - google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NAN = 2, - google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL = 3 -} google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator; -#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_MIN google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_OPERATOR_UNSPECIFIED -#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_MAX google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL -#define _google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_ARRAYSIZE ((google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator_IS_NULL+1)) - -/* Struct definitions */ -typedef struct _google_firestore_v1beta1_StructuredQuery_FieldReference { - pb_callback_t field_path; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_FieldReference) */ -} google_firestore_v1beta1_StructuredQuery_FieldReference; - -typedef struct _google_firestore_v1beta1_StructuredQuery_Projection { - pb_callback_t fields; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Projection) */ -} google_firestore_v1beta1_StructuredQuery_Projection; - -typedef struct _google_firestore_v1beta1_Cursor { - pb_callback_t values; - bool before; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Cursor) */ -} google_firestore_v1beta1_Cursor; - -typedef struct _google_firestore_v1beta1_StructuredQuery_CollectionSelector { - pb_callback_t collection_id; - bool all_descendants; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_CollectionSelector) */ -} google_firestore_v1beta1_StructuredQuery_CollectionSelector; - -typedef struct _google_firestore_v1beta1_StructuredQuery_CompositeFilter { - google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator op; - pb_callback_t filters; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_CompositeFilter) */ -} google_firestore_v1beta1_StructuredQuery_CompositeFilter; - -typedef struct _google_firestore_v1beta1_StructuredQuery_FieldFilter { - google_firestore_v1beta1_StructuredQuery_FieldReference field; - google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator op; - google_firestore_v1beta1_Value value; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_FieldFilter) */ -} google_firestore_v1beta1_StructuredQuery_FieldFilter; - -typedef struct _google_firestore_v1beta1_StructuredQuery_Order { - google_firestore_v1beta1_StructuredQuery_FieldReference field; - google_firestore_v1beta1_StructuredQuery_Direction direction; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Order) */ -} google_firestore_v1beta1_StructuredQuery_Order; - -typedef struct _google_firestore_v1beta1_StructuredQuery_UnaryFilter { - google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator op; - pb_size_t which_operand_type; - union { - google_firestore_v1beta1_StructuredQuery_FieldReference field; - } operand_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_UnaryFilter) */ -} google_firestore_v1beta1_StructuredQuery_UnaryFilter; - -typedef struct _google_firestore_v1beta1_StructuredQuery_Filter { - pb_size_t which_filter_type; - union { - google_firestore_v1beta1_StructuredQuery_CompositeFilter composite_filter; - google_firestore_v1beta1_StructuredQuery_FieldFilter field_filter; - google_firestore_v1beta1_StructuredQuery_UnaryFilter unary_filter; - } filter_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery_Filter) */ -} google_firestore_v1beta1_StructuredQuery_Filter; - -typedef struct _google_firestore_v1beta1_StructuredQuery { - google_firestore_v1beta1_StructuredQuery_Projection select; - pb_callback_t from; - google_firestore_v1beta1_StructuredQuery_Filter where; - pb_callback_t order_by; - google_protobuf_Int32Value limit; - int32_t offset; - google_firestore_v1beta1_Cursor start_at; - google_firestore_v1beta1_Cursor end_at; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_StructuredQuery) */ -} google_firestore_v1beta1_StructuredQuery; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_firestore_v1beta1_StructuredQuery_init_default {google_firestore_v1beta1_StructuredQuery_Projection_init_default, {{NULL}, NULL}, google_firestore_v1beta1_StructuredQuery_Filter_init_default, {{NULL}, NULL}, google_protobuf_Int32Value_init_default, 0, google_firestore_v1beta1_Cursor_init_default, google_firestore_v1beta1_Cursor_init_default} -#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_init_default {{{NULL}, NULL}, 0} -#define google_firestore_v1beta1_StructuredQuery_Filter_init_default {0, {google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_default}} -#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_default {(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)0, {{NULL}, NULL}} -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_init_default {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default, (google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)0, google_firestore_v1beta1_Value_init_default} -#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_init_default {(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)0, 0, {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default}} -#define google_firestore_v1beta1_StructuredQuery_Order_init_default {google_firestore_v1beta1_StructuredQuery_FieldReference_init_default, (google_firestore_v1beta1_StructuredQuery_Direction)0} -#define google_firestore_v1beta1_StructuredQuery_FieldReference_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_StructuredQuery_Projection_init_default {{{NULL}, NULL}} -#define google_firestore_v1beta1_Cursor_init_default {{{NULL}, NULL}, 0} -#define google_firestore_v1beta1_StructuredQuery_init_zero {google_firestore_v1beta1_StructuredQuery_Projection_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_StructuredQuery_Filter_init_zero, {{NULL}, NULL}, google_protobuf_Int32Value_init_zero, 0, google_firestore_v1beta1_Cursor_init_zero, google_firestore_v1beta1_Cursor_init_zero} -#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_init_zero {{{NULL}, NULL}, 0} -#define google_firestore_v1beta1_StructuredQuery_Filter_init_zero {0, {google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_zero}} -#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_init_zero {(google_firestore_v1beta1_StructuredQuery_CompositeFilter_Operator)0, {{NULL}, NULL}} -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_init_zero {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero, (google_firestore_v1beta1_StructuredQuery_FieldFilter_Operator)0, google_firestore_v1beta1_Value_init_zero} -#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_init_zero {(google_firestore_v1beta1_StructuredQuery_UnaryFilter_Operator)0, 0, {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero}} -#define google_firestore_v1beta1_StructuredQuery_Order_init_zero {google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero, (google_firestore_v1beta1_StructuredQuery_Direction)0} -#define google_firestore_v1beta1_StructuredQuery_FieldReference_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_StructuredQuery_Projection_init_zero {{{NULL}, NULL}} -#define google_firestore_v1beta1_Cursor_init_zero {{{NULL}, NULL}, 0} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_firestore_v1beta1_StructuredQuery_FieldReference_field_path_tag 2 -#define google_firestore_v1beta1_StructuredQuery_Projection_fields_tag 2 -#define google_firestore_v1beta1_Cursor_values_tag 1 -#define google_firestore_v1beta1_Cursor_before_tag 2 -#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_collection_id_tag 2 -#define google_firestore_v1beta1_StructuredQuery_CollectionSelector_all_descendants_tag 3 -#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_op_tag 1 -#define google_firestore_v1beta1_StructuredQuery_CompositeFilter_filters_tag 2 -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_field_tag 1 -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_op_tag 2 -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_value_tag 3 -#define google_firestore_v1beta1_StructuredQuery_Order_field_tag 1 -#define google_firestore_v1beta1_StructuredQuery_Order_direction_tag 2 -#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_field_tag 2 -#define google_firestore_v1beta1_StructuredQuery_UnaryFilter_op_tag 1 -#define google_firestore_v1beta1_StructuredQuery_Filter_composite_filter_tag 1 -#define google_firestore_v1beta1_StructuredQuery_Filter_field_filter_tag 2 -#define google_firestore_v1beta1_StructuredQuery_Filter_unary_filter_tag 3 -#define google_firestore_v1beta1_StructuredQuery_select_tag 1 -#define google_firestore_v1beta1_StructuredQuery_from_tag 2 -#define google_firestore_v1beta1_StructuredQuery_where_tag 3 -#define google_firestore_v1beta1_StructuredQuery_order_by_tag 4 -#define google_firestore_v1beta1_StructuredQuery_start_at_tag 7 -#define google_firestore_v1beta1_StructuredQuery_end_at_tag 8 -#define google_firestore_v1beta1_StructuredQuery_offset_tag 6 -#define google_firestore_v1beta1_StructuredQuery_limit_tag 5 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_fields[9]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_CollectionSelector_fields[3]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Filter_fields[4]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_CompositeFilter_fields[3]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_FieldFilter_fields[4]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_UnaryFilter_fields[3]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Order_fields[3]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_FieldReference_fields[2]; -extern const pb_field_t google_firestore_v1beta1_StructuredQuery_Projection_fields[2]; -extern const pb_field_t google_firestore_v1beta1_Cursor_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_firestore_v1beta1_StructuredQuery_size depends on runtime parameters */ -/* google_firestore_v1beta1_StructuredQuery_CollectionSelector_size depends on runtime parameters */ -/* google_firestore_v1beta1_StructuredQuery_Filter_size depends on runtime parameters */ -/* google_firestore_v1beta1_StructuredQuery_CompositeFilter_size depends on runtime parameters */ -#define google_firestore_v1beta1_StructuredQuery_FieldFilter_size (14 + google_firestore_v1beta1_StructuredQuery_FieldReference_size + google_firestore_v1beta1_Value_size) -/* google_firestore_v1beta1_StructuredQuery_UnaryFilter_size depends on runtime parameters */ -#define google_firestore_v1beta1_StructuredQuery_Order_size (8 + google_firestore_v1beta1_StructuredQuery_FieldReference_size) -/* google_firestore_v1beta1_StructuredQuery_FieldReference_size depends on runtime parameters */ -/* google_firestore_v1beta1_StructuredQuery_Projection_size depends on runtime parameters */ -/* google_firestore_v1beta1_Cursor_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define QUERY_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/write.nanopb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/write.nanopb.h new file mode 100644 index 0000000..4c4e6ba --- /dev/null +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/write.nanopb.h @@ -0,0 +1,189 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_WRITE_PB_H_INCLUDED +#define PB_GOOGLE_FIRESTORE_V1BETA1_WRITE_PB_H_INCLUDED +#include + +#include "google/api/annotations.nanopb.h" + +#include "google/firestore/v1beta1/common.nanopb.h" + +#include "google/firestore/v1beta1/document.nanopb.h" + +#include "google/protobuf/timestamp.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Enum definitions */ +typedef enum _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue { + google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_SERVER_VALUE_UNSPECIFIED = 0, + google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME = 1 +} google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue; +#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_MIN google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_SERVER_VALUE_UNSPECIFIED +#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_MAX google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME +#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_ARRAYSIZE ((google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME+1)) + +/* Struct definitions */ +typedef struct _google_firestore_v1beta1_DocumentTransform { + pb_callback_t document; + pb_callback_t field_transforms; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentTransform) */ +} google_firestore_v1beta1_DocumentTransform; + +typedef struct _google_firestore_v1beta1_DocumentChange { + google_firestore_v1beta1_Document document; + pb_callback_t target_ids; + pb_callback_t removed_target_ids; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentChange) */ +} google_firestore_v1beta1_DocumentChange; + +typedef struct _google_firestore_v1beta1_DocumentDelete { + pb_callback_t document; + google_protobuf_Timestamp read_time; + pb_callback_t removed_target_ids; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentDelete) */ +} google_firestore_v1beta1_DocumentDelete; + +typedef struct _google_firestore_v1beta1_DocumentRemove { + pb_callback_t document; + pb_callback_t removed_target_ids; + google_protobuf_Timestamp read_time; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentRemove) */ +} google_firestore_v1beta1_DocumentRemove; + +typedef struct _google_firestore_v1beta1_DocumentTransform_FieldTransform { + pb_callback_t field_path; + pb_size_t which_transform_type; + union { + google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue set_to_server_value; + google_firestore_v1beta1_ArrayValue append_missing_elements; + google_firestore_v1beta1_ArrayValue remove_all_from_array; + } transform_type; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentTransform_FieldTransform) */ +} google_firestore_v1beta1_DocumentTransform_FieldTransform; + +typedef struct _google_firestore_v1beta1_ExistenceFilter { + int32_t target_id; + int32_t count; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ExistenceFilter) */ +} google_firestore_v1beta1_ExistenceFilter; + +typedef struct _google_firestore_v1beta1_Write { + google_firestore_v1beta1_Document update; + pb_callback_t delete_; + google_firestore_v1beta1_DocumentMask update_mask; + google_firestore_v1beta1_Precondition current_document; + google_firestore_v1beta1_DocumentTransform transform; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Write) */ +} google_firestore_v1beta1_Write; + +typedef struct _google_firestore_v1beta1_WriteResult { + google_protobuf_Timestamp update_time; + pb_callback_t transform_results; +/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteResult) */ +} google_firestore_v1beta1_WriteResult; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_firestore_v1beta1_Write_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_Precondition_init_default, google_firestore_v1beta1_DocumentTransform_init_default} +#define google_firestore_v1beta1_DocumentTransform_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_init_default {{{NULL}, NULL}, 0, {(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)0}} +#define google_firestore_v1beta1_WriteResult_init_default {google_protobuf_Timestamp_init_default, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentChange_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentDelete_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentRemove_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} +#define google_firestore_v1beta1_ExistenceFilter_init_default {0, 0} +#define google_firestore_v1beta1_Write_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_Precondition_init_zero, google_firestore_v1beta1_DocumentTransform_init_zero} +#define google_firestore_v1beta1_DocumentTransform_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_init_zero {{{NULL}, NULL}, 0, {(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)0}} +#define google_firestore_v1beta1_WriteResult_init_zero {google_protobuf_Timestamp_init_zero, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentChange_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentDelete_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero, {{NULL}, NULL}} +#define google_firestore_v1beta1_DocumentRemove_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} +#define google_firestore_v1beta1_ExistenceFilter_init_zero {0, 0} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_firestore_v1beta1_DocumentTransform_document_tag 1 +#define google_firestore_v1beta1_DocumentTransform_field_transforms_tag 2 +#define google_firestore_v1beta1_DocumentChange_document_tag 1 +#define google_firestore_v1beta1_DocumentChange_target_ids_tag 5 +#define google_firestore_v1beta1_DocumentChange_removed_target_ids_tag 6 +#define google_firestore_v1beta1_DocumentDelete_document_tag 1 +#define google_firestore_v1beta1_DocumentDelete_removed_target_ids_tag 6 +#define google_firestore_v1beta1_DocumentDelete_read_time_tag 4 +#define google_firestore_v1beta1_DocumentRemove_document_tag 1 +#define google_firestore_v1beta1_DocumentRemove_removed_target_ids_tag 2 +#define google_firestore_v1beta1_DocumentRemove_read_time_tag 4 +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_set_to_server_value_tag 2 +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_append_missing_elements_tag 6 +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_remove_all_from_array_tag 7 +#define google_firestore_v1beta1_DocumentTransform_FieldTransform_field_path_tag 1 +#define google_firestore_v1beta1_ExistenceFilter_target_id_tag 1 +#define google_firestore_v1beta1_ExistenceFilter_count_tag 2 +#define google_firestore_v1beta1_Write_update_tag 1 +#define google_firestore_v1beta1_Write_delete_tag 2 +#define google_firestore_v1beta1_Write_transform_tag 6 +#define google_firestore_v1beta1_Write_update_mask_tag 3 +#define google_firestore_v1beta1_Write_current_document_tag 4 +#define google_firestore_v1beta1_WriteResult_update_time_tag 1 +#define google_firestore_v1beta1_WriteResult_transform_results_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_firestore_v1beta1_Write_fields[6]; +extern const pb_field_t google_firestore_v1beta1_DocumentTransform_fields[3]; +extern const pb_field_t google_firestore_v1beta1_DocumentTransform_FieldTransform_fields[5]; +extern const pb_field_t google_firestore_v1beta1_WriteResult_fields[3]; +extern const pb_field_t google_firestore_v1beta1_DocumentChange_fields[4]; +extern const pb_field_t google_firestore_v1beta1_DocumentDelete_fields[4]; +extern const pb_field_t google_firestore_v1beta1_DocumentRemove_fields[4]; +extern const pb_field_t google_firestore_v1beta1_ExistenceFilter_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_firestore_v1beta1_Write_size depends on runtime parameters */ +/* google_firestore_v1beta1_DocumentTransform_size depends on runtime parameters */ +/* google_firestore_v1beta1_DocumentTransform_FieldTransform_size depends on runtime parameters */ +/* google_firestore_v1beta1_WriteResult_size depends on runtime parameters */ +/* google_firestore_v1beta1_DocumentChange_size depends on runtime parameters */ +/* google_firestore_v1beta1_DocumentDelete_size depends on runtime parameters */ +/* google_firestore_v1beta1_DocumentRemove_size depends on runtime parameters */ +#define google_firestore_v1beta1_ExistenceFilter_size 22 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define WRITE_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.c b/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.c index 26542e0..2527138 100644 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.c +++ b/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Thu Apr 12 07:27:15 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "write.pb.h" +#include "write.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.h b/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.h deleted file mode 100644 index 5a272b2..0000000 --- a/Firestore/Protos/nanopb/google/firestore/v1beta1/write.pb.h +++ /dev/null @@ -1,189 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Thu Apr 12 07:27:15 2018. */ - -#ifndef PB_GOOGLE_FIRESTORE_V1BETA1_WRITE_PB_H_INCLUDED -#define PB_GOOGLE_FIRESTORE_V1BETA1_WRITE_PB_H_INCLUDED -#include - -#include "google/api/annotations.pb.h" - -#include "google/firestore/v1beta1/common.pb.h" - -#include "google/firestore/v1beta1/document.pb.h" - -#include "google/protobuf/timestamp.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Enum definitions */ -typedef enum _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue { - google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_SERVER_VALUE_UNSPECIFIED = 0, - google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME = 1 -} google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue; -#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_MIN google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_SERVER_VALUE_UNSPECIFIED -#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_MAX google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME -#define _google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_ARRAYSIZE ((google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue_REQUEST_TIME+1)) - -/* Struct definitions */ -typedef struct _google_firestore_v1beta1_DocumentTransform { - pb_callback_t document; - pb_callback_t field_transforms; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentTransform) */ -} google_firestore_v1beta1_DocumentTransform; - -typedef struct _google_firestore_v1beta1_DocumentChange { - google_firestore_v1beta1_Document document; - pb_callback_t target_ids; - pb_callback_t removed_target_ids; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentChange) */ -} google_firestore_v1beta1_DocumentChange; - -typedef struct _google_firestore_v1beta1_DocumentDelete { - pb_callback_t document; - google_protobuf_Timestamp read_time; - pb_callback_t removed_target_ids; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentDelete) */ -} google_firestore_v1beta1_DocumentDelete; - -typedef struct _google_firestore_v1beta1_DocumentRemove { - pb_callback_t document; - pb_callback_t removed_target_ids; - google_protobuf_Timestamp read_time; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentRemove) */ -} google_firestore_v1beta1_DocumentRemove; - -typedef struct _google_firestore_v1beta1_DocumentTransform_FieldTransform { - pb_callback_t field_path; - pb_size_t which_transform_type; - union { - google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue set_to_server_value; - google_firestore_v1beta1_ArrayValue append_missing_elements; - google_firestore_v1beta1_ArrayValue remove_all_from_array; - } transform_type; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_DocumentTransform_FieldTransform) */ -} google_firestore_v1beta1_DocumentTransform_FieldTransform; - -typedef struct _google_firestore_v1beta1_ExistenceFilter { - int32_t target_id; - int32_t count; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_ExistenceFilter) */ -} google_firestore_v1beta1_ExistenceFilter; - -typedef struct _google_firestore_v1beta1_Write { - google_firestore_v1beta1_Document update; - pb_callback_t delete_; - google_firestore_v1beta1_DocumentMask update_mask; - google_firestore_v1beta1_Precondition current_document; - google_firestore_v1beta1_DocumentTransform transform; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_Write) */ -} google_firestore_v1beta1_Write; - -typedef struct _google_firestore_v1beta1_WriteResult { - google_protobuf_Timestamp update_time; - pb_callback_t transform_results; -/* @@protoc_insertion_point(struct:google_firestore_v1beta1_WriteResult) */ -} google_firestore_v1beta1_WriteResult; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_firestore_v1beta1_Write_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_default, google_firestore_v1beta1_Precondition_init_default, google_firestore_v1beta1_DocumentTransform_init_default} -#define google_firestore_v1beta1_DocumentTransform_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_init_default {{{NULL}, NULL}, 0, {(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)0}} -#define google_firestore_v1beta1_WriteResult_init_default {google_protobuf_Timestamp_init_default, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentChange_init_default {google_firestore_v1beta1_Document_init_default, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentDelete_init_default {{{NULL}, NULL}, google_protobuf_Timestamp_init_default, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentRemove_init_default {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_default} -#define google_firestore_v1beta1_ExistenceFilter_init_default {0, 0} -#define google_firestore_v1beta1_Write_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, google_firestore_v1beta1_DocumentMask_init_zero, google_firestore_v1beta1_Precondition_init_zero, google_firestore_v1beta1_DocumentTransform_init_zero} -#define google_firestore_v1beta1_DocumentTransform_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_init_zero {{{NULL}, NULL}, 0, {(google_firestore_v1beta1_DocumentTransform_FieldTransform_ServerValue)0}} -#define google_firestore_v1beta1_WriteResult_init_zero {google_protobuf_Timestamp_init_zero, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentChange_init_zero {google_firestore_v1beta1_Document_init_zero, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentDelete_init_zero {{{NULL}, NULL}, google_protobuf_Timestamp_init_zero, {{NULL}, NULL}} -#define google_firestore_v1beta1_DocumentRemove_init_zero {{{NULL}, NULL}, {{NULL}, NULL}, google_protobuf_Timestamp_init_zero} -#define google_firestore_v1beta1_ExistenceFilter_init_zero {0, 0} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_firestore_v1beta1_DocumentTransform_document_tag 1 -#define google_firestore_v1beta1_DocumentTransform_field_transforms_tag 2 -#define google_firestore_v1beta1_DocumentChange_document_tag 1 -#define google_firestore_v1beta1_DocumentChange_target_ids_tag 5 -#define google_firestore_v1beta1_DocumentChange_removed_target_ids_tag 6 -#define google_firestore_v1beta1_DocumentDelete_document_tag 1 -#define google_firestore_v1beta1_DocumentDelete_removed_target_ids_tag 6 -#define google_firestore_v1beta1_DocumentDelete_read_time_tag 4 -#define google_firestore_v1beta1_DocumentRemove_document_tag 1 -#define google_firestore_v1beta1_DocumentRemove_removed_target_ids_tag 2 -#define google_firestore_v1beta1_DocumentRemove_read_time_tag 4 -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_set_to_server_value_tag 2 -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_append_missing_elements_tag 6 -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_remove_all_from_array_tag 7 -#define google_firestore_v1beta1_DocumentTransform_FieldTransform_field_path_tag 1 -#define google_firestore_v1beta1_ExistenceFilter_target_id_tag 1 -#define google_firestore_v1beta1_ExistenceFilter_count_tag 2 -#define google_firestore_v1beta1_Write_update_tag 1 -#define google_firestore_v1beta1_Write_delete_tag 2 -#define google_firestore_v1beta1_Write_transform_tag 6 -#define google_firestore_v1beta1_Write_update_mask_tag 3 -#define google_firestore_v1beta1_Write_current_document_tag 4 -#define google_firestore_v1beta1_WriteResult_update_time_tag 1 -#define google_firestore_v1beta1_WriteResult_transform_results_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_firestore_v1beta1_Write_fields[6]; -extern const pb_field_t google_firestore_v1beta1_DocumentTransform_fields[3]; -extern const pb_field_t google_firestore_v1beta1_DocumentTransform_FieldTransform_fields[5]; -extern const pb_field_t google_firestore_v1beta1_WriteResult_fields[3]; -extern const pb_field_t google_firestore_v1beta1_DocumentChange_fields[4]; -extern const pb_field_t google_firestore_v1beta1_DocumentDelete_fields[4]; -extern const pb_field_t google_firestore_v1beta1_DocumentRemove_fields[4]; -extern const pb_field_t google_firestore_v1beta1_ExistenceFilter_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_firestore_v1beta1_Write_size depends on runtime parameters */ -/* google_firestore_v1beta1_DocumentTransform_size depends on runtime parameters */ -/* google_firestore_v1beta1_DocumentTransform_FieldTransform_size depends on runtime parameters */ -/* google_firestore_v1beta1_WriteResult_size depends on runtime parameters */ -/* google_firestore_v1beta1_DocumentChange_size depends on runtime parameters */ -/* google_firestore_v1beta1_DocumentDelete_size depends on runtime parameters */ -/* google_firestore_v1beta1_DocumentRemove_size depends on runtime parameters */ -#define google_firestore_v1beta1_ExistenceFilter_size 22 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define WRITE_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/any.nanopb.h b/Firestore/Protos/nanopb/google/protobuf/any.nanopb.h new file mode 100644 index 0000000..91a7001 --- /dev/null +++ b/Firestore/Protos/nanopb/google/protobuf/any.nanopb.h @@ -0,0 +1,69 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_PROTOBUF_ANY_PB_H_INCLUDED +#define PB_GOOGLE_PROTOBUF_ANY_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_protobuf_Any { + pb_callback_t type_url; + pb_callback_t value; +/* @@protoc_insertion_point(struct:google_protobuf_Any) */ +} google_protobuf_Any; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_protobuf_Any_init_default {{{NULL}, NULL}, {{NULL}, NULL}} +#define google_protobuf_Any_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_protobuf_Any_type_url_tag 1 +#define google_protobuf_Any_value_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_protobuf_Any_fields[3]; + +/* Maximum encoded size of messages (where known) */ +/* google_protobuf_Any_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define ANY_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/any.pb.c b/Firestore/Protos/nanopb/google/protobuf/any.pb.c index b28d0ba..34a415c 100644 --- a/Firestore/Protos/nanopb/google/protobuf/any.pb.c +++ b/Firestore/Protos/nanopb/google/protobuf/any.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "any.pb.h" +#include "any.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/protobuf/any.pb.h b/Firestore/Protos/nanopb/google/protobuf/any.pb.h deleted file mode 100644 index 10a722e..0000000 --- a/Firestore/Protos/nanopb/google/protobuf/any.pb.h +++ /dev/null @@ -1,69 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ - -#ifndef PB_GOOGLE_PROTOBUF_ANY_PB_H_INCLUDED -#define PB_GOOGLE_PROTOBUF_ANY_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_protobuf_Any { - pb_callback_t type_url; - pb_callback_t value; -/* @@protoc_insertion_point(struct:google_protobuf_Any) */ -} google_protobuf_Any; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_protobuf_Any_init_default {{{NULL}, NULL}, {{NULL}, NULL}} -#define google_protobuf_Any_init_zero {{{NULL}, NULL}, {{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_protobuf_Any_type_url_tag 1 -#define google_protobuf_Any_value_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_protobuf_Any_fields[3]; - -/* Maximum encoded size of messages (where known) */ -/* google_protobuf_Any_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define ANY_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/empty.nanopb.h b/Firestore/Protos/nanopb/google/protobuf/empty.nanopb.h new file mode 100644 index 0000000..3fb0eba --- /dev/null +++ b/Firestore/Protos/nanopb/google/protobuf/empty.nanopb.h @@ -0,0 +1,66 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_PROTOBUF_EMPTY_PB_H_INCLUDED +#define PB_GOOGLE_PROTOBUF_EMPTY_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_protobuf_Empty { + char dummy_field; +/* @@protoc_insertion_point(struct:google_protobuf_Empty) */ +} google_protobuf_Empty; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_protobuf_Empty_init_default {0} +#define google_protobuf_Empty_init_zero {0} + +/* Field tags (for use in manual encoding/decoding) */ + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_protobuf_Empty_fields[1]; + +/* Maximum encoded size of messages (where known) */ +#define google_protobuf_Empty_size 0 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define EMPTY_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/empty.pb.c b/Firestore/Protos/nanopb/google/protobuf/empty.pb.c index 050af9c..2326702 100644 --- a/Firestore/Protos/nanopb/google/protobuf/empty.pb.c +++ b/Firestore/Protos/nanopb/google/protobuf/empty.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "empty.pb.h" +#include "empty.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/protobuf/empty.pb.h b/Firestore/Protos/nanopb/google/protobuf/empty.pb.h deleted file mode 100644 index 466e1fd..0000000 --- a/Firestore/Protos/nanopb/google/protobuf/empty.pb.h +++ /dev/null @@ -1,66 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ - -#ifndef PB_GOOGLE_PROTOBUF_EMPTY_PB_H_INCLUDED -#define PB_GOOGLE_PROTOBUF_EMPTY_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_protobuf_Empty { - char dummy_field; -/* @@protoc_insertion_point(struct:google_protobuf_Empty) */ -} google_protobuf_Empty; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_protobuf_Empty_init_default {0} -#define google_protobuf_Empty_init_zero {0} - -/* Field tags (for use in manual encoding/decoding) */ - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_protobuf_Empty_fields[1]; - -/* Maximum encoded size of messages (where known) */ -#define google_protobuf_Empty_size 0 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define EMPTY_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/struct.nanopb.h b/Firestore/Protos/nanopb/google/protobuf/struct.nanopb.h new file mode 100644 index 0000000..fcccd9e --- /dev/null +++ b/Firestore/Protos/nanopb/google/protobuf/struct.nanopb.h @@ -0,0 +1,117 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_PROTOBUF_STRUCT_PB_H_INCLUDED +#define PB_GOOGLE_PROTOBUF_STRUCT_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Enum definitions */ +typedef enum _google_protobuf_NullValue { + google_protobuf_NullValue_NULL_VALUE = 0 +} google_protobuf_NullValue; +#define _google_protobuf_NullValue_MIN google_protobuf_NullValue_NULL_VALUE +#define _google_protobuf_NullValue_MAX google_protobuf_NullValue_NULL_VALUE +#define _google_protobuf_NullValue_ARRAYSIZE ((google_protobuf_NullValue)(google_protobuf_NullValue_NULL_VALUE+1)) + +/* Struct definitions */ +typedef struct _google_protobuf_ListValue { + pb_callback_t values; +/* @@protoc_insertion_point(struct:google_protobuf_ListValue) */ +} google_protobuf_ListValue; + +typedef struct _google_protobuf_Struct { + pb_callback_t fields; +/* @@protoc_insertion_point(struct:google_protobuf_Struct) */ +} google_protobuf_Struct; + +typedef struct _google_protobuf_Value { + google_protobuf_NullValue null_value; + double number_value; + pb_callback_t string_value; + bool bool_value; + google_protobuf_Struct struct_value; + google_protobuf_ListValue list_value; +/* @@protoc_insertion_point(struct:google_protobuf_Value) */ +} google_protobuf_Value; + +typedef struct _google_protobuf_Struct_FieldsEntry { + pb_callback_t key; + google_protobuf_Value value; +/* @@protoc_insertion_point(struct:google_protobuf_Struct_FieldsEntry) */ +} google_protobuf_Struct_FieldsEntry; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_protobuf_Struct_init_default {{{NULL}, NULL}} +#define google_protobuf_Struct_FieldsEntry_init_default {{{NULL}, NULL}, google_protobuf_Value_init_default} +#define google_protobuf_Value_init_default {(google_protobuf_NullValue)0, 0, {{NULL}, NULL}, 0, google_protobuf_Struct_init_default, google_protobuf_ListValue_init_default} +#define google_protobuf_ListValue_init_default {{{NULL}, NULL}} +#define google_protobuf_Struct_init_zero {{{NULL}, NULL}} +#define google_protobuf_Struct_FieldsEntry_init_zero {{{NULL}, NULL}, google_protobuf_Value_init_zero} +#define google_protobuf_Value_init_zero {(google_protobuf_NullValue)0, 0, {{NULL}, NULL}, 0, google_protobuf_Struct_init_zero, google_protobuf_ListValue_init_zero} +#define google_protobuf_ListValue_init_zero {{{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_protobuf_ListValue_values_tag 1 +#define google_protobuf_Struct_fields_tag 1 +#define google_protobuf_Value_null_value_tag 1 +#define google_protobuf_Value_number_value_tag 2 +#define google_protobuf_Value_string_value_tag 3 +#define google_protobuf_Value_bool_value_tag 4 +#define google_protobuf_Value_struct_value_tag 5 +#define google_protobuf_Value_list_value_tag 6 +#define google_protobuf_Struct_FieldsEntry_key_tag 1 +#define google_protobuf_Struct_FieldsEntry_value_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_protobuf_Struct_fields[2]; +extern const pb_field_t google_protobuf_Struct_FieldsEntry_fields[3]; +extern const pb_field_t google_protobuf_Value_fields[7]; +extern const pb_field_t google_protobuf_ListValue_fields[2]; + +/* Maximum encoded size of messages (where known) */ +/* google_protobuf_Struct_size depends on runtime parameters */ +/* google_protobuf_Struct_FieldsEntry_size depends on runtime parameters */ +/* google_protobuf_Value_size depends on runtime parameters */ +/* google_protobuf_ListValue_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define STRUCT_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/struct.pb.c b/Firestore/Protos/nanopb/google/protobuf/struct.pb.c index 2826aab..dc6eca4 100644 --- a/Firestore/Protos/nanopb/google/protobuf/struct.pb.c +++ b/Firestore/Protos/nanopb/google/protobuf/struct.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "struct.pb.h" +#include "struct.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/protobuf/struct.pb.h b/Firestore/Protos/nanopb/google/protobuf/struct.pb.h deleted file mode 100644 index b325b60..0000000 --- a/Firestore/Protos/nanopb/google/protobuf/struct.pb.h +++ /dev/null @@ -1,117 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_PROTOBUF_STRUCT_PB_H_INCLUDED -#define PB_GOOGLE_PROTOBUF_STRUCT_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Enum definitions */ -typedef enum _google_protobuf_NullValue { - google_protobuf_NullValue_NULL_VALUE = 0 -} google_protobuf_NullValue; -#define _google_protobuf_NullValue_MIN google_protobuf_NullValue_NULL_VALUE -#define _google_protobuf_NullValue_MAX google_protobuf_NullValue_NULL_VALUE -#define _google_protobuf_NullValue_ARRAYSIZE ((google_protobuf_NullValue)(google_protobuf_NullValue_NULL_VALUE+1)) - -/* Struct definitions */ -typedef struct _google_protobuf_ListValue { - pb_callback_t values; -/* @@protoc_insertion_point(struct:google_protobuf_ListValue) */ -} google_protobuf_ListValue; - -typedef struct _google_protobuf_Struct { - pb_callback_t fields; -/* @@protoc_insertion_point(struct:google_protobuf_Struct) */ -} google_protobuf_Struct; - -typedef struct _google_protobuf_Value { - google_protobuf_NullValue null_value; - double number_value; - pb_callback_t string_value; - bool bool_value; - google_protobuf_Struct struct_value; - google_protobuf_ListValue list_value; -/* @@protoc_insertion_point(struct:google_protobuf_Value) */ -} google_protobuf_Value; - -typedef struct _google_protobuf_Struct_FieldsEntry { - pb_callback_t key; - google_protobuf_Value value; -/* @@protoc_insertion_point(struct:google_protobuf_Struct_FieldsEntry) */ -} google_protobuf_Struct_FieldsEntry; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_protobuf_Struct_init_default {{{NULL}, NULL}} -#define google_protobuf_Struct_FieldsEntry_init_default {{{NULL}, NULL}, google_protobuf_Value_init_default} -#define google_protobuf_Value_init_default {(google_protobuf_NullValue)0, 0, {{NULL}, NULL}, 0, google_protobuf_Struct_init_default, google_protobuf_ListValue_init_default} -#define google_protobuf_ListValue_init_default {{{NULL}, NULL}} -#define google_protobuf_Struct_init_zero {{{NULL}, NULL}} -#define google_protobuf_Struct_FieldsEntry_init_zero {{{NULL}, NULL}, google_protobuf_Value_init_zero} -#define google_protobuf_Value_init_zero {(google_protobuf_NullValue)0, 0, {{NULL}, NULL}, 0, google_protobuf_Struct_init_zero, google_protobuf_ListValue_init_zero} -#define google_protobuf_ListValue_init_zero {{{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_protobuf_ListValue_values_tag 1 -#define google_protobuf_Struct_fields_tag 1 -#define google_protobuf_Value_null_value_tag 1 -#define google_protobuf_Value_number_value_tag 2 -#define google_protobuf_Value_string_value_tag 3 -#define google_protobuf_Value_bool_value_tag 4 -#define google_protobuf_Value_struct_value_tag 5 -#define google_protobuf_Value_list_value_tag 6 -#define google_protobuf_Struct_FieldsEntry_key_tag 1 -#define google_protobuf_Struct_FieldsEntry_value_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_protobuf_Struct_fields[2]; -extern const pb_field_t google_protobuf_Struct_FieldsEntry_fields[3]; -extern const pb_field_t google_protobuf_Value_fields[7]; -extern const pb_field_t google_protobuf_ListValue_fields[2]; - -/* Maximum encoded size of messages (where known) */ -/* google_protobuf_Struct_size depends on runtime parameters */ -/* google_protobuf_Struct_FieldsEntry_size depends on runtime parameters */ -/* google_protobuf_Value_size depends on runtime parameters */ -/* google_protobuf_ListValue_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define STRUCT_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/timestamp.nanopb.h b/Firestore/Protos/nanopb/google/protobuf/timestamp.nanopb.h new file mode 100644 index 0000000..30fe497 --- /dev/null +++ b/Firestore/Protos/nanopb/google/protobuf/timestamp.nanopb.h @@ -0,0 +1,69 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_PROTOBUF_TIMESTAMP_PB_H_INCLUDED +#define PB_GOOGLE_PROTOBUF_TIMESTAMP_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_protobuf_Timestamp { + int64_t seconds; + int32_t nanos; +/* @@protoc_insertion_point(struct:google_protobuf_Timestamp) */ +} google_protobuf_Timestamp; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_protobuf_Timestamp_init_default {0, 0} +#define google_protobuf_Timestamp_init_zero {0, 0} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_protobuf_Timestamp_seconds_tag 1 +#define google_protobuf_Timestamp_nanos_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_protobuf_Timestamp_fields[3]; + +/* Maximum encoded size of messages (where known) */ +#define google_protobuf_Timestamp_size 22 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define TIMESTAMP_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.c b/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.c index 4f03c19..4d91990 100644 --- a/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.c +++ b/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "timestamp.pb.h" +#include "timestamp.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.h b/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.h deleted file mode 100644 index d7be977..0000000 --- a/Firestore/Protos/nanopb/google/protobuf/timestamp.pb.h +++ /dev/null @@ -1,69 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_PROTOBUF_TIMESTAMP_PB_H_INCLUDED -#define PB_GOOGLE_PROTOBUF_TIMESTAMP_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_protobuf_Timestamp { - int64_t seconds; - int32_t nanos; -/* @@protoc_insertion_point(struct:google_protobuf_Timestamp) */ -} google_protobuf_Timestamp; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_protobuf_Timestamp_init_default {0, 0} -#define google_protobuf_Timestamp_init_zero {0, 0} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_protobuf_Timestamp_seconds_tag 1 -#define google_protobuf_Timestamp_nanos_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_protobuf_Timestamp_fields[3]; - -/* Maximum encoded size of messages (where known) */ -#define google_protobuf_Timestamp_size 22 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define TIMESTAMP_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/wrappers.nanopb.h b/Firestore/Protos/nanopb/google/protobuf/wrappers.nanopb.h new file mode 100644 index 0000000..7e36429 --- /dev/null +++ b/Firestore/Protos/nanopb/google/protobuf/wrappers.nanopb.h @@ -0,0 +1,147 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_PROTOBUF_WRAPPERS_PB_H_INCLUDED +#define PB_GOOGLE_PROTOBUF_WRAPPERS_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_protobuf_BytesValue { + pb_callback_t value; +/* @@protoc_insertion_point(struct:google_protobuf_BytesValue) */ +} google_protobuf_BytesValue; + +typedef struct _google_protobuf_StringValue { + pb_callback_t value; +/* @@protoc_insertion_point(struct:google_protobuf_StringValue) */ +} google_protobuf_StringValue; + +typedef struct _google_protobuf_BoolValue { + bool value; +/* @@protoc_insertion_point(struct:google_protobuf_BoolValue) */ +} google_protobuf_BoolValue; + +typedef struct _google_protobuf_DoubleValue { + double value; +/* @@protoc_insertion_point(struct:google_protobuf_DoubleValue) */ +} google_protobuf_DoubleValue; + +typedef struct _google_protobuf_FloatValue { + float value; +/* @@protoc_insertion_point(struct:google_protobuf_FloatValue) */ +} google_protobuf_FloatValue; + +typedef struct _google_protobuf_Int32Value { + int32_t value; +/* @@protoc_insertion_point(struct:google_protobuf_Int32Value) */ +} google_protobuf_Int32Value; + +typedef struct _google_protobuf_Int64Value { + int64_t value; +/* @@protoc_insertion_point(struct:google_protobuf_Int64Value) */ +} google_protobuf_Int64Value; + +typedef struct _google_protobuf_UInt32Value { + uint32_t value; +/* @@protoc_insertion_point(struct:google_protobuf_UInt32Value) */ +} google_protobuf_UInt32Value; + +typedef struct _google_protobuf_UInt64Value { + uint64_t value; +/* @@protoc_insertion_point(struct:google_protobuf_UInt64Value) */ +} google_protobuf_UInt64Value; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_protobuf_DoubleValue_init_default {0} +#define google_protobuf_FloatValue_init_default {0} +#define google_protobuf_Int64Value_init_default {0} +#define google_protobuf_UInt64Value_init_default {0} +#define google_protobuf_Int32Value_init_default {0} +#define google_protobuf_UInt32Value_init_default {0} +#define google_protobuf_BoolValue_init_default {0} +#define google_protobuf_StringValue_init_default {{{NULL}, NULL}} +#define google_protobuf_BytesValue_init_default {{{NULL}, NULL}} +#define google_protobuf_DoubleValue_init_zero {0} +#define google_protobuf_FloatValue_init_zero {0} +#define google_protobuf_Int64Value_init_zero {0} +#define google_protobuf_UInt64Value_init_zero {0} +#define google_protobuf_Int32Value_init_zero {0} +#define google_protobuf_UInt32Value_init_zero {0} +#define google_protobuf_BoolValue_init_zero {0} +#define google_protobuf_StringValue_init_zero {{{NULL}, NULL}} +#define google_protobuf_BytesValue_init_zero {{{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_protobuf_BytesValue_value_tag 1 +#define google_protobuf_StringValue_value_tag 1 +#define google_protobuf_BoolValue_value_tag 1 +#define google_protobuf_DoubleValue_value_tag 1 +#define google_protobuf_FloatValue_value_tag 1 +#define google_protobuf_Int32Value_value_tag 1 +#define google_protobuf_Int64Value_value_tag 1 +#define google_protobuf_UInt32Value_value_tag 1 +#define google_protobuf_UInt64Value_value_tag 1 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_protobuf_DoubleValue_fields[2]; +extern const pb_field_t google_protobuf_FloatValue_fields[2]; +extern const pb_field_t google_protobuf_Int64Value_fields[2]; +extern const pb_field_t google_protobuf_UInt64Value_fields[2]; +extern const pb_field_t google_protobuf_Int32Value_fields[2]; +extern const pb_field_t google_protobuf_UInt32Value_fields[2]; +extern const pb_field_t google_protobuf_BoolValue_fields[2]; +extern const pb_field_t google_protobuf_StringValue_fields[2]; +extern const pb_field_t google_protobuf_BytesValue_fields[2]; + +/* Maximum encoded size of messages (where known) */ +#define google_protobuf_DoubleValue_size 9 +#define google_protobuf_FloatValue_size 5 +#define google_protobuf_Int64Value_size 11 +#define google_protobuf_UInt64Value_size 11 +#define google_protobuf_Int32Value_size 11 +#define google_protobuf_UInt32Value_size 6 +#define google_protobuf_BoolValue_size 2 +/* google_protobuf_StringValue_size depends on runtime parameters */ +/* google_protobuf_BytesValue_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define WRAPPERS_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.c b/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.c index 41ab3c6..f2c7bd9 100644 --- a/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.c +++ b/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "wrappers.pb.h" +#include "wrappers.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.h b/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.h deleted file mode 100644 index 0e98785..0000000 --- a/Firestore/Protos/nanopb/google/protobuf/wrappers.pb.h +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Mon Feb 12 11:03:06 2018. */ - -#ifndef PB_GOOGLE_PROTOBUF_WRAPPERS_PB_H_INCLUDED -#define PB_GOOGLE_PROTOBUF_WRAPPERS_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_protobuf_BytesValue { - pb_callback_t value; -/* @@protoc_insertion_point(struct:google_protobuf_BytesValue) */ -} google_protobuf_BytesValue; - -typedef struct _google_protobuf_StringValue { - pb_callback_t value; -/* @@protoc_insertion_point(struct:google_protobuf_StringValue) */ -} google_protobuf_StringValue; - -typedef struct _google_protobuf_BoolValue { - bool value; -/* @@protoc_insertion_point(struct:google_protobuf_BoolValue) */ -} google_protobuf_BoolValue; - -typedef struct _google_protobuf_DoubleValue { - double value; -/* @@protoc_insertion_point(struct:google_protobuf_DoubleValue) */ -} google_protobuf_DoubleValue; - -typedef struct _google_protobuf_FloatValue { - float value; -/* @@protoc_insertion_point(struct:google_protobuf_FloatValue) */ -} google_protobuf_FloatValue; - -typedef struct _google_protobuf_Int32Value { - int32_t value; -/* @@protoc_insertion_point(struct:google_protobuf_Int32Value) */ -} google_protobuf_Int32Value; - -typedef struct _google_protobuf_Int64Value { - int64_t value; -/* @@protoc_insertion_point(struct:google_protobuf_Int64Value) */ -} google_protobuf_Int64Value; - -typedef struct _google_protobuf_UInt32Value { - uint32_t value; -/* @@protoc_insertion_point(struct:google_protobuf_UInt32Value) */ -} google_protobuf_UInt32Value; - -typedef struct _google_protobuf_UInt64Value { - uint64_t value; -/* @@protoc_insertion_point(struct:google_protobuf_UInt64Value) */ -} google_protobuf_UInt64Value; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_protobuf_DoubleValue_init_default {0} -#define google_protobuf_FloatValue_init_default {0} -#define google_protobuf_Int64Value_init_default {0} -#define google_protobuf_UInt64Value_init_default {0} -#define google_protobuf_Int32Value_init_default {0} -#define google_protobuf_UInt32Value_init_default {0} -#define google_protobuf_BoolValue_init_default {0} -#define google_protobuf_StringValue_init_default {{{NULL}, NULL}} -#define google_protobuf_BytesValue_init_default {{{NULL}, NULL}} -#define google_protobuf_DoubleValue_init_zero {0} -#define google_protobuf_FloatValue_init_zero {0} -#define google_protobuf_Int64Value_init_zero {0} -#define google_protobuf_UInt64Value_init_zero {0} -#define google_protobuf_Int32Value_init_zero {0} -#define google_protobuf_UInt32Value_init_zero {0} -#define google_protobuf_BoolValue_init_zero {0} -#define google_protobuf_StringValue_init_zero {{{NULL}, NULL}} -#define google_protobuf_BytesValue_init_zero {{{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_protobuf_BytesValue_value_tag 1 -#define google_protobuf_StringValue_value_tag 1 -#define google_protobuf_BoolValue_value_tag 1 -#define google_protobuf_DoubleValue_value_tag 1 -#define google_protobuf_FloatValue_value_tag 1 -#define google_protobuf_Int32Value_value_tag 1 -#define google_protobuf_Int64Value_value_tag 1 -#define google_protobuf_UInt32Value_value_tag 1 -#define google_protobuf_UInt64Value_value_tag 1 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_protobuf_DoubleValue_fields[2]; -extern const pb_field_t google_protobuf_FloatValue_fields[2]; -extern const pb_field_t google_protobuf_Int64Value_fields[2]; -extern const pb_field_t google_protobuf_UInt64Value_fields[2]; -extern const pb_field_t google_protobuf_Int32Value_fields[2]; -extern const pb_field_t google_protobuf_UInt32Value_fields[2]; -extern const pb_field_t google_protobuf_BoolValue_fields[2]; -extern const pb_field_t google_protobuf_StringValue_fields[2]; -extern const pb_field_t google_protobuf_BytesValue_fields[2]; - -/* Maximum encoded size of messages (where known) */ -#define google_protobuf_DoubleValue_size 9 -#define google_protobuf_FloatValue_size 5 -#define google_protobuf_Int64Value_size 11 -#define google_protobuf_UInt64Value_size 11 -#define google_protobuf_Int32Value_size 11 -#define google_protobuf_UInt32Value_size 6 -#define google_protobuf_BoolValue_size 2 -/* google_protobuf_StringValue_size depends on runtime parameters */ -/* google_protobuf_BytesValue_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define WRAPPERS_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/rpc/status.nanopb.h b/Firestore/Protos/nanopb/google/rpc/status.nanopb.h new file mode 100644 index 0000000..d26c31a --- /dev/null +++ b/Firestore/Protos/nanopb/google/rpc/status.nanopb.h @@ -0,0 +1,73 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_RPC_STATUS_PB_H_INCLUDED +#define PB_GOOGLE_RPC_STATUS_PB_H_INCLUDED +#include + +#include "google/protobuf/any.nanopb.h" + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_rpc_Status { + int32_t code; + pb_callback_t message; + pb_callback_t details; +/* @@protoc_insertion_point(struct:google_rpc_Status) */ +} google_rpc_Status; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_rpc_Status_init_default {0, {{NULL}, NULL}, {{NULL}, NULL}} +#define google_rpc_Status_init_zero {0, {{NULL}, NULL}, {{NULL}, NULL}} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_rpc_Status_code_tag 1 +#define google_rpc_Status_message_tag 2 +#define google_rpc_Status_details_tag 3 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_rpc_Status_fields[4]; + +/* Maximum encoded size of messages (where known) */ +/* google_rpc_Status_size depends on runtime parameters */ + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define STATUS_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/rpc/status.pb.c b/Firestore/Protos/nanopb/google/rpc/status.pb.c index dbdccce..7a96204 100644 --- a/Firestore/Protos/nanopb/google/rpc/status.pb.c +++ b/Firestore/Protos/nanopb/google/rpc/status.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "status.pb.h" +#include "status.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/rpc/status.pb.h b/Firestore/Protos/nanopb/google/rpc/status.pb.h deleted file mode 100644 index afcbab9..0000000 --- a/Firestore/Protos/nanopb/google/rpc/status.pb.h +++ /dev/null @@ -1,73 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_RPC_STATUS_PB_H_INCLUDED -#define PB_GOOGLE_RPC_STATUS_PB_H_INCLUDED -#include - -#include "google/protobuf/any.pb.h" - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_rpc_Status { - int32_t code; - pb_callback_t message; - pb_callback_t details; -/* @@protoc_insertion_point(struct:google_rpc_Status) */ -} google_rpc_Status; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_rpc_Status_init_default {0, {{NULL}, NULL}, {{NULL}, NULL}} -#define google_rpc_Status_init_zero {0, {{NULL}, NULL}, {{NULL}, NULL}} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_rpc_Status_code_tag 1 -#define google_rpc_Status_message_tag 2 -#define google_rpc_Status_details_tag 3 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_rpc_Status_fields[4]; - -/* Maximum encoded size of messages (where known) */ -/* google_rpc_Status_size depends on runtime parameters */ - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define STATUS_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/Protos/nanopb/google/type/latlng.nanopb.h b/Firestore/Protos/nanopb/google/type/latlng.nanopb.h new file mode 100644 index 0000000..a3b8365 --- /dev/null +++ b/Firestore/Protos/nanopb/google/type/latlng.nanopb.h @@ -0,0 +1,69 @@ +/* + * 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. + */ + +/* Automatically generated nanopb header */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ + +#ifndef PB_GOOGLE_TYPE_LATLNG_PB_H_INCLUDED +#define PB_GOOGLE_TYPE_LATLNG_PB_H_INCLUDED +#include + +/* @@protoc_insertion_point(includes) */ +#if PB_PROTO_HEADER_VERSION != 30 +#error Regenerate this file with the current version of nanopb generator. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/* Struct definitions */ +typedef struct _google_type_LatLng { + double latitude; + double longitude; +/* @@protoc_insertion_point(struct:google_type_LatLng) */ +} google_type_LatLng; + +/* Default values for struct fields */ + +/* Initializer values for message structs */ +#define google_type_LatLng_init_default {0, 0} +#define google_type_LatLng_init_zero {0, 0} + +/* Field tags (for use in manual encoding/decoding) */ +#define google_type_LatLng_latitude_tag 1 +#define google_type_LatLng_longitude_tag 2 + +/* Struct field encoding specification for nanopb */ +extern const pb_field_t google_type_LatLng_fields[3]; + +/* Maximum encoded size of messages (where known) */ +#define google_type_LatLng_size 18 + +/* Message IDs (where set with "msgid" option) */ +#ifdef PB_MSGID + +#define LATLNG_MESSAGES \ + + +#endif + +#ifdef __cplusplus +} /* extern "C" */ +#endif +/* @@protoc_insertion_point(eof) */ + +#endif diff --git a/Firestore/Protos/nanopb/google/type/latlng.pb.c b/Firestore/Protos/nanopb/google/type/latlng.pb.c index b5f6424..a2a2de3 100644 --- a/Firestore/Protos/nanopb/google/type/latlng.pb.c +++ b/Firestore/Protos/nanopb/google/type/latlng.pb.c @@ -15,9 +15,9 @@ */ /* Automatically generated nanopb constant definitions */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ +/* Generated by nanopb-0.3.8 at Fri Jun 1 18:36:44 2018. */ -#include "latlng.pb.h" +#include "latlng.nanopb.h" /* @@protoc_insertion_point(includes) */ #if PB_PROTO_HEADER_VERSION != 30 diff --git a/Firestore/Protos/nanopb/google/type/latlng.pb.h b/Firestore/Protos/nanopb/google/type/latlng.pb.h deleted file mode 100644 index fa5703b..0000000 --- a/Firestore/Protos/nanopb/google/type/latlng.pb.h +++ /dev/null @@ -1,69 +0,0 @@ -/* - * 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. - */ - -/* Automatically generated nanopb header */ -/* Generated by nanopb-0.3.8 at Fri Feb 2 17:48:02 2018. */ - -#ifndef PB_GOOGLE_TYPE_LATLNG_PB_H_INCLUDED -#define PB_GOOGLE_TYPE_LATLNG_PB_H_INCLUDED -#include - -/* @@protoc_insertion_point(includes) */ -#if PB_PROTO_HEADER_VERSION != 30 -#error Regenerate this file with the current version of nanopb generator. -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/* Struct definitions */ -typedef struct _google_type_LatLng { - double latitude; - double longitude; -/* @@protoc_insertion_point(struct:google_type_LatLng) */ -} google_type_LatLng; - -/* Default values for struct fields */ - -/* Initializer values for message structs */ -#define google_type_LatLng_init_default {0, 0} -#define google_type_LatLng_init_zero {0, 0} - -/* Field tags (for use in manual encoding/decoding) */ -#define google_type_LatLng_latitude_tag 1 -#define google_type_LatLng_longitude_tag 2 - -/* Struct field encoding specification for nanopb */ -extern const pb_field_t google_type_LatLng_fields[3]; - -/* Maximum encoded size of messages (where known) */ -#define google_type_LatLng_size 18 - -/* Message IDs (where set with "msgid" option) */ -#ifdef PB_MSGID - -#define LATLNG_MESSAGES \ - - -#endif - -#ifdef __cplusplus -} /* extern "C" */ -#endif -/* @@protoc_insertion_point(eof) */ - -#endif diff --git a/Firestore/core/src/firebase/firestore/nanopb/reader.cc b/Firestore/core/src/firebase/firestore/nanopb/reader.cc index 7a12900..ec4282d 100644 --- a/Firestore/core/src/firebase/firestore/nanopb/reader.cc +++ b/Firestore/core/src/firebase/firestore/nanopb/reader.cc @@ -16,7 +16,7 @@ #include "Firestore/core/src/firebase/firestore/nanopb/reader.h" -#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h" +#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h" namespace firebase { namespace firestore { diff --git a/Firestore/core/src/firebase/firestore/nanopb/writer.cc b/Firestore/core/src/firebase/firestore/nanopb/writer.cc index c3ffaac..7f32d4e 100644 --- a/Firestore/core/src/firebase/firestore/nanopb/writer.cc +++ b/Firestore/core/src/firebase/firestore/nanopb/writer.cc @@ -16,7 +16,7 @@ #include "Firestore/core/src/firebase/firestore/nanopb/writer.h" -#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h" +#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h" namespace firebase { namespace firestore { diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index 03fbb1a..0839efc 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -24,8 +24,8 @@ #include #include -#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.pb.h" -#include "Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.pb.h" +#include "Firestore/Protos/nanopb/google/firestore/v1beta1/document.nanopb.h" +#include "Firestore/Protos/nanopb/google/firestore/v1beta1/firestore.nanopb.h" #include "Firestore/core/include/firebase/firestore/firestore_errors.h" #include "Firestore/core/include/firebase/firestore/timestamp.h" #include "Firestore/core/src/firebase/firestore/model/document.h" diff --git a/scripts/style.sh b/scripts/style.sh index d8825f2..8eff1e8 100755 --- a/scripts/style.sh +++ b/scripts/style.sh @@ -122,6 +122,7 @@ s%^./%% # Checked-in generated code \%\.pb(objc|rpc)\.% d \%\.pb\.% d +\%\.nanopb\.% d # Format C-ish sources only \%\.(h|m|mm|cc|swift)$% p -- cgit v1.2.3 From 26b8ac9ee43bb67b08e4bc62af98ac6bda2f121c Mon Sep 17 00:00:00 2001 From: rsgowman Date: Mon, 4 Jun 2018 15:31:10 -0400 Subject: Skip unknown fields while decoding FieldValue proto objects. (#1354) --- .../core/src/firebase/firestore/nanopb/reader.cc | 8 +++ .../core/src/firebase/firestore/nanopb/reader.h | 9 +++ .../src/firebase/firestore/remote/serializer.cc | 40 +++++++------ .../firebase/firestore/remote/serializer_test.cc | 65 ++++++++++++++++++---- 4 files changed, 95 insertions(+), 27 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/nanopb/reader.cc b/Firestore/core/src/firebase/firestore/nanopb/reader.cc index ec4282d..69e3d83 100644 --- a/Firestore/core/src/firebase/firestore/nanopb/reader.cc +++ b/Firestore/core/src/firebase/firestore/nanopb/reader.cc @@ -136,6 +136,14 @@ std::string Reader::ReadString() { return result; } +void Reader::SkipField(const Tag& tag) { + if (!status_.ok()) return; + + if (!pb_skip_field(&stream_, tag.wire_type)) { + status_ = Status(FirestoreErrorCode::DataLoss, PB_GET_ERROR(&stream_)); + } +} + } // namespace nanopb } // namespace firestore } // namespace firebase diff --git a/Firestore/core/src/firebase/firestore/nanopb/reader.h b/Firestore/core/src/firebase/firestore/nanopb/reader.h index 930211a..2c16ec4 100644 --- a/Firestore/core/src/firebase/firestore/nanopb/reader.h +++ b/Firestore/core/src/firebase/firestore/nanopb/reader.h @@ -89,6 +89,15 @@ class Reader { template T ReadNestedMessage(const std::function& read_message_fn); + /** + * Discards the bytes associated with the given tag. + * + * @param tag The tag associated with the field that is otherwise about to be + * read. This method uses the tag to determine how many bytes should be + * discarded. + */ + void SkipField(const Tag& tag); + size_t bytes_left() const { return stream_.bytes_left; } diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index 0839efc..eee56f8 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -204,20 +204,20 @@ FieldValue DecodeFieldValueImpl(Reader* reader) { } break; - default: - // We could get here for one of two reasons; either because the input - // bytes are corrupt, or because we're attempting to parse a tag that we - // haven't implemented yet. Long term, the latter reason should become - // less likely (especially in production), so we'll assume former. - - // TODO(rsgowman): While still in development, we'll contradict the - // above and assume the latter. Remove the following assertion when - // we're confident that we're handling all the tags in the protos. + case google_firestore_v1beta1_Value_double_value_tag: + case google_firestore_v1beta1_Value_bytes_value_tag: + case google_firestore_v1beta1_Value_reference_value_tag: + case google_firestore_v1beta1_Value_geo_point_value_tag: + case google_firestore_v1beta1_Value_array_value_tag: + // TODO(b/74243929): Implement remaining types. HARD_FAIL("Unhandled message field number (tag): %i.", tag.field_number); - reader->set_status(Status( - FirestoreErrorCode::DataLoss, - "Input proto bytes cannot be parsed (invalid field number (tag))")); + + default: + // Unknown tag. According to the proto spec, we need to ignore these. No + // action required here, though we'll need to skip the relevant bytes + // below. + break; } if (!reader->status().ok()) return FieldValue::NullValue(); @@ -247,12 +247,18 @@ FieldValue DecodeFieldValueImpl(Reader* reader) { reader->ReadNestedMessage(DecodeMapValue)); break; + case google_firestore_v1beta1_Value_double_value_tag: + case google_firestore_v1beta1_Value_bytes_value_tag: + case google_firestore_v1beta1_Value_reference_value_tag: + case google_firestore_v1beta1_Value_geo_point_value_tag: + case google_firestore_v1beta1_Value_array_value_tag: + // TODO(b/74243929): Implement remaining types. + HARD_FAIL("Unhandled message field number (tag): %i.", + tag.field_number); + default: - // This indicates an internal error as we've already ensured that this - // is a valid field_number. - HARD_FAIL( - "Somehow got an unexpected field number (tag) after verifying that " - "the field number was expected."); + // Unknown tag. According to the proto spec, we need to ignore these. + reader->SkipField(tag); } } diff --git a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc index 96ffa9e..7dcdf6e 100644 --- a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc +++ b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc @@ -605,7 +605,12 @@ TEST_F(SerializerTest, BadTimestampValue_TooSmall) { Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); } -TEST_F(SerializerTest, BadTag) { +TEST_F(SerializerTest, BadFieldValueTagAndNoOtherTagPresent) { + // A bad tag should be ignored. But if there are *no* valid tags, then we + // don't know the type of the FieldValue. Although it might be reasonable to + // assume some sort of default type in this situation, we've decided to fail + // the deserialization process in this case instead. + std::vector bytes = EncodeFieldValue(&serializer, FieldValue::NullValue()); @@ -615,15 +620,55 @@ TEST_F(SerializerTest, BadTag) { // Specifically 31. 0xf8 represents field number 31 encoded as a varint. Mutate(&bytes[0], /*expected_initial_value=*/0x58, /*new_value=*/0xf8); - // TODO(rsgowman): The behaviour is *temporarily* slightly different during - // development; this will cause a failed assertion rather than a failed - // status. Remove this EXPECT_ANY_THROW statement (and reenable the - // following commented out statement) once the corresponding assert has been - // removed from serializer.cc. - EXPECT_ANY_THROW(ExpectFailedStatusDuringFieldValueDecode( - Status(FirestoreErrorCode::DataLoss, "ignored"), bytes)); - // ExpectFailedStatusDuringFieldValueDecode( - // Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); + ExpectFailedStatusDuringFieldValueDecode( + Status(FirestoreErrorCode::DataLoss, "ignored"), bytes); +} + +TEST_F(SerializerTest, BadFieldValueTagWithOtherValidTagsPresent) { + // A bad tag should be ignored, in which case, we should successfully + // deserialize the rest of the bytes as if it wasn't there. To craft these + // bytes, we'll use the same technique as + // EncodesFieldValuesWithRepeatedEntries (so go read the comments there + // first). + + // Copy of the real one (from the nanopb generated document.pb.h), but with + // only boolean_value and integer_value. + struct google_firestore_v1beta1_Value_Fake { + bool boolean_value; + int64_t integer_value; + }; + + // Copy of the real one (from the nanopb generated document.pb.c), but with + // only boolean_value and integer_value. Also modified such that integer_value + // now has an invalid tag (instead of 2). + const int invalid_tag = 31; + const pb_field_t google_firestore_v1beta1_Value_fields_Fake[2] = { + PB_FIELD(1, BOOL, SINGULAR, STATIC, FIRST, + google_firestore_v1beta1_Value_Fake, boolean_value, + boolean_value, 0), + PB_FIELD(invalid_tag, INT64, SINGULAR, STATIC, OTHER, + google_firestore_v1beta1_Value_Fake, integer_value, + boolean_value, 0), + }; + + // Craft the bytes. boolean_value has a smaller tag, so it'll get encoded + // first, normally implying integer_value should "win". Except that + // integer_value isn't a valid tag, so it should be ignored here. + google_firestore_v1beta1_Value_Fake crafty_value{false, int64_t{42}}; + std::vector bytes(128); + pb_ostream_t stream = pb_ostream_from_buffer(bytes.data(), bytes.size()); + pb_encode(&stream, google_firestore_v1beta1_Value_fields_Fake, &crafty_value); + bytes.resize(stream.bytes_written); + + // Decode the bytes into the model + StatusOr actual_model_status = serializer.DecodeFieldValue(bytes); + EXPECT_OK(actual_model_status); + FieldValue actual_model = actual_model_status.ValueOrDie(); + + // Ensure the decoded model is as expected. + FieldValue expected_model = FieldValue::BooleanValue(false); + EXPECT_EQ(FieldValue::Type::Boolean, actual_model.type()); + EXPECT_EQ(expected_model, actual_model); } TEST_F(SerializerTest, TagVarintWiretypeStringMismatch) { -- cgit v1.2.3 From dc4f87527f61f0d20a5fc175ca19ad3f367133c1 Mon Sep 17 00:00:00 2001 From: Gil Date: Mon, 4 Jun 2018 13:06:43 -0700 Subject: Build cleanup (#1375) * Remove extraneous firebase_firestore_util_async_queue target * Remove unimplemented declaration in string_util.h --- Firestore/core/src/firebase/firestore/util/CMakeLists.txt | 15 ++++----------- Firestore/core/src/firebase/firestore/util/string_util.h | 5 ----- .../core/test/firebase/firestore/util/CMakeLists.txt | 4 ++-- 3 files changed, 6 insertions(+), 18 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/util/CMakeLists.txt b/Firestore/core/src/firebase/firestore/util/CMakeLists.txt index ed3a301..30589a0 100644 --- a/Firestore/core/src/firebase/firestore/util/CMakeLists.txt +++ b/Firestore/core/src/firebase/firestore/util/CMakeLists.txt @@ -29,6 +29,7 @@ cc_library( absl_strings ) + ## assert and log cc_library( @@ -158,16 +159,6 @@ else() endif() -cc_library( - firebase_firestore_util_async_queue - SOURCES - async_queue.cc - async_queue.h - DEPENDS - ${FIREBASE_FIRESTORE_UTIL_EXECUTOR} - ${FIREBASE_FIRESTORE_UTIL_LOG} - EXCLUDE_FROM_ALL -) ## main library @@ -179,6 +170,8 @@ configure_file( cc_library( firebase_firestore_util SOURCES + async_queue.cc + async_queue.h autoid.cc autoid.h bits.cc @@ -204,7 +197,7 @@ cc_library( DEPENDS absl_base firebase_firestore_util_base - firebase_firestore_util_async_queue + ${FIREBASE_FIRESTORE_UTIL_EXECUTOR} ${FIREBASE_FIRESTORE_UTIL_LOG} ${FIREBASE_FIRESTORE_UTIL_RANDOM} ) diff --git a/Firestore/core/src/firebase/firestore/util/string_util.h b/Firestore/core/src/firebase/firestore/util/string_util.h index 96ba0b0..86acc56 100644 --- a/Firestore/core/src/firebase/firestore/util/string_util.h +++ b/Firestore/core/src/firebase/firestore/util/string_util.h @@ -65,11 +65,6 @@ std::string PrefixSuccessor(absl::string_view prefix); */ std::string ImmediateSuccessor(absl::string_view s); -/** - * Returns true if the given value starts with the given prefix. - */ -bool StartsWith(const std::string &value, const std::string &prefix); - } // namespace util } // namespace firestore } // namespace firebase diff --git a/Firestore/core/test/firebase/firestore/util/CMakeLists.txt b/Firestore/core/test/firebase/firestore/util/CMakeLists.txt index c07a4ea..44a3b61 100644 --- a/Firestore/core/test/firebase/firestore/util/CMakeLists.txt +++ b/Firestore/core/test/firebase/firestore/util/CMakeLists.txt @@ -98,7 +98,7 @@ cc_test( async_tests_util.h DEPENDS firebase_firestore_util_executor_std - firebase_firestore_util_async_queue + firebase_firestore_util ) if(HAVE_LIBDISPATCH) @@ -111,7 +111,7 @@ if(HAVE_LIBDISPATCH) async_tests_util.h DEPENDS firebase_firestore_util_executor_libdispatch - firebase_firestore_util_async_queue + firebase_firestore_util ) endif() -- cgit v1.2.3 From 9307f4893008f7d6cf9473e906d4c896546c5c8c Mon Sep 17 00:00:00 2001 From: rsgowman Date: Tue, 5 Jun 2018 12:24:14 -0400 Subject: Skip unknown fields while decoding BatchGetDocumentsResponse proto objects (#1377) --- .../src/firebase/firestore/remote/serializer.cc | 14 +++-- .../firebase/firestore/remote/serializer_test.cc | 62 ++++++++++++++++++++++ 2 files changed, 68 insertions(+), 8 deletions(-) (limited to 'Firestore/core') diff --git a/Firestore/core/src/firebase/firestore/remote/serializer.cc b/Firestore/core/src/firebase/firestore/remote/serializer.cc index eee56f8..19a068b 100644 --- a/Firestore/core/src/firebase/firestore/remote/serializer.cc +++ b/Firestore/core/src/firebase/firestore/remote/serializer.cc @@ -551,9 +551,10 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( break; default: - reader->set_status(Status( - FirestoreErrorCode::DataLoss, - "Input proto bytes cannot be parsed (invalid field number (tag))")); + // Unknown tag. According to the proto spec, we need to ignore these. No + // action required here, though we'll need to skip the relevant bytes + // below. + break; } if (!reader->status().ok()) return nullptr; @@ -595,11 +596,8 @@ std::unique_ptr Serializer::DecodeBatchGetDocumentsResponse( break; default: - // This indicates an internal error as we've already ensured that this - // is a valid field_number. - HARD_FAIL( - "Somehow got an unexpected field number (tag) after verifying that " - "the field number was expected."); + // Unknown tag. According to the proto spec, we need to ignore these. + reader->SkipField(tag); } } diff --git a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc index 7dcdf6e..a902b5d 100644 --- a/Firestore/core/test/firebase/firestore/remote/serializer_test.cc +++ b/Firestore/core/test/firebase/firestore/remote/serializer_test.cc @@ -804,6 +804,68 @@ TEST_F(SerializerTest, EncodesNonEmptyDocument) { ExpectRoundTrip(key, fields, update_time, proto); } +TEST_F(SerializerTest, + BadBatchGetDocumentsResponseTagWithOtherValidTagsPresent) { + // A bad tag should be ignored, in which case, we should successfully + // deserialize the rest of the bytes as if it wasn't there. To craft these + // bytes, we'll use the same technique as + // EncodesFieldValuesWithRepeatedEntries (so go read the comments there + // first). + + // Copy of the real one (from the nanopb generated firestore.pb.h), but with + // only "missing" (a field from the original proto) and an extra_field. + struct google_firestore_v1beta1_BatchGetDocumentsResponse_Fake { + pb_callback_t missing; + int64_t extra_field; + }; + + // Copy of the real one (from the nanopb generated firestore.pb.c), but with + // only missing and an extra_field. Also modified such that extra_field + // now has a tag of 31. + const int invalid_tag = 31; + const pb_field_t + google_firestore_v1beta1_BatchGetDocumentsResponse_fields_Fake[2] = { + PB_FIELD(2, STRING, SINGULAR, CALLBACK, FIRST, + google_firestore_v1beta1_BatchGetDocumentsResponse_Fake, + missing, missing, 0), + PB_FIELD(invalid_tag, INT64, SINGULAR, STATIC, OTHER, + google_firestore_v1beta1_BatchGetDocumentsResponse_Fake, + extra_field, missing, 0), + }; + + const char* missing_value = "projects/p/databases/d/documents/one/two"; + google_firestore_v1beta1_BatchGetDocumentsResponse_Fake crafty_value; + crafty_value.missing.funcs.encode = + [](pb_ostream_t* stream, const pb_field_t* field, void* const* arg) { + const char* missing_value = static_cast(*arg); + if (!pb_encode_tag_for_field(stream, field)) return false; + return pb_encode_string(stream, + reinterpret_cast(missing_value), + strlen(missing_value)); + }; + crafty_value.missing.arg = const_cast(missing_value); + crafty_value.extra_field = 42; + + std::vector bytes(128); + pb_ostream_t stream = pb_ostream_from_buffer(bytes.data(), bytes.size()); + pb_encode(&stream, + google_firestore_v1beta1_BatchGetDocumentsResponse_fields_Fake, + &crafty_value); + bytes.resize(stream.bytes_written); + + // Decode the bytes into the model + StatusOr> actual_model_status = + serializer.DecodeMaybeDocument(bytes); + EXPECT_OK(actual_model_status); + std::unique_ptr actual_model = + std::move(actual_model_status).ValueOrDie(); + + // Ensure the decoded model is as expected. + NoDocument expected_model = + NoDocument(Key("one/two"), SnapshotVersion::None()); + EXPECT_EQ(expected_model, *actual_model.get()); +} + TEST_F(SerializerTest, DecodesNoDocument) { // We can't actually *encode* a NoDocument; the method exposed by the // serializer requires both the document key and contents (as an ObjectValue, -- cgit v1.2.3