SrgsItem Constructors
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the SrgsItem class.
SrgsItem() |
Initializes a new instance of the SrgsItem class. |
SrgsItem(Int32) |
Initializes a new instance of the SrgsItem class and specifies the number of times that its contents must be spoken. |
SrgsItem(SrgsElement[]) |
Initializes a new instance of the SrgsItem class and specifies an array of SrgsElement objects to add to this instance. |
SrgsItem(String) |
Initializes a new instance of the SrgsItem class and specifies its textual contents. |
SrgsItem(Int32, Int32) |
Initializes a new instance of the SrgsItem class and specifies minimum and maximum repetition counts. |
SrgsItem(Int32, Int32, SrgsElement[]) |
Initializes a new instance of the SrgsItem class, specifies an array of SrgsElement objects to add to this instance, and sets minimum and maximum repetition counts. |
SrgsItem(Int32, Int32, String) |
Initializes a new instance of the SrgsItem class, specifies the text associated with the item, and specifies minimum and maximum repetition counts. |
This overloaded constructor for SrgsItem initializes the object with a default repeatCount
property of 0.
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class.
public:
SrgsItem();
public SrgsItem ();
Public Sub New ()
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class and specifies the number of times that its contents must be spoken.
public:
SrgsItem(int repeatCount);
public SrgsItem (int repeatCount);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : int -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (repeatCount As Integer)
Parameters
- repeatCount
- Int32
The number of times that the item must be spoken.
Exceptions
repeatCount
is negative or is larger than 255.
Remarks
This constructor sets MaxRepeat and MinRepeat properties of the new SrgsItem to the value in repeatCount
.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class and specifies an array of SrgsElement objects to add to this instance.
public:
SrgsItem(... cli::array <System::Speech::Recognition::SrgsGrammar::SrgsElement ^> ^ elements);
public SrgsItem (params System.Speech.Recognition.SrgsGrammar.SrgsElement[] elements);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : System.Speech.Recognition.SrgsGrammar.SrgsElement[] -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (ParamArray elements As SrgsElement())
Parameters
- elements
- SrgsElement[]
The array of objects to add to the SrgsItem instance.
Exceptions
elements
is null
.
Any member of the elements
array is null
.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class and specifies its textual contents.
public:
SrgsItem(System::String ^ text);
public SrgsItem (string text);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : string -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (text As String)
Parameters
- text
- String
The text associated with the item.
Exceptions
text
is null
.
text
is an empty string.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class and specifies minimum and maximum repetition counts.
public:
SrgsItem(int min, int max);
public SrgsItem (int min, int max);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : int * int -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (min As Integer, max As Integer)
Parameters
- min
- Int32
The minimum number of times that the text in the item must be repeated.
- max
- Int32
The maximum number of times that the text in the item can be repeated.
Exceptions
min
is larger than max
.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class, specifies an array of SrgsElement objects to add to this instance, and sets minimum and maximum repetition counts.
public:
SrgsItem(int min, int max, ... cli::array <System::Speech::Recognition::SrgsGrammar::SrgsElement ^> ^ elements);
public SrgsItem (int min, int max, params System.Speech.Recognition.SrgsGrammar.SrgsElement[] elements);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : int * int * System.Speech.Recognition.SrgsGrammar.SrgsElement[] -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (min As Integer, max As Integer, ParamArray elements As SrgsElement())
Parameters
- elements
- SrgsElement[]
The array of objects to add to the SrgsItem instance.
Exceptions
elements
is null
.
Any member of the elements
array is null
.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
- Source:
- SrgsItem.cs
Initializes a new instance of the SrgsItem class, specifies the text associated with the item, and specifies minimum and maximum repetition counts.
public:
SrgsItem(int min, int max, System::String ^ text);
public SrgsItem (int min, int max, string text);
new System.Speech.Recognition.SrgsGrammar.SrgsItem : int * int * string -> System.Speech.Recognition.SrgsGrammar.SrgsItem
Public Sub New (min As Integer, max As Integer, text As String)
Parameters
- min
- Int32
The minimum number of times that the item must be repeated.
- max
- Int32
The maximum number of times that the item can be repeated.
- text
- String
The text associated with the item.
Exceptions
min
is larger than max
.
Applies to
.NET 9 (package-provided) en andere versies
Product | Versies |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
Feedback over .NET
.NET is een opensourceproject. Selecteer een koppeling om feedback te geven: