QueryExecute<OBJ, R> extension
Operations for query builders.
- on
-
- QueryBuilder<
OBJ, R, QOperations>
- QueryBuilder<
Methods
-
build(
) → IsarQuery< R> - Create a query from this query builder.
-
count(
) → int - Count how many objects match the query.
-
countAsync(
) → Future< int> - Count how many objects match the query.
-
deleteAll(
{int? offset, int? limit}) → int - Delete all objects that match this query. Returns the number of deleted objects.
-
deleteFirst(
{int? offset}) → bool - Delete the first object that matches this query. Returns whether an object has been deleted.
-
exportJson(
{int? offset, int? limit}) → List< Map< String, dynamic> > - Export the results of this query as json.
-
findAll(
{int? offset, int? limit}) → List< R> - Find all objects that match this query.
-
findAllAsync(
{int? offset, int? limit}) → Future< List< R> > - Find all objects that match this query.
-
findFirst(
{int? offset}) → R? -
Find the first object that matches this query or
null
if no object matches. -
findFirstAsync(
{int? offset}) → Future< R?> -
Find the first object that matches this query or
null
if no object matches. -
isEmpty(
) → bool -
Yields
true
if there are no objects that match the query. -
isEmptyAsync(
) → Future< bool> -
Yields
true
if there are no objects that match the query. -
watch(
{bool fireImmediately = false, int? offset, int? limit}) → Stream< List< R> > - Create a watcher that yields the results of this query whenever its results have (potentially) changed.
-
watchLazy(
{bool fireImmediately = false}) → Stream< void> -
Watch the query for changes. If
fireImmediately
istrue
, an event will be fired immediately.