|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.didion.jwnl.dictionary.Dictionary
net.didion.jwnl.dictionary.AbstractCachingDictionary
net.didion.jwnl.dictionary.DatabaseBackedDictionary
public class DatabaseBackedDictionary
Field Summary | |
---|---|
static java.lang.String |
DATABASE_MANAGER
|
static java.lang.String |
DICTIONARY_ELEMENT_FACTORY
|
static java.lang.String |
MORPH
MorphologicalProcessor class install parameter. |
Constructor Summary | |
---|---|
DatabaseBackedDictionary()
|
Method Summary | |
---|---|
void |
close()
Shut down the dictionary |
Exc |
getException(POS pos,
java.lang.String derivation)
Lookup derivation in the exceptions file of part-of-speech
pos and return an Exc object containing the results. |
java.util.Iterator |
getExceptionIterator(POS pos)
Return an Iterator over all the Exceptions in the database. |
IndexWord |
getIndexWord(POS pos,
java.lang.String lemma)
Look up a word in the database. |
java.util.Iterator |
getIndexWordIterator(POS pos)
Return an Iterator over all the IndexWords of part-of-speech pos in the database. |
java.util.Iterator |
getIndexWordIterator(POS pos,
java.lang.String substring)
Return an Iterator over all the IndexWords of part-of-speech pos whose lemmas contain substring as a substring. |
IndexWord |
getRandomIndexWord(POS pos)
|
java.lang.String |
getSenseKey(long offset,
java.lang.String lemma)
Not implemented in DB yet. |
Synset |
getSynsetAt(POS pos,
long offset)
Return the Synset at offset offset from the database. |
java.util.Iterator |
getSynsetIterator(POS pos)
Return an Iterator over all the Synsets of part-of-speech pos in the database. |
int |
getUsageCount(long offset,
java.lang.String lemma)
Not implemented in DB yet. |
void |
install(java.util.Map params)
|
Methods inherited from class net.didion.jwnl.dictionary.AbstractCachingDictionary |
---|
clearCache, clearCache, getCacheCapacity, getCacheSizes, isCachingEnabled, setCacheCapacity, setCacheCapacity, setCachingEnabled |
Methods inherited from class net.didion.jwnl.dictionary.Dictionary |
---|
getInstance, getMorphologicalProcessor, lookupAllIndexWords, lookupIndexWord, uninstall |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String MORPH
MorphologicalProcessor
class install parameter. The value should be the
class of MorphologicalProcessor
to use.
public static final java.lang.String DICTIONARY_ELEMENT_FACTORY
public static final java.lang.String DATABASE_MANAGER
Constructor Detail |
---|
public DatabaseBackedDictionary()
Method Detail |
---|
public void install(java.util.Map params) throws JWNLException
JWNLException
public IndexWord getIndexWord(POS pos, java.lang.String lemma) throws JWNLException
Dictionary
Dictionary.lookupIndexWord(POS, String)
.
getIndexWord
in class Dictionary
pos
- The part-of-speech.lemma
- The orthographic representation of the word.
null
if
no such entry exists.
JWNLException
public java.util.Iterator getIndexWordIterator(POS pos) throws JWNLException
Dictionary
getIndexWordIterator
in class Dictionary
pos
- The part-of-speech
IndexWord
s
JWNLException
public java.util.Iterator getIndexWordIterator(POS pos, java.lang.String substring) throws JWNLException
Dictionary
getIndexWordIterator
in class Dictionary
pos
- The part-of-speech.
IndexWord
s.
JWNLException
public IndexWord getRandomIndexWord(POS pos) throws JWNLException
getRandomIndexWord
in class Dictionary
JWNLException
public Synset getSynsetAt(POS pos, long offset) throws JWNLException
Dictionary
Synset
at offset offset
from the database.
getSynsetAt
in class Dictionary
pos
- The part-of-speech file to look inoffset
- The offset of the synset in the file
JWNLException
public java.util.Iterator getSynsetIterator(POS pos) throws JWNLException
Dictionary
getSynsetIterator
in class Dictionary
pos
- The part-of-speech.
Synset
s.
JWNLException
public Exc getException(POS pos, java.lang.String derivation) throws JWNLException
Dictionary
derivation
in the exceptions file of part-of-speech
pos
and return an Exc object containing the results.
getException
in class Dictionary
pos
- the exception file to look inderivation
- the word to look up
JWNLException
public java.util.Iterator getExceptionIterator(POS pos) throws JWNLException
Dictionary
getExceptionIterator
in class Dictionary
pos
- the part-of-speech
String
s
JWNLException
public void close()
Dictionary
close
in class Dictionary
public int getUsageCount(long offset, java.lang.String lemma)
getUsageCount
in class Dictionary
public java.lang.String getSenseKey(long offset, java.lang.String lemma)
getSenseKey
in class Dictionary
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |