diff options
author | rsgowman <rgowman@google.com> | 2018-07-13 16:22:07 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-13 16:22:07 -0400 |
commit | 920cfbfa998ca9d04cce5f7731aced7e950a3477 (patch) | |
tree | 76f62fa05240d533477707bb4cd26df6808cd523 /Firestore/core/src/firebase/firestore/model/field_value.h | |
parent | 81ec26d4ff2f9cc295bf057167a649a34a7a11aa (diff) |
Initial (incomplete) implementation of f:f:core::Filter (#1495)
And RelationFilter subclass.
Used to implement the next step in core::Query.
Diffstat (limited to 'Firestore/core/src/firebase/firestore/model/field_value.h')
-rw-r--r-- | Firestore/core/src/firebase/firestore/model/field_value.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Firestore/core/src/firebase/firestore/model/field_value.h b/Firestore/core/src/firebase/firestore/model/field_value.h index 09c8531..697d5b3 100644 --- a/Firestore/core/src/firebase/firestore/model/field_value.h +++ b/Firestore/core/src/firebase/firestore/model/field_value.h @@ -108,6 +108,15 @@ class FieldValue { return tag_; } + /** + * PORTING NOTE: This deviates from the other platforms that define TypeOrder. + * Since we already define Type for union types, we use it together with this + * function to achieve the equivalent order of types i.e. + * i) if two types are comparable, then they are of equal order; + * ii) otherwise, their order is the same as the order of their Type. + */ + static bool Comparable(Type lhs, Type rhs); + bool boolean_value() const { HARD_ASSERT(tag_ == Type::Boolean); return boolean_value_; |