'Returns a cached Model instance given the entity key if available.
Args:
key: Key instance.
Returns:
A Model instance if the key exists in the cache.'

def _load_from_cache_if_available(self, key):

    if (key in self._cache):
        entity = self._cache[key]
        if ((entity is None) or (entity._key == key)):
            raise tasklets.Return(entity)
