diff --git a/gcloud/datastore/dataset.py b/gcloud/datastore/dataset.py index f72aeb0ab971..674290e59e0a 100644 --- a/gcloud/datastore/dataset.py +++ b/gcloud/datastore/dataset.py @@ -82,11 +82,11 @@ def entity(self, kind, exclude_from_indexes=()): """Create an entity bound to this dataset. :type kind: string - :param kind: the "kind" of the new entity. + :param kind: the "kind" of the new entity (see + https://cloud.google.com/datastore/docs/concepts/entities#Datastore_Kinds_and_identifiers) - :type exclude_from_indexes: sequence of str - :param exclude_from_indexes: Names of properties *not* to be indexed - for the entity. + :param exclude_from_indexes: names of fields whose values are not to + be indexed. :rtype: :class:`gcloud.datastore.entity.Entity` :returns: a new Entity instance, bound to this dataset. diff --git a/gcloud/datastore/entity.py b/gcloud/datastore/entity.py index 295792e28bbd..96c4c887f937 100644 --- a/gcloud/datastore/entity.py +++ b/gcloud/datastore/entity.py @@ -78,6 +78,15 @@ class Entity(dict): Python3), will be saved using the 'blob_value' field, without any decoding / encoding step. + :type dataset: :class:`gcloud.datastore.dataset.Dataset`, or None + :param dataset: the Dataset instance associated with this entity. + + :type kind: str + :param kind: the "kind" of the entity (see + https://cloud.google.com/datastore/docs/concepts/entities#Datastore_Kinds_and_identifiers) + + :param exclude_from_indexes: names of fields whose values are not to be + indexed for this entity. """ def __init__(self, dataset=None, kind=None, exclude_from_indexes=()): @@ -142,9 +151,9 @@ def kind(self): return self._key.kind() def exclude_from_indexes(self): - """Return field names which are *not* to be indexed. + """Names of fields which are *not* to be indexed for this entity. - :rtype: list(str) + :rtype: sequence of field names """ return frozenset(self._exclude_from_indexes)