countSync method

int countSync()

Count how many objects match this query.

This operation is much faster than using findAll().length.

Implementation

int countSync() => aggregateSync<int>(AggregationOp.count)!;