def key(self, entity, filter_predicate=None):
    names = self._get_prop_names()
    names.add(datastore_types.KEY_SPECIAL_PROPERTY)
    if filter_predicate is not None:
      names |= filter_predicate._get_prop_names()

    value_map = _make_key_value_map(entity, names)
    if filter_predicate is not None:
      filter_predicate._prune(value_map)
    return (self._key(value_map),
            value_map[datastore_types.KEY_SPECIAL_PROPERTY])
Constructs a "key" value for the given entity based on the current order.
dataset/ETHPy150Open AppScale/appscale/AppServer/google/appengine/datastore/datastore_query.py/Order.key