Last updated by maurice 6 years ago
SummaryRe-builds the spelling suggestions index
DescriptionA spelling suggestions index is required to use query suggestions.This method allows you to re-build the spelling suggestions index(es) on demand.The spelling suggestions feature is provided by Compass and normally takes care of itself. In other words, you do not need to re-build the spelling index in normal circumstances.However it may be useful in certain scenarios, eg, in tests.
- @options@ - A
- @fork@ - If @true@, forks a new thread and returns immediately. May not be used with @subIndex@. Default is @false@, in which case the method only returns when the re-build is finished
- @subIndex@ - The sub-index of a searchable class to re-build the spelling suggestions for. May not be used with @fork@. Default is to re-build the spelling suggestions indexes for all classes.
// Rebuild in a backgroudn thread searchableService.rebuildSpellingSuggestions(fork: true)
// Rebuild for just one sub-index (maps to one class hierarchy) searchableService.rebuildSpellingSuggestions(subIndex: "House")