public class FileBasedSpellChecker extends AbstractLuceneSpellChecker
A spell checker implementation that loads words from a text file (one word per line).
Modifier and Type | Field and Description |
---|---|
static String |
SOURCE_FILE_CHAR_ENCODING |
static String |
WORD_FIELD_NAME |
accuracy, ACCURACY, COMPARATOR_CLASS, DEFAULT_SUGGESTION_COUNT, dictionary, FIELD, FREQ_COMP, index, INDEX_DIR, indexDir, LOCATION, SCORE_COMP, sd, sourceLocation, spellChecker, SPELLCHECKER_ARG_NAME, STRING_DISTANCE
analyzer, DEFAULT_DICTIONARY_NAME, DICTIONARY_NAME, field, FIELD_TYPE, fieldTypeName, name
Constructor and Description |
---|
FileBasedSpellChecker() |
Modifier and Type | Method and Description |
---|---|
void |
build(SolrCore core,
SolrIndexSearcher searcher)
(re)Builds the spelling index.
|
protected IndexReader |
determineReader(IndexReader reader)
Override to return null, since there is no reader associated with a file based index
|
String |
getCharacterEncoding() |
String |
init(NamedList config,
SolrCore core) |
getAccuracy, getField, getFieldTypeName, getIndexDir, getSourceLocation, getSpellChecker, getStringDistance, getSuggestions, initIndex, reload
getDictionaryName, getQueryAnalyzer, isSuggestionsMayOverlap, mergeSuggestions
public static final String SOURCE_FILE_CHAR_ENCODING
public static final String WORD_FIELD_NAME
public String init(NamedList config, SolrCore core)
init
in class AbstractLuceneSpellChecker
public void build(SolrCore core, SolrIndexSearcher searcher) throws IOException
SolrSpellChecker
build
in class SolrSpellChecker
IOException
protected IndexReader determineReader(IndexReader reader)
determineReader
in class AbstractLuceneSpellChecker
public String getCharacterEncoding()
Copyright © 2000-2015 Apache Software Foundation. All Rights Reserved.