|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.solr.spelling.SolrSpellChecker
public abstract class SolrSpellChecker
Refer to SpellCheckComponent for more details.
| Field Summary | |
|---|---|
protected Analyzer |
analyzer
|
static String |
DEFAULT_DICTIONARY_NAME
|
static String |
DICTIONARY_NAME
|
protected String |
field
|
static String |
FIELD
|
static String |
FIELD_TYPE
|
protected String |
fieldTypeName
|
protected String |
name
Dictionary name |
| Constructor Summary | |
|---|---|
SolrSpellChecker()
|
|
| Method Summary | |
|---|---|
abstract void |
build(SolrCore core,
SolrIndexSearcher searcher)
(re)Builds the spelling index. |
protected float |
getAccuracy()
Get the value of SpellingParams.SPELLCHECK_ACCURACY if supported. |
String |
getDictionaryName()
|
Analyzer |
getQueryAnalyzer()
|
protected StringDistance |
getStringDistance()
Get the distance implementation used by this spellchecker, or NULL if not applicable. |
abstract SpellingResult |
getSuggestions(SpellingOptions options)
Get suggestions for the given query. |
String |
init(org.apache.solr.common.util.NamedList config,
SolrCore core)
|
boolean |
isSuggestionsMayOverlap()
|
SpellingResult |
mergeSuggestions(SpellCheckMergeData mergeData,
int numSug,
int count,
boolean extendedResults)
Integrate spelling suggestions from the various shards in a distributed environment. |
abstract void |
reload(SolrCore core,
SolrIndexSearcher searcher)
Reloads the index. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String DICTIONARY_NAME
public static final String DEFAULT_DICTIONARY_NAME
public static final String FIELD
public static final String FIELD_TYPE
protected String name
protected Analyzer analyzer
protected String field
protected String fieldTypeName
| Constructor Detail |
|---|
public SolrSpellChecker()
| Method Detail |
|---|
public String init(org.apache.solr.common.util.NamedList config,
SolrCore core)
public SpellingResult mergeSuggestions(SpellCheckMergeData mergeData,
int numSug,
int count,
boolean extendedResults)
mergeData - numSug - count - extendedResults - public Analyzer getQueryAnalyzer()
public String getDictionaryName()
public abstract void reload(SolrCore core,
SolrIndexSearcher searcher)
throws IOException
IOException
public abstract void build(SolrCore core,
SolrIndexSearcher searcher)
protected float getAccuracy()
SpellingParams.SPELLCHECK_ACCURACY if supported.
Otherwise throws UnsupportedOperationException.
protected StringDistance getStringDistance()
public abstract SpellingResult getSuggestions(SpellingOptions options)
throws IOException
SpellingResult.getSuggestions() suggestions must be ordered by best suggestion first.
options - The SpellingOptions to use
SpellingResult suggestions
IOException - if there is an error producing suggestionspublic boolean isSuggestionsMayOverlap()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||