|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.swabunga.spell.engine.SpellDictionaryASpell
Container for various methods that any SpellDictionary will use.
Based on the original Jazzy aspell port.
| Field Summary | |
protected Transformator |
tf
The reference to a Transformator, used to transform a word into it's phonetic code. |
| Constructor Summary | |
SpellDictionaryASpell(java.io.File phonetic)
|
|
SpellDictionaryASpell(java.io.File phonetic,
java.lang.String encoding)
|
|
SpellDictionaryASpell(java.io.Reader phonetic)
|
|
| Method Summary | |
java.lang.String |
getCode(java.lang.String word)
Returns the phonetic code representing the word. |
java.util.List |
getSuggestions(java.lang.String word,
int threshold)
Returns a list of Word objects that are the suggestions to an incorrect word. |
protected abstract java.util.List |
getWords(java.lang.String phoneticCode)
Returns a list of words that have the same phonetic code. |
boolean |
isCorrect(java.lang.String word)
Returns true if the word is correctly spelled against the current word list. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.swabunga.spell.engine.SpellDictionary |
addWord |
| Field Detail |
protected Transformator tf
| Constructor Detail |
public SpellDictionaryASpell(java.io.File phonetic)
throws java.io.IOException
public SpellDictionaryASpell(java.io.File phonetic,
java.lang.String encoding)
throws java.io.IOException
public SpellDictionaryASpell(java.io.Reader phonetic)
throws java.io.IOException
| Method Detail |
public java.util.List getSuggestions(java.lang.String word,
int threshold)
getSuggestions in interface SpellDictionaryword - Suggestions for given mispelt wordthreshold - The lower boundary of similarity to mispelt word
Wordpublic java.lang.String getCode(java.lang.String word)
protected abstract java.util.List getWords(java.lang.String phoneticCode)
public boolean isCorrect(java.lang.String word)
isCorrect in interface SpellDictionary
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||