|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.extjwnl.data.IndexWordSet
public class IndexWordSet
A class to simplify the access to a set of IndexWord
s, each containing
one part of speech of the same word. IndexWordSets are usually created by a
call to Dictionary.lookupAllIndexWords
.
Constructor Summary | |
---|---|
IndexWordSet(String lemma)
|
Method Summary | |
---|---|
void |
add(IndexWord word)
Adds an IndexWord to this set. |
boolean |
equals(Object object)
It is assumed that IndexWordSets will only be created by calling Dictionary.lookupAllIndexWords ,
so all IndexWordSets with the same lemma should be equal. |
IndexWord |
getIndexWord(POS p)
Returns the IndexWord associated with POS p. |
IndexWord[] |
getIndexWordArray()
Returns an array of the IndexWords in this set. |
Collection |
getIndexWordCollection()
Returns a collection of the IndexWords in this set. |
String |
getLemma()
|
int |
getSenseCount(POS pos)
Finds out how many senses the word with part-of-speech pos has. |
Set |
getValidPOSSet()
Returns a set of all the parts-of-speech for which there is an IndexWord in this set. |
boolean |
isValidPOS(POS pos)
Return true if there is a word with part-of-speech pos in this set. |
void |
remove(POS p)
Removes the IndexWords associated with POS p from this set. |
int |
size()
Returns the number of IndexWords in this set. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public IndexWordSet(String lemma)
Method Detail |
---|
public void add(IndexWord word)
word
- word to addpublic void remove(POS p)
p
- POSpublic int size()
public IndexWord getIndexWord(POS p)
p
- POS
public IndexWord[] getIndexWordArray()
public Collection getIndexWordCollection()
public Set getValidPOSSet()
public boolean isValidPOS(POS pos)
pos
- POS
public int getSenseCount(POS pos)
pos
- POS
public String toString()
toString
in class Object
public String getLemma()
public boolean equals(Object object)
Dictionary.lookupAllIndexWords
,
so all IndexWordSets with the same lemma should be equal.
equals
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |