|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.sun.speech.engine.BaseEngine
com.sun.speech.engine.synthesis.BaseSynthesizer
com.sun.speech.engine.synthesis.text.TextSynthesizer
public class TextSynthesizer
Supports a simple text-output-only JSAPI 1.0 Synthesizer.
Intended for demonstration purposes for those developing JSAPI
implementations. It may also be useful to developers who want a
JSAPI synthesizer that doesn't produce any noise.
| Nested Class Summary | |
|---|---|
class |
TextSynthesizer.OutputHandler
The output device for a TextSynthesizer. |
| Field Summary |
|---|
| Fields inherited from class com.sun.speech.engine.synthesis.BaseSynthesizer |
|---|
speakableListeners, voiceList |
| Fields inherited from class com.sun.speech.engine.BaseEngine |
|---|
audioManager, CLEAR_ALL_STATE, engineListeners, engineModeDesc, engineProperties, engineState, engineStateLock |
| Constructor Summary | |
|---|---|
TextSynthesizer(SynthesizerModeDesc desc)
Creates a new Synthesizer in the DEALLOCATED state. |
|
| Method Summary | |
|---|---|
protected void |
appendQueue(BaseSynthesizerQueueItem item)
Puts an item on the speaking queue and sends a queue updated event. |
void |
cancel()
Cancels the item at the top of the queue. |
void |
cancel(java.lang.Object source)
Cancels a specific object on the queue. |
void |
cancelAll()
Cancels all items on the output queue. |
protected BaseSynthesizerQueueItem |
createQueueItem()
Creates a TextSynthesizerQueueItem. |
java.util.Enumeration |
enumerateQueue()
Returns an enumeration of the queue. |
protected void |
handleAllocate()
Starts the output thread. |
protected void |
handleDeallocate()
Stops the output thread. |
protected void |
handlePause()
Pauses the output. |
protected void |
handleResume()
Resumes the output. |
| Methods inherited from class com.sun.speech.engine.synthesis.BaseSynthesizer |
|---|
addSpeakableListener, createEngineProperties, dispatchSpeechEvent, fireQueueEmptied, fireQueueUpdated, getSynthesizerProperties, getVoiceList, phoneme, postQueueEmptied, postQueueUpdated, removeSpeakableListener, speak, speak, speak, speakPlainText, stateToString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public TextSynthesizer(SynthesizerModeDesc desc)
desc - the operating mode| Method Detail |
|---|
protected void handleAllocate()
handleAllocate in class BaseEngineBaseEngine.allocate()protected void handleDeallocate()
handleDeallocate in class BaseEngineprotected BaseSynthesizerQueueItem createQueueItem()
createQueueItem in class BaseSynthesizer
public java.util.Enumeration enumerateQueue()
throws EngineStateError
enumerateQueue in class BaseSynthesizerEnumeration of the speech output queue or
null.
EngineStateError - if this Synthesizer in the DEALLOCATED or
DEALLOCATING_RESOURCES statesprotected void appendQueue(BaseSynthesizerQueueItem item)
TextSynthesizerQueueItems.
appendQueue in class BaseSynthesizeritem - the item to add to the queue
public void cancel()
throws EngineStateError
cancel in class BaseSynthesizerEngineStateError - if this Synthesizer in the DEALLOCATED or
DEALLOCATING_RESOURCES states
public void cancel(java.lang.Object source)
throws java.lang.IllegalArgumentException,
EngineStateError
cancel in class BaseSynthesizersource - object to be removed from the speech output queue
java.lang.IllegalArgumentException - if the source object is not found in the speech output queue.
EngineStateError - if this Synthesizer in the DEALLOCATED or
DEALLOCATING_RESOURCES states
public void cancelAll()
throws EngineStateError
cancelAll in class BaseSynthesizerEngineStateError - if this Synthesizer in the DEALLOCATED or
DEALLOCATING_RESOURCES statesprotected void handlePause()
handlePause in class BaseEngineprotected void handleResume()
handleResume in class BaseEngine
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||