Beispiel #1
0
 def expand_prefix(self, fieldname, prefix):
     self._test_field(fieldname)
     # If a fieldcache for the field is already loaded, we already have the
     # values for the field in memory, so just yield them from there
     if self.fieldcache_loaded(fieldname):
         return self._texts_in_fieldcache(fieldname, prefix)
     else:
         return IndexReader.expand_prefix(self, fieldname, prefix)
 def expand_prefix(self, fieldname, prefix):
     self._test_field(fieldname)
     # If a fieldcache for the field is already loaded, we already have the
     # values for the field in memory, so just yield them from there
     if self.fieldcache_loaded(fieldname):
         return self._texts_in_fieldcache(fieldname, prefix)
     else:
         return IndexReader.expand_prefix(self, fieldname, prefix)