Delen via


Note

Please see Azure Cognitive Services for Speech documentation for the latest supported speech solutions.

SrgsToken Class

Represents a word or short phrase that can be recognized.

Inheritance Hierarchy

System.Object
  System.MarshalByRefObject
    Microsoft.Speech.Recognition.SrgsGrammar.SrgsElement
      Microsoft.Speech.Recognition.SrgsGrammar.SrgsToken

Namespace:  Microsoft.Speech.Recognition.SrgsGrammar
Assembly:  Microsoft.Speech (in Microsoft.Speech.dll)

Syntax

'Declaration
<SerializableAttribute> _
Public NotInheritable Class SrgsToken _
    Inherits SrgsElement
'Usage
Dim instance As SrgsToken
[SerializableAttribute]
public sealed class SrgsToken : SrgsElement

Remarks

Using the members of the SrgsToken class, you can specify three forms of a word: the Display form, the Text form, and a custom Pronunciation for the word.

If multiple words are stored in a single SrgsToken object, each is treated as a different token internally and in the result.

This class represents the token element defined by the World Wide Web Consortium (W3C) Speech Recognition Grammar Specification (SRGS) Version 1.0.. For information about the SRGS token element and details about its support by the Microsoft Speech Platform SDK 11, see token Element (Microsoft.Speech).

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

SrgsToken Members

Microsoft.Speech.Recognition.SrgsGrammar Namespace