|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.speech.freetts.Segmenter
Annotates an utterance with Relation.SYLLABLE
,
Relation.SYLLABLE_STRUCTURE
, and
Relation.SEGMENT
.
To determine stress, the isStressed
method relies upon
a phone ending in the number "1". Subclasses should override
isStressed
and deStress
if stresses are
determined in other ways.
Relation.SEGMENT
,
Relation.SYLLABLE
,
Relation.SYLLABLE_STRUCTURE
Constructor Summary | |
Segmenter()
|
Method Summary | |
protected java.lang.String |
deStress(java.lang.String phone)
Converts stressed phoneme to regular phoneme. |
protected boolean |
isStressed(java.lang.String phone)
Determines if the given phonemene is stressed. |
void |
processUtterance(Utterance utterance)
Annotates an utterance with Relation.SYLLABLE ,
Relation.SYLLABLE_STRUCTURE , and
Relation.SEGMENT . |
java.lang.String |
toString()
Returns the simple name of this class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Segmenter()
Method Detail |
public void processUtterance(Utterance utterance) throws ProcessException
Relation.SYLLABLE
,
Relation.SYLLABLE_STRUCTURE
, and
Relation.SEGMENT
.
processUtterance
in interface UtteranceProcessor
utterance
- the utterance to process/tokenize
ProcessException
- if an IOException is thrown during the
processing of the utteranceRelation.SEGMENT
,
Relation.SYLLABLE
,
Relation.SYLLABLE_STRUCTURE
protected boolean isStressed(java.lang.String phone)
phone
- the phone to check
protected java.lang.String deStress(java.lang.String phone)
phone
- the phone to convert
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |