|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.speech.engine.BaseEngineProperties com.sun.speech.engine.synthesis.BaseSynthesizerProperties
Supports the JSAPI 1.0 SynthesizerProperties
interface. The properties of a Synthesizer
are:
Field Summary | |
protected float |
currentPitch
The current pitch. |
protected float |
currentPitchRange
The current pitch range. |
protected float |
currentSpeakingRate
The current speaking rate. |
protected javax.speech.synthesis.Voice |
currentVoice
The current voice. |
protected float |
currentVolume
The current volume. |
protected float |
defaultPitch
The default pitch. |
protected float |
defaultPitchRange
The default pitch range. |
protected float |
defaultSpeakingRate
The default specking rate. |
protected javax.speech.synthesis.Voice |
defaultVoice
The default voice. |
protected float |
defaultVolume
The default volume. |
Fields inherited from class com.sun.speech.engine.BaseEngineProperties |
propertyChangeListeners |
Constructor Summary | |
BaseSynthesizerProperties()
Class constructor. |
|
BaseSynthesizerProperties(javax.speech.synthesis.Voice defaultVoice,
float defaultPitch,
float defaultPitchRange,
float defaultSpeakingRate,
float defaultVolume)
Creates a new BaseSynthesizerProperties with the
given default values. |
Method Summary | |
float |
getPitch()
Gets the baseline pitch for synthesis. |
float |
getPitchRange()
Gets the pitch range for synthesis. |
float |
getSpeakingRate()
Gets the current target speaking rate in words per minute. |
javax.speech.synthesis.Voice |
getVoice()
Gets the current synthesizer voice. |
float |
getVolume()
Gets the current volume. |
void |
reset()
Resets all properties to their default values. |
void |
setPitch(float hertz)
Sets the baseline pitch for the current synthesis voice. |
void |
setPitchRange(float hertz)
Sets the pitch range for the current synthesis voice. |
void |
setSpeakingRate(float wpm)
Sets the target speaking rate in words per minute. |
void |
setVoice(javax.speech.synthesis.Voice voice)
Sets the current synthesizer voice. |
void |
setVolume(float volume)
Sets the volume. |
Methods inherited from class com.sun.speech.engine.BaseEngineProperties |
addPropertyChangeListener, dispatchSpeechEvent, firePropertyChangeEvent, getControlComponent, postPropertyChangeEvent, postPropertyChangeEvent, postPropertyChangeEvent, postPropertyChangeEvent, removePropertyChangeListener |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.speech.EngineProperties |
addPropertyChangeListener, getControlComponent, removePropertyChangeListener |
Field Detail |
protected javax.speech.synthesis.Voice defaultVoice
protected float defaultPitch
protected float defaultPitchRange
protected float defaultSpeakingRate
protected float defaultVolume
protected javax.speech.synthesis.Voice currentVoice
protected float currentPitch
protected float currentPitchRange
protected float currentSpeakingRate
protected float currentVolume
Constructor Detail |
public BaseSynthesizerProperties()
public BaseSynthesizerProperties(javax.speech.synthesis.Voice defaultVoice, float defaultPitch, float defaultPitchRange, float defaultSpeakingRate, float defaultVolume)
BaseSynthesizerProperties
with the
given default values.
defaultVoice
- the default voicedefaultPitch
- the default pitchdefaultPitchRange
- the default pitch rangedefaultSpeakingRate
- the default speaking ratedefaultVolume
- the default volumeMethod Detail |
public void reset()
reset
in interface javax.speech.EngineProperties
reset
in class BaseEngineProperties
public javax.speech.synthesis.Voice getVoice()
getVoice
in interface javax.speech.synthesis.SynthesizerProperties
setVoice(javax.speech.synthesis.Voice)
public void setVoice(javax.speech.synthesis.Voice voice) throws java.beans.PropertyVetoException
setVoice
in interface javax.speech.synthesis.SynthesizerProperties
voice
- the new voice
java.beans.PropertyVetoException
- if the voice cannot be set to
the given valuegetVoice()
public float getPitch()
getPitch
in interface javax.speech.synthesis.SynthesizerProperties
setPitch(float)
public void setPitch(float hertz) throws java.beans.PropertyVetoException
setPitch
in interface javax.speech.synthesis.SynthesizerProperties
hertz
- the new baseline pitch in Hertz
java.beans.PropertyVetoException
- if the baseline pitch cannot be
set to the given valuegetPitch()
public float getPitchRange()
getPitchRange
in interface javax.speech.synthesis.SynthesizerProperties
setPitchRange(float)
public void setPitchRange(float hertz) throws java.beans.PropertyVetoException
setPitchRange
in interface javax.speech.synthesis.SynthesizerProperties
hertz
- the new range in Hertz
java.beans.PropertyVetoException
- if the pitch range cannot be set
to the given valuegetPitchRange()
public float getSpeakingRate()
getSpeakingRate
in interface javax.speech.synthesis.SynthesizerProperties
getSpeakingRate()
public void setSpeakingRate(float wpm) throws java.beans.PropertyVetoException
setSpeakingRate
in interface javax.speech.synthesis.SynthesizerProperties
wpm
- the new speaking rate in words per minute
java.beans.PropertyVetoException
- if the speaking rate cannot be
set to the given valuegetSpeakingRate()
public float getVolume()
getVolume
in interface javax.speech.synthesis.SynthesizerProperties
float
0.0 and 1.0, inclusivesetVolume(float)
public void setVolume(float volume) throws java.beans.PropertyVetoException
setVolume
in interface javax.speech.synthesis.SynthesizerProperties
volume
- the new volume expressed as a float
0.0 and 1.0, inclusive
java.beans.PropertyVetoException
- if the volume cannot be
set to the given valuegetVolume()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |