|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--SpellCheckerService
| Constructor Summary | |
SpellCheckerService()
|
|
| Method Summary | |
void |
addWord(java.lang.String word,
java.lang.String userDictionary)
Adds a word to the user dictionary |
java.lang.String |
checkSpelling(java.lang.String words)
Checks spelling using all default options |
java.lang.String |
checkSpelling(java.lang.String words,
java.lang.String langauges,
java.lang.String userDictionaries)
Checks spelling using specified languages, and default options |
java.lang.String |
checkSpelling(java.lang.String words,
java.lang.String languages,
java.lang.String userDictionaries,
java.lang.String format,
boolean stripHTML,
int numSuggestions,
int searchDepth,
boolean englishPhonetic,
int charLimit)
checks spelling |
void |
createUserDictionary(java.lang.String dictionaryName)
Opens the user dictionary in memory |
boolean |
isSpelledWrong(java.lang.String word)
Boolean result of a spell check. |
boolean |
isSpelledWrong(java.lang.String word,
java.lang.String languages,
java.lang.String userDictionaries)
Boolean result of a spell check. |
boolean |
isSpelledWrong(java.lang.String word,
java.lang.String languages,
java.lang.String userDictionaries,
int searchDepth,
boolean englishPhonetic)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SpellCheckerService()
| Method Detail |
public void addWord(java.lang.String word,
java.lang.String userDictionary)
throws java.lang.Exception
word - the word to adduserDictionary - the name of the user dictionary
java.lang.Exception
public void createUserDictionary(java.lang.String dictionaryName)
throws java.lang.Exception
dictionaryName - the name of the dictionary
java.lang.Exception
public java.lang.String checkSpelling(java.lang.String words)
throws java.lang.Exception
words - the words to spell check
java.lang.Exception
public java.lang.String checkSpelling(java.lang.String words,
java.lang.String langauges,
java.lang.String userDictionaries)
throws java.lang.Exception
words - the words to spell checkuserDictionaries - a comma-serperated list of user dictionaries or text lexicons (eg "bob,joe"). If null or empty no user dictionaries are used.
java.lang.Exception
public java.lang.String checkSpelling(java.lang.String words,
java.lang.String languages,
java.lang.String userDictionaries,
java.lang.String format,
boolean stripHTML,
int numSuggestions,
int searchDepth,
boolean englishPhonetic,
int charLimit)
throws java.lang.Exception
words - the words to check spelling on.languages - a comma-seperated list of languages to use (eg "american,medical") if empty or null the default (american) is useduserDictionaries - a comma-serperated list of user dictionaries or text lexicons (eg "bob,joe"). If null or empty no user dictionaries are used.format - the format results are returned in, either javascript or wddx (xml)stripHTML - if true stripts the text of tagsnumSuggestions - the number of suggestions to return, default is 14searchDepth - the deepness of the spell checking search algorithm default is 50, higher values yeild better results, but slower searchesenglishPhonetic - if true the english phonetic algorithm is used, this performs well on english dictionaries, but for other languages you will want to disable it.charLimit - the max number of characters to check. Typically set to a high value
java.lang.Exception
public boolean isSpelledWrong(java.lang.String word,
java.lang.String languages,
java.lang.String userDictionaries,
int searchDepth,
boolean englishPhonetic)
throws java.lang.Exception
word - a single word that is in questionlanguages - a comma-seperated list of languages to use (eg "american,medical") if empty or null the default (american) is useduserDictionaries - a comma-serperated list of user dictionaries or text lexicons (eg "bob,joe"). If null or empty no user dictionaries are used.searchDepth - the deepness of the spell checking search algorithm default is 50, higher values yeild better results, but slower searches
java.lang.Exception
public boolean isSpelledWrong(java.lang.String word)
throws java.lang.Exception
word - word to spell check
java.lang.Exception
public boolean isSpelledWrong(java.lang.String word,
java.lang.String languages,
java.lang.String userDictionaries)
throws java.lang.Exception
word - word to spell checklanguages - a comma-seperated list of languages to use (eg "american,medical") if empty or null the default (american) is useduserDictionaries - a comma-serperated list of user dictionaries or text lexicons (eg "bob,joe"). If null or empty no user dictionaries are used.
java.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||