VoxML 1.0 Element Reference

RENAME Element

RENAME Element

The RENAME element is used to rename recognition slots in VoxML grammars, such that the resulting VoxML variable name can be different from the name of the recognition slot defined in the grammar.

The RENAME element can exist only within the INPUT element, and then only when using the GRAMMAR input type.

Syntax

<RENAME RECNAME="value" VARNAME="value" />

Attributes

Attribute Name

Allowed Values

VARNAMEidentifier

RECNAMEidentifier

Examples

1 <INPUT TYPE="GRAMMAR"

2SRC="http://www.foo.com/mygram.grm"

3NEXT="http://www.fancyquotes.com/vmlstocks.asp">

4<RENAME VARNAME="sym" RECNAME="symbol">

5<RENAME VARNAME="detail" RECNAME="quotetype">

6</INPUT>

In this example, the RENAME element is used to account for differences in the variable names collected from a grammar and those expected by another script. In particular, the case imagined here is one where a grammar from foo.com is used to provide input to a VoxML application hosted by fancyquotes.com. Because the grammar and script are imagined to have been developed independently, the RENAME element is used to help connect the grammar and the stock-quoting application.

October 1998

VoxML 1.0 Language Reference 41

Page 45
Image 45
Motorola 1 manual Rename Element