|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectgov.nih.nlm.nls.gspell.CommonMisspellings
CommonMisspellings is a simple bad word to good word lookup. There is no magic involved here. We've culled several sources for these common misspellings.
| Constructor Summary | |
CommonMisspellings(GlobalBehavior pSettings)
This is a constructor for CommonMisspellings |
|
CommonMisspellings(java.lang.String pDictionaryName,
int pMode)
This is a constructor for CommonMisspellings |
|
CommonMisspellings(java.lang.String pDictionaryName,
java.lang.String pDictionaryDir,
int pMode)
This is a constructor for CommonMisspellings |
|
| Method Summary | |
void |
cleanup()
Method cleanup |
void |
close()
Method close closes the open db's |
void |
export(java.io.PrintWriter pWriter)
Method export |
void |
find(java.io.BufferedReader pFStream,
java.io.PrintWriter pPrintWriter)
find This method writes to the output the following: inputTerm|candidate|rank|FromMethod|Messages if there are candidates Otherwise, this method writes the following: inputTerm||-9999||No Suggestions Where messages could include "Correct" if the rank = 0; or "No Suggestions" there are no close suggestions. |
Candidate[] |
find(java.lang.String pTerm)
Method find |
void |
flush()
Method flush |
void |
index(java.io.BufferedReader pFStream)
Method index indexes the contents of what somes in from this inputStream This can be a fileStream, or standardinput. |
void |
index(java.lang.String pBadTerm,
java.lang.String pGoodTerm)
Method index indexes this term |
static void |
main(java.lang.String[] args)
main |
static int |
run(java.lang.String[] args)
Method run |
(package private) void |
save()
Method save |
void |
update(java.io.BufferedReader pFStream)
Method update updates the indexes with terms from the file into the dictionary |
void |
update(java.lang.String pBadTerm,
java.lang.String pGoodTerm)
Method update adds this term to the dictionary |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public CommonMisspellings(java.lang.String pDictionaryName,
int pMode)
throws java.lang.Exception
pDictionaryName - The label to call this dictionarypMode - GSpell.WRITE_ONLY|GSpell.READ_WRITE|GSpell.READ_ONLY
public CommonMisspellings(java.lang.String pDictionaryName,
java.lang.String pDictionaryDir,
int pMode)
throws java.lang.Exception
pDictionaryName - The label to call this dictionarypDictionaryDir - The dir that the Dictionary is going to be placed in.pMode - GSpell.WRITE_ONLY|GSpell.READ_WRITE|GSpell.READ_ONLY
public CommonMisspellings(GlobalBehavior pSettings)
throws java.lang.Exception
pSettings - Options that incude truncation, max candidates ...| Method Detail |
public void index(java.io.BufferedReader pFStream)
throws java.lang.Exception
pFStream -
java.lang.Exception
public void index(java.lang.String pBadTerm,
java.lang.String pGoodTerm)
throws java.lang.Exception
pBadTerm - pGoodTerm -
java.lang.Exception
public void update(java.io.BufferedReader pFStream)
throws java.lang.Exception
pFStream -
java.lang.Exception
public void update(java.lang.String pBadTerm,
java.lang.String pGoodTerm)
throws java.lang.Exception
pBadTerm - pGoodTerm -
java.lang.Exception
public void find(java.io.BufferedReader pFStream,
java.io.PrintWriter pPrintWriter)
throws java.lang.Exception
pFStream - pPrintWriter -
java.lang.Exception
public Candidate[] find(java.lang.String pTerm)
throws java.lang.Exception
pTerm -
java.lang.Exception
public void cleanup()
throws java.lang.Exception
java.lang.Exception
public void close()
throws java.lang.Exception
java.lang.Exception
public void flush()
throws java.lang.Exception
java.lang.Exception
public void export(java.io.PrintWriter pWriter)
throws java.lang.Exception
pWriter -
java.lang.Exceptionpublic static int run(java.lang.String[] args)
args -
void save()
throws java.lang.Exception
java.lang.Exceptionpublic static final void main(java.lang.String[] args)
args - The command line input, tokenized
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||