|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Provides a generic interface to a dictionary. The dictionary is responsibile for determining how a word is pronounced.
Field Summary | |
static java.lang.String |
PROP_ADD_SIL_ENDING_PRONUNCIATION
The name of the SphinxProperty that specifies whether to add a duplicate SIL-ending pronunication. |
static boolean |
PROP_ADD_SIL_ENDING_PRONUNCIATION_DEFAULT
The default value of PROP_ADD_SIL_ENDING_PRONUNCIATION. |
static java.lang.String |
PROP_ALLOW_MISSING_WORDS
The name of the SphinxProperty that specifies whether the dictionary should return null if a word is not found in the dictionary, or whether it should throw an error. |
static boolean |
PROP_ALLOW_MISSING_WORDS_DEFAULT
The default value of PROP_ALLOW_MISSING_WORDS. |
static java.lang.String |
PROP_CREATE_MISSING_WORDS
The SphinxProperty that specifies whether the Dictionary.getWord() method should return a Word object even if the word does not exist in the dictionary. |
static boolean |
PROP_CREATE_MISSING_WORDS_DEFAULT
The default value of PROP_CREATE_MISSING_WORD. |
static java.lang.String |
PROP_DICTIONARY
The name of the SphinxProperty for the dictionary file path. |
static java.lang.String |
PROP_DICTIONARY_DEFAULT
The default value of PROP_DICTIONARY. |
static java.lang.String |
PROP_FILLER_DICTIONARY
The name of the SphinxProperty for the filler dictionary file path. |
static java.lang.String |
PROP_FILLER_DICTIONARY_DEFAULT
The default value of PROP_FILLER_DICTIONARY. |
static java.lang.String |
PROP_LOCATION
The name of the SphinxProperty that defines the location (directory or jar file) for the dictionary |
static java.lang.String |
PROP_LOCATION_DEFAULT
The default value of PROP_LOCATION. |
static java.lang.String |
PROP_UNIT_MANAGER
The sphinx property that defines the name of the unit manager that is used to convert strings to Unit objects |
static java.lang.String |
PROP_WORD_REPLACEMENT
The name of the SphinxProperty that specifies the word to substitute when a lookup fails to find the word in the dictionary. |
static java.lang.String |
PROP_WORD_REPLACEMENT_DEFAULT
The default value of PROP_WORD_REPLACEMENT. |
static java.lang.String |
SENTENCE_END_SPELLING
Spelling of the sentence end word. |
static java.lang.String |
SENTENCE_START_SPELLING
Spelling of the sentence start word. |
static java.lang.String |
SILENCE_SPELLING
Spelling of the 'word' that marks a silence |
Method Summary | |
void |
allocate()
Allocates the dictionary |
void |
deallocate()
Deallocates the dictionary |
void |
dump()
Dumps out a dictionary |
Word[] |
getFillerWords()
Gets the set of all filler words in the dictionary |
WordClassification[] |
getPossibleWordClassifications()
Returns the set of all possible word classifications for this dictionary. |
Word |
getSentenceEndWord()
Returns the sentence end word. |
Word |
getSentenceStartWord()
Returns the sentence start word. |
Word |
getSilenceWord()
Returns the silence word. |
Word |
getWord(java.lang.String text)
Returns a Word object based on the spelling and its classification. |
Methods inherited from interface edu.cmu.sphinx.util.props.Configurable |
getName, newProperties, register |
Field Detail |
public static final java.lang.String SENTENCE_START_SPELLING
public static final java.lang.String SENTENCE_END_SPELLING
public static final java.lang.String SILENCE_SPELLING
public static final java.lang.String PROP_LOCATION
public static final java.lang.String PROP_LOCATION_DEFAULT
public static final java.lang.String PROP_DICTIONARY
public static final java.lang.String PROP_DICTIONARY_DEFAULT
public static final java.lang.String PROP_FILLER_DICTIONARY
public static final java.lang.String PROP_FILLER_DICTIONARY_DEFAULT
public static final java.lang.String PROP_ADD_SIL_ENDING_PRONUNCIATION
public static final boolean PROP_ADD_SIL_ENDING_PRONUNCIATION_DEFAULT
public static final java.lang.String PROP_WORD_REPLACEMENT
public static final java.lang.String PROP_WORD_REPLACEMENT_DEFAULT
public static final java.lang.String PROP_ALLOW_MISSING_WORDS
public static final boolean PROP_ALLOW_MISSING_WORDS_DEFAULT
public static final java.lang.String PROP_CREATE_MISSING_WORDS
public static final boolean PROP_CREATE_MISSING_WORDS_DEFAULT
public static final java.lang.String PROP_UNIT_MANAGER
Method Detail |
public Word getWord(java.lang.String text)
text
- the spelling of the word of interest.
Pronunciation
public Word getSentenceStartWord()
public Word getSentenceEndWord()
public Word getSilenceWord()
public WordClassification[] getPossibleWordClassifications()
public void dump()
public Word[] getFillerWords()
public void allocate() throws java.io.IOException
java.io.IOException
- if there is trouble loading the dictionarypublic void deallocate()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |