| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
| |
Note that it isn't possible to *serialize* NoDocuments.
Still TODO:
- Error handling
|
|
|
|
|
|
|
| |
* Add direct support for formatting Objective-C objects
* Rewrite log.h
* Convert FSTWarn to LOG_WARN
* Convert FSTLog to LOG_DEBUG
* Remove FSTLogger
|
| |
|
|
|
|
|
|
| |
* Add HARD_ASSERT
* Use HARD_ASSERT
* Remove FIREBASE_ASSERT
* Remove StringPrintf
|
|
|
| |
Roughly s/google::firebase::v1beta1/v1beta1/g
|
|
|
|
|
|
| |
* Move GoogleTest.podspec out of the Tests tree
* Rename GoogleTests to CoreTests
* Move CoreTests to the top-level
* Move FSTGoogleTestTests.mm into core/test
|
|
|
|
|
|
|
| |
* [De]serialize non-empty Document instances
Still TODO:
- NoDocument
- ErrorHandling
|
|
|
|
|
|
| |
* fix "target of using declaration conflicts with declaration already in scope"
* fix "call to implicitly-deleted copy constructor of *unique_ptr*"
|
|
|
|
| |
* Add StringFormat
* Use StringFormat
|
|
|
|
|
|
| |
* fix lint to run copybara
* address changes
|
|
|
|
| |
Mostly to make existing methods a bit more general to support followup
PR (which will allow encoding/decoding documents with contents.)
|
|
|
|
|
|
|
|
|
| |
* [De]serialize empty Document instances
Still TODO:
- non-empty
- NoDocument
- ErrorHandling
|
|
|
|
|
|
|
|
|
|
|
| |
Was using google_firestore_v1beta1_MapValue_FieldsEntry_key_tag to tag
the key/value pair. (But that tag should be used for the *key* of the
key/value pair, not the pair itself.) Switched to using
google_firestore_v1beta1_MapValue_fields_tag.
This previously worked anyways by coincidence. These two values happen
to be the same. (But it caused me all sorts of confusion as I adapted
this for Document contents.)
|
|
|
|
|
| |
FSTDispatchQueue now doesn't contain any logic of its own and instead
just passes through all method calls to AsyncQueue (backed by an
ExecutorLibdispatch).
|
|
|
|
|
| |
Moved Tag, Reader, Writer from serializer.cc's anon namespace to firebase::firestore::nanopb
This should be bug-for-bug compatible. No changes were made to the moved methods.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Fix order of project elements
* Add immutable container tests to the Firestore project
* Fix style problems in TransformOperations
* Method names should have an initial upper case character (except
getters/setters)
* Pointers bind to the type not the name in C++
* Fix unsigned/signed comparison warning
* Make transform_operations.h Objective-C++ only
It turns out that you can't conditionally define virtual methods. This
causes multiple versions of the vtable to be emitted and when the linker
resolves all the vtable definitions for a class it picks one arbitrarily
causing failures for callers that expect some of the conditional methods
to be present.
* Add precondition_test and field_mask_test to the project
* Add field_transform_test and transform_operations_test to the project
* Clean up missing newline/excess comments
* Use braced initialization to avoid linter false positive on std::transform
|
| |
|
| |
|
|
|
|
|
| |
This should prevent weird bugs due to system time readjustments. Because
operations are scheduled relative to now, the fact that the resulting
timepoint isn't in Unix epoch shouldn't matter.
|
|
|
|
|
|
|
|
| |
dispatch_queue_t is defined differently in libdispatch depending on
whether the library header is being include from Objective-C (or
Objective-C++) code, or else from C or C++ code. Make sure that all
source files in Firestore that include executor_libdispatch.h are
compiled in the same mode (Objective-C++) to avoid linker errors.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
AsyncQueue is a queue that executes given operations asynchronously,
enforcing that only a single operation is executing at any given time,
and that in-progress operations don't spawn more operations. The actual
execution is delegated to a platform-specific executor. Executor is an
interface for a FIFO queue that executes given operations serially. Two
implementations of Executor, one using libdispatch and the other using
C++11 standard library, are provided.
AsyncQueue is not used anywhere in the code base at this point.
|
|
|
|
|
| |
Remove BasePath.Hash() Objective-C compatibility method
Make DocumentKey's hasher use BasePath's segment-based hash code.
|
| |
|
|
|
|
|
|
|
|
|
| |
* Define a Comparator for DocumentKey
* Automated migration from FSTDocumentKeySet to DocumentKeySet
* Manual fixups for DocumentKeySet
* Delete FSTDocumentKeySet
|
| |
|
|
|
|
|
|
|
| |
* Add SortedSet
* Add document_key_set.h
* Add equality to SortedSet
|
| |
|
| |
|
|
|
|
|
| |
This is more interesting than the serializing case, as we should expect
to see occasional corruption of our input byte vector.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* remove conversions in `Local` and `Remote`
* replace `FSTSnapshotVersion` in `Model`
* replace `FSTSnapshotVersion` in the rest
* let test check equal with C++ equal
* fix newly added code
* address changes
|
|
|
|
|
| |
This is good enough to make it possible for the new C++ code to
interoperate with existing Objective-C code where `-hash` is required if
you override `-isEqual:`.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* no-brainer replace `FSTSnapshotVersion` with `SnapshotVersion`
* refresh code
* fix LocalStore
* fix LocalStore (partial revert 78e6c38)
* address changes
|
|
|
|
|
|
| |
* Add a simple range adapter.
* Add SortedMap::keys
* Add SortedMap::keys_from
* Add SortedMap::keys_in
|
| |
|
|
|
|
| |
* Add SortedMap::min
* Add SortedMap::erase
|
|
|
|
|
|
| |
Previously, the tests would compare serialization results against a
precomputed (via protoc) array of bytes. Now they serialize via our
nanopb based class and deserialize via libprotobuf (and vice versa) and
then ensure the result is the same as the input
|
|
|
|
|
|
|
|
|
|
| |
* update FieldValue for Mutation implementation
* address changes
* address changes
* address change
|
|
|
|
|
|
| |
* Standardize method ordering across sorted maps
* Add SortedMap::find
* Add SortedMap::find_index
* Add SortedMap::contains
|
|
|
|
| |
* fix multiline comments by subst /* ... */ for //
* fix unreachable case in a switch statement
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* Add a minimal LlrbNodeIterator
* Remove fixed_size type parameter from FixedArray
The parameter wasn't that useful and caused problems in trying to define
dependent iterator types.
* Add begin()/end() to SortedMap.
|
|
|
|
| |
* Serialize array transform mutations.
* Improve ArrayTransform constructor to avoid extra copying.
|
|
|
|
|
|
|
|
|
| |
* Make LlrbNode Rep more explicit, share empty node
* SortedMap::insert converts implementations
* Implement LlrbNode::insert
* Remove TestPolicy<SortedMap>
|
|
|
|
| |
transforms. (#1101)
|
|
|
|
|
|
|
|
|
|
|
| |
Change Next() to avoid advancing past the end of either iterator by only
advancing if !advanced and if the iterator is still valid.
If Next() is called after the last entry is deleted, SyncToTransaction()
returns false indicating it hasn't advanced but at that point is_valid_
is false. Previously Next() would then attempt to advance one of the
underlying iterators and if it was the mutations_iter_ would advance
past the end, which would cause the next UpdateCurrent() to dereference
random memory.
|
|
|
|
|
| |
This includes the new FIRFieldValue sentinels, the FSTUserDataConverter code to parse them into internal ArrayTransform operations for use in an FSTTransformMutation, and some sanity testing in FSTMutationTests.
I still need to implement FSTTransformMutation support for local application and serialization (and then integration tests).
|