QueryBuilder<T extends ParseObject> class

Class to create complex queries

Constructors

QueryBuilder(T object)
Class to create complex queries
QueryBuilder.and(T object, List<QueryBuilder<T>> list)
QueryBuilder.copy(QueryBuilder<T> query)
factory
QueryBuilder.name(String classname)
factory
QueryBuilder.nor(T object, List<QueryBuilder<T>> list)
QueryBuilder.or(T object, List<QueryBuilder<T>> list)

Properties

extraOptions Map<String, dynamic>
final
hashCode int
The hash code for this object.
no setterinherited
limiters Map<String, dynamic>
final
object ↔ T
getter/setter pair
queries List<MapEntry<String, dynamic>>
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

buildQueries(List<MapEntry<String, dynamic>> queries) String
Runs through all queries and adds them to a query string
buildQuery() String
Builds the query for Parse
count() Future<ParseResponse>
Counts the number of objects that match this query
distinct<U extends ParseObject>(String className) Future<ParseResponse>
dontSelectKeys(String column, dynamic value) → void
Returns an object where the String column doesn't select
excludeKeys(List<String> keys) → void
Exclude specific fields from the returned query
find() Future<List<T>>
Find the objects that satisfy the query. Returns an empty list if no objects are found.
first() Future<T?>
Find the first object that satisfies the query. Returns null, if no object is found.
getExtraOptions(Map<String, dynamic> map) String
Adds extra options to the query
getLimiters(Map<String, dynamic> map) String
Adds the limiters to the query, i.e. skip=10, limit=10
getLimitersRelational(Map<String, dynamic> map) String
Adds the limiters to the query relational, i.e. skip=10, limit=10
includeObject(List<String> objectTypes) → void
Includes other ParseObjects stored as a Pointer
keysToReturn(List<String> keys) → void
Define which keys in an object to return.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
orderByAscending(String order) → void
Sorts the results in ascending order.
orderByDescending(String order) → void
Sorts the results descending order.
query<U extends ParseObject>({ProgressCallback? progressCallback}) Future<ParseResponse>
Finishes the query and calls the server
regEx(String column, String value) → void
Returns an object where the String column has a regEx performed on, this can include ^StringsWith, or ^EndsWith. This can be manipulated to the users desire
selectKeys(String column, dynamic value) → void
Returns an object where the String column contains select
setAmountToSkip(int skip) → void
Useful for pagination, skips int amount of results
setLimit(int limit) → void
Adds a limit to amount of results return from Parse
setRedirectClassNameForKey(String key) → void
Used by ParseRelation getQuery()
toString() String
A string representation of this object.
inherited
whereArrayContainsAll(String column, List value) → void
Returns an object where the String column contains all
whereContainedIn(String column, List value) → void
Returns an object where the String column is containedIn
whereContains(String column, String substring, {bool caseSensitive = false}) → void
Add a constraint for finding String values that contain the provided substring
whereContainsWholeWord(String column, String searchTerm, {bool caseSensitive = false, bool orderByScore = true, bool diacriticSensitive = false}) → void
Powerful search for containing whole words. This search is much quicker than regex and can search for whole words including whether they are case sensitive or not. This search can also order by the score of the search
whereDoesNotMatchKeyInQuery<E extends ParseObject>(String column, String keyInQuery, QueryBuilder<E> query) → void
Add a constraint to the query that requires a particular key's value does not match any value for a key in the results of another ParseQuery
whereDoesNotMatchQuery<E extends ParseObject>(String column, QueryBuilder<E> query) → void
Add a constraint to the query that requires a particular key's value does not match another QueryBuilder
whereEndsWith(String column, String prefix, {bool caseSensitive = false}) → void
Add a constraint for finding objects where the String value in column ends with prefix
whereEquals(String where) → void
Creates a query based on where
whereEqualTo(String column, dynamic value) → void
Add a constraint to the query that requires a particular column's value to be equal to the provided value
whereGreaterThan(String column, dynamic value) → void
Returns an object where the String column contains a value greater than value
whereGreaterThanOrEqualsTo(String column, dynamic value) → void
Returns an object where the String column contains a value greater than equal to value
whereLessThan(String column, dynamic value) → void
Returns an object where the String column contains a value less than value
whereLessThanOrEqualTo(String column, dynamic value) → void
Returns an object where the String column contains a value less or equal to than value
whereMatchesKeyInQuery<E extends ParseObject>(String column, String keyInQuery, QueryBuilder<E> query) → void
Add a constraint to the query that requires a particular key's value matches a value for a key in the results of another ParseQuery.
whereMatchesQuery<E extends ParseObject>(String column, QueryBuilder<E> query) → void
Add a constraint to the query that requires a particular key's value match another QueryBuilder
whereNear(String column, ParseGeoPoint point) → void
Returns an objects with key point values near the point given
whereNotContainedIn(String column, List value) → void
Returns an object where the String column is notContainedIn
whereNotEqualTo(String column, dynamic value) → void
Add a constraint to the query that requires a particular column's value to be not equal to the provided value
wherePolygonContains(String column, ParseGeoPoint point) → void
Add a constraint to the query that requires a particular key's coordinates that contains a point
whereRelatedTo(String column, String className, String objectId) → void
Retrieves related objets where String column is a relation field to the class String className
whereStartsWith(String column, String prefix, {bool caseSensitive = false}) → void
Add a constraint for finding objects where the String value in column starts with prefix
whereValueExists(String column, bool value) → void
Returns an object where the String column for the object has data correctly entered/saved
whereWithinGeoBox(String column, ParseGeoPoint southwest, ParseGeoPoint northeast) → void
Returns an object with key point values contained within a given rectangular geographic bounding box.
whereWithinKilometers(String column, ParseGeoPoint point, double maxDistance) → void
Returns an object with key point values near the point given and within the maximum distance given.
whereWithinMiles(String column, ParseGeoPoint point, double maxDistance) → void
Returns an object with key point values near the point given and within the maximum distance given.
whereWithinPolygon(String column, List<ParseGeoPoint> points) → void
Return an object with key coordinates be contained within and on the bounds of a given polygon. Supports closed and open (last point is connected to first) paths Polygon must have at least 3 points
whereWithinRadians(String column, ParseGeoPoint point, double maxDistance) → void
Returns an object with key point values near the point given and within the maximum distance given.

Operators

operator ==(Object other) bool
The equality operator.
inherited