SpeechHypothesizedEventArgs Класс

Определение

Возвращает уведомление из SpeechHypothesized или SpeechHypothesized событий.

Этот класс поддерживает инфраструктуру .NET Framework и не предназначен для использования непосредственно из кода приложения.

public ref class SpeechHypothesizedEventArgs : System::Speech::Recognition::RecognitionEventArgs
public class SpeechHypothesizedEventArgs : System.Speech.Recognition.RecognitionEventArgs
[System.Serializable]
public class SpeechHypothesizedEventArgs : System.Speech.Recognition.RecognitionEventArgs
type SpeechHypothesizedEventArgs = class
    inherit RecognitionEventArgs
[<System.Serializable>]
type SpeechHypothesizedEventArgs = class
    inherit RecognitionEventArgs
Public Class SpeechHypothesizedEventArgs
Inherits RecognitionEventArgs
Наследование
SpeechHypothesizedEventArgs
Атрибуты

Примеры

В приведенном ниже примере создается обработчик для SpeechRecognizer.SpeechHypothesized событий или SpeechRecognitionEngine.SpeechHypothesized событий. Обработчик использует экземпляр SpeechHypothesizedEventArgs возвращаемой и отображаемой информации о предварительно распознанной фразе.

// Create a handler for the SpeechHypothesized event.
recognizer.SpeechHypothesized += new EventHandler<SpeechHypothesizedEventArgs>(recognizer_SpeechHypothesized);

// Handle the event and display the hypothesized result.
void recognizer_SpeechHypothesized (object sender, SpeechHypothesizedEventArgs e)
  {
    Console.WriteLine("Hypothesized text: " + e.Result.Text);
  }

Комментарии

Событие SpeechHypothesized вызывается классами и SpeechRecognitionEngine классамиSpeechRecognizer.

Подробные сведения о предварительно распознанной фразе можно получить с помощью Result свойства.

Многочисленные SpeechHypothesized события создаются в качестве обработчика распознавания, пытающегося определить входную фразу. Как правило, обработка этих событий полезна только для отладки.

SpeechHypothesizedEventArgs является производным от RecognitionEventArgs.

Свойства

Имя Описание
Result

Возвращает данные результатов распознавания, связанные с событием распознавания речи.

(Унаследовано от RecognitionEventArgs)

Методы

Имя Описание
Equals(Object)

Определяет, равен ли указанный объект текущему объекту.

(Унаследовано от Object)
GetHashCode()

Служит хэш-функцией по умолчанию.

(Унаследовано от Object)
GetType()

Возвращает Type текущего экземпляра.

(Унаследовано от Object)
MemberwiseClone()

Создает неглубокую копию текущей Object.

(Унаследовано от Object)
ToString()

Возвращает строку, представляющую текущий объект.

(Унаследовано от Object)

Применяется к

См. также раздел