|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--gov.nist.nlpir.irf.de.normalize.StopWordTable
This class implements a table of unique stop word strings
NOTE: entries are lowercased before addition and words to
be looked up are lowercased first.
Field Summary | |
private static int |
EOF
Working copy of end of file marker value |
private java.util.HashSet |
table
Table of stop words |
Constructor Summary | |
StopWordTable()
Constructs an empty stopword table |
|
StopWordTable(java.lang.String fileName)
Creates the Stop Word Table from a file. |
Method Summary | |
void |
addWord(java.lang.String word)
Adds a lowercased stop word to the table |
boolean |
containsWord(java.lang.String wordToLookUp)
Tests whether the given word is in the table or not. |
void |
present()
Presents the contents of the table. |
void |
removeWord(java.lang.String word)
Removes a stop word from the table |
int |
size()
Returns the number of words in the table |
Methods inherited from class java.lang.Object |
|
Field Detail |
private java.util.HashSet table
private static int EOF
Constructor Detail |
public StopWordTable()
public StopWordTable(java.lang.String fileName)
fileName
- the name of the file used.Method Detail |
public final void addWord(java.lang.String word)
public final void removeWord(java.lang.String word)
public final int size()
public void present()
public final boolean containsWord(java.lang.String wordToLookUp)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |