語言

TextToSpeech 建構函式

定義

多載

名稱 Description
TextToSpeech(Context, TextToSpeech+IOnInitListener)

TextToSpeech 類別的建構器,使用預設的 TTS 引擎。

TextToSpeech(IntPtr, JniHandleOwnership)

用於建立 JNI 物件受管理表示的建構器;由執行時呼叫。

TextToSpeech(Context, TextToSpeech+IOnInitListener, String)

TextToSpeech 類別的構造器,使用給定的 TTS 引擎。

TextToSpeech(Context, TextToSpeech+IOnInitListener)

TextToSpeech 類別的建構器,使用預設的 TTS 引擎。

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;Landroid/speech/tts/TextToSpeech$OnInitListener;)V", "")]
public TextToSpeech(Android.Content.Context? context, Android.Speech.Tts.TextToSpeech.IOnInitListener? listener);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;Landroid/speech/tts/TextToSpeech$OnInitListener;)V", "")>]
new Android.Speech.Tts.TextToSpeech : Android.Content.Context * Android.Speech.Tts.TextToSpeech.IOnInitListener -> Android.Speech.Tts.TextToSpeech

參數

context
Context

這個實例所處的情境。

listener
TextToSpeech.IOnInitListener

TextToSpeech.OnInitListener當 TextToSpeech 引擎初始化時,就會被呼叫。 若發生故障,監聽者可能會立即被呼叫,且在 TextToSpeech 實例尚未完全建構之前。

屬性

備註

Java 文件 android.speech.tts.TextToSpeech.TextToSpeech(android.content.Context, android.speech.tts.OnInitListener)。

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於

TextToSpeech(IntPtr, JniHandleOwnership)

用於建立 JNI 物件受管理表示的建構器;由執行時呼叫。

protected TextToSpeech(IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Android.Speech.Tts.TextToSpeech : nativeint * Android.Runtime.JniHandleOwnership -> Android.Speech.Tts.TextToSpeech

參數

javaReference
IntPtr

nativeint

IntPtr,包含 Java Native Interface (JNI) 對象參考。

transfer
JniHandleOwnership

JniHandleOwnership,指出如何處理javaReference

備註

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於

TextToSpeech(Context, TextToSpeech+IOnInitListener, String)

TextToSpeech 類別的構造器,使用給定的 TTS 引擎。

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;Landroid/speech/tts/TextToSpeech$OnInitListener;Ljava/lang/String;)V", "")]
public TextToSpeech(Android.Content.Context? context, Android.Speech.Tts.TextToSpeech.IOnInitListener? listener, string? engine);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;Landroid/speech/tts/TextToSpeech$OnInitListener;Ljava/lang/String;)V", "")>]
new Android.Speech.Tts.TextToSpeech : Android.Content.Context * Android.Speech.Tts.TextToSpeech.IOnInitListener * string -> Android.Speech.Tts.TextToSpeech

參數

context
Context

這個實例所處的情境。

listener
TextToSpeech.IOnInitListener

TextToSpeech.OnInitListener當 TextToSpeech 引擎初始化時,就會被呼叫。 若發生故障,監聽者可能會立即被呼叫,且在 TextToSpeech 實例尚未完全建構之前。

engine
String

TTS 引擎的套件名稱。

屬性

備註

TextToSpeech 類別的構造器,使用給定的 TTS 引擎。 如果 TextToSpeech 引擎還沒在運行,這也會初始化它。

Android 參考資料。android.speech.tts.TextToSpeech.TextToSpeech

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於