|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.swabunga.spell.event.AbstractWordTokenizer
com.swabunga.spell.event.StringWordTokenizer
This class tokenizes a input string.
It also allows for the string to be altered by calls to replaceWord(). The result after the spell checking is completed is available to the call to getContext.
| Field Summary |
| Fields inherited from class com.swabunga.spell.event.AbstractWordTokenizer |
currentWord, finder, sentenceIterator, wordCount |
| Constructor Summary | |
StringWordTokenizer(java.lang.String s)
Creates a new StringWordTokenizer object. |
|
StringWordTokenizer(java.lang.String s,
WordFinder finder)
|
|
StringWordTokenizer(WordFinder wf)
Creates a new StringWordTokenizer object. |
|
| Method Summary | |
java.lang.String |
getFinalText()
Deprecated. use getContext() instead as per the WordTokenizer interface specification. |
void |
replaceWord(java.lang.String s)
Replace the current word in the iteration with the String s. |
| Methods inherited from class com.swabunga.spell.event.AbstractWordTokenizer |
getContext, getCurrentWordCount, getCurrentWordEnd, getCurrentWordPosition, hasMoreWords, isNewSentence, nextWord |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public StringWordTokenizer(java.lang.String s)
s - the string to tokenize.public StringWordTokenizer(WordFinder wf)
wf - the custom WordFinder to use in tokenizing. Note
that the string to tokenize will be encapsulated within the WordFinder.
public StringWordTokenizer(java.lang.String s,
WordFinder finder)
| Method Detail |
public java.lang.String getFinalText()
public void replaceWord(java.lang.String s)
replaceWord in interface WordTokenizerreplaceWord in class AbstractWordTokenizers - the String to replace the current word.
WordNotFoundException - current word not yet set.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||