public final class SynthesisRequest extends Object
TextToSpeech.setLanguage(java.util.Locale)
instead of
TextToSpeech.setVoice(android.speech.tts.Voice)
params
argument in TextToSpeech.speak(java.lang.CharSequence, int, android.os.Bundle, java.lang.String)
and TextToSpeech.synthesizeToFile(java.lang.CharSequence, android.os.Bundle, java.io.File, java.lang.String)
.Constructor and Description |
---|
SynthesisRequest(CharSequence text,
Bundle params) |
SynthesisRequest(String text,
Bundle params) |
Modifier and Type | Method and Description |
---|---|
int |
getCallerUid()
Gets the request caller Uid.
|
CharSequence |
getCharSequenceText()
Gets the text which should be synthesized.
|
String |
getCountry()
Gets the ISO 3-letter country code for the language to use.
|
String |
getLanguage()
Gets the ISO 3-letter language code for the language to use.
|
Bundle |
getParams()
Gets the additional params, if any.
|
int |
getPitch()
Gets the pitch to use.
|
int |
getSpeechRate()
Gets the speech rate to use.
|
String |
getText()
Deprecated.
As of API level 21, replaced by
getCharSequenceText() . |
String |
getVariant()
Gets the language variant to use.
|
String |
getVoiceName()
Gets the name of the voice to use.
|
public SynthesisRequest(CharSequence text, Bundle params)
@Deprecated public String getText()
getCharSequenceText()
.public CharSequence getCharSequenceText()
public String getVoiceName()
public String getLanguage()
public String getCountry()
public String getVariant()
public int getSpeechRate()
public int getPitch()
public Bundle getParams()
public int getCallerUid()