Search in sources :

Example 1 with LimitType

use of com.google.firebase.firestore.core.Query.LimitType in project firebase-android-sdk by firebase.

the class LocalSerializer method decodeBundledQuery.

public BundledQuery decodeBundledQuery(com.google.firestore.bundle.BundledQuery bundledQuery) {
    LimitType limitType = bundledQuery.getLimitType().equals(com.google.firestore.bundle.BundledQuery.LimitType.FIRST) ? LimitType.LIMIT_TO_FIRST : LimitType.LIMIT_TO_LAST;
    Target target = rpcSerializer.decodeQueryTarget(bundledQuery.getParent(), bundledQuery.getStructuredQuery());
    return new BundledQuery(target, limitType);
}
Also used : Target(com.google.firebase.firestore.core.Target) BundledQuery(com.google.firebase.firestore.bundle.BundledQuery) LimitType(com.google.firebase.firestore.core.Query.LimitType)

Aggregations

BundledQuery (com.google.firebase.firestore.bundle.BundledQuery)1 LimitType (com.google.firebase.firestore.core.Query.LimitType)1 Target (com.google.firebase.firestore.core.Target)1