Package com.google.cloud.datastore
Class BaseKey.Builder<B extends BaseKey.Builder<B>>
java.lang.Object
com.google.cloud.datastore.BaseKey.Builder<B>
- Type Parameters:
B
- the key builder.
- Direct Known Subclasses:
IncompleteKey.Builder
,Key.Builder
,KeyFactory
- Enclosing class:
- BaseKey
Base class for key builders.
-
Method Summary
Modifier and TypeMethodDescriptionaddAncestor
(PathElement ancestor) Adds an ancestor for this key.addAncestors
(PathElement ancestor, PathElement... other) Adds the provided ancestors to the key.addAncestors
(Iterable<PathElement> ancestors) Adds the provided ancestors to the key.protected abstract BaseKey
build()
setDatabaseId
(String databaseId) Sets the database id of the key.Sets the kind of the key.setNamespace
(String namespace) Sets the namespace of the key.setProjectId
(String projectId) Sets the project ID of the key.
-
Method Details
-
addAncestor
Adds an ancestor for this key. -
addAncestors
Adds the provided ancestors to the key. -
addAncestors
Adds the provided ancestors to the key. -
setKind
Sets the kind of the key. -
setProjectId
Sets the project ID of the key. -
setNamespace
Sets the namespace of the key. -
setDatabaseId
Sets the database id of the key. -
build
-