Package com.google.cloud.datastore
Class KeyQuery.Builder
java.lang.Object
com.google.cloud.datastore.KeyQuery.Builder
- All Implemented Interfaces:
StructuredQuery.Builder<Key>
- Enclosing class:
- KeyQuery
A
KeyQuery
builder for queries that return Key
results.-
Method Summary
Modifier and TypeMethodDescriptionaddOrderBy
(StructuredQuery.OrderBy orderBy, StructuredQuery.OrderBy... others) Adds settings to the existing order by clause.build()
Clears any previously specified order by settings.setEndCursor
(Cursor endCursor) Sets the end cursor for the query.setFilter
(StructuredQuery.Filter filter) Sets the kind for the query.Sets the limit for the query.setNamespace
(String namespace) Sets the namespace for the query.setOffset
(int offset) Sets the offset for the query.setOrderBy
(StructuredQuery.OrderBy orderBy, StructuredQuery.OrderBy... others) Sets the query's order by clause (clearing any previously specified order by settings).setStartCursor
(Cursor startCursor) Sets the start cursor for the query.
-
Method Details
-
build
-
setNamespace
Description copied from interface:StructuredQuery.Builder
Sets the namespace for the query.- Specified by:
setNamespace
in interfaceStructuredQuery.Builder<V>
-
setKind
Description copied from interface:StructuredQuery.Builder
Sets the kind for the query.- Specified by:
setKind
in interfaceStructuredQuery.Builder<V>
-
setStartCursor
Description copied from interface:StructuredQuery.Builder
Sets the start cursor for the query.- Specified by:
setStartCursor
in interfaceStructuredQuery.Builder<V>
-
setEndCursor
Description copied from interface:StructuredQuery.Builder
Sets the end cursor for the query.- Specified by:
setEndCursor
in interfaceStructuredQuery.Builder<V>
-
setOffset
Description copied from interface:StructuredQuery.Builder
Sets the offset for the query.- Specified by:
setOffset
in interfaceStructuredQuery.Builder<V>
-
setLimit
Description copied from interface:StructuredQuery.Builder
Sets the limit for the query.- Specified by:
setLimit
in interfaceStructuredQuery.Builder<V>
-
setFilter
- Specified by:
setFilter
in interfaceStructuredQuery.Builder<V>
-
clearOrderBy
Description copied from interface:StructuredQuery.Builder
Clears any previously specified order by settings.- Specified by:
clearOrderBy
in interfaceStructuredQuery.Builder<V>
-
setOrderBy
public KeyQuery.Builder setOrderBy(StructuredQuery.OrderBy orderBy, StructuredQuery.OrderBy... others) Description copied from interface:StructuredQuery.Builder
Sets the query's order by clause (clearing any previously specified order by settings).- Specified by:
setOrderBy
in interfaceStructuredQuery.Builder<V>
-
addOrderBy
public KeyQuery.Builder addOrderBy(StructuredQuery.OrderBy orderBy, StructuredQuery.OrderBy... others) Description copied from interface:StructuredQuery.Builder
Adds settings to the existing order by clause.- Specified by:
addOrderBy
in interfaceStructuredQuery.Builder<V>
-