语言

BluetoothHeadset.StopVoiceRecognition(BluetoothDevice) 方法

定义

停止蓝牙语音识别模式,并关闭蓝牙音频路径。

[Android.Runtime.Register("stopVoiceRecognition", "(Landroid/bluetooth/BluetoothDevice;)Z", "")]
[Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")]
public bool StopVoiceRecognition(Android.Bluetooth.BluetoothDevice? device);
[<Android.Runtime.Register("stopVoiceRecognition", "(Landroid/bluetooth/BluetoothDevice;)Z", "")>]
[<Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")>]
member this.StopVoiceRecognition : Android.Bluetooth.BluetoothDevice -> bool

参数

device
BluetoothDevice

蓝牙耳机

返回

如果未连接耳机,或者语音识别尚未启动,或者语音识别已在此头戴显示设备或错误处结束,则为 false;否则为 true

特性

注解

停止蓝牙语音识别模式,并关闭蓝牙音频路径。

用户可以侦 #ACTION_AUDIO_STATE_CHANGED听 。 如果此函数返回 true,则此意向将广播 #EXTRA_STATE 并设置为 #STATE_AUDIO_DISCONNECTED。

Java文档android.bluetooth.BluetoothHeadset.stopVoiceRecognition(android.bluetooth.BluetoothDevice)。

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于