name Attribute
Provides a name that uniquely identifies the grammar element. Optional.
<grammar name = "gramName" >
Remarks
The name attribute uniquely identifies a grammar element within a listen or dtmf element for the purpose of activation and deactivation. The use of the name attribute does not enable references to the rules of one inline grammar from another.
Example
The following code demonstrates the use of the name attribute.
<salt:grammar name="cities" xmlns="http://www.w3.org/2001/06/grammar" lang="en-US">
<grammar root="root" version="1.0" tag-format="semantics-ms/1.0">
<rule id="root">
<item repeat="0-1">from </item>
<ruleref name="#cities" />
</rule>
<rule id="cities">
<one-of>
<item> Cambridge </item>
<item> Seattle </item>
<item> London </item>
</one-of>
</rule>
</grammar>
</salt:grammar>