SpeechRecognizer.HypothesisGenerated 事件
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
当语音识别器返回识别结果片段时,在正在进行的听写会话期间发生。
// Register
event_token HypothesisGenerated(TypedEventHandler<SpeechRecognizer, SpeechRecognitionHypothesisGeneratedEventArgs const&> const& handler) const;
// Revoke with event_token
void HypothesisGenerated(event_token const* cookie) const;
// Revoke with event_revoker
SpeechRecognizer::HypothesisGenerated_revoker HypothesisGenerated(auto_revoke_t, TypedEventHandler<SpeechRecognizer, SpeechRecognitionHypothesisGeneratedEventArgs const&> const& handler) const;
public event TypedEventHandler<SpeechRecognizer,SpeechRecognitionHypothesisGeneratedEventArgs> HypothesisGenerated;
function onHypothesisGenerated(eventArgs) { /* Your code */ }
speechRecognizer.addEventListener("hypothesisgenerated", onHypothesisGenerated);
speechRecognizer.removeEventListener("hypothesisgenerated", onHypothesisGenerated);
- or -
speechRecognizer.onhypothesisgenerated = onHypothesisGenerated;
Public Custom Event HypothesisGenerated As TypedEventHandler(Of SpeechRecognizer, SpeechRecognitionHypothesisGeneratedEventArgs)
事件类型
注解
结果片段可用于证明语音识别在长时间听写会话期间正在处理输入。