Bug 38193 - [RDC] BuiltIn Grammar support for Field
Summary: [RDC] BuiltIn Grammar support for Field
Status: ASSIGNED
Alias: None
Product: Taglibs
Classification: Unclassified
Component: RDC Taglib (show other bugs)
Version: unspecified
Hardware: All other
: P2 enhancement (vote)
Target Milestone: ---
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-09 11:35 UTC by Aravilli Srinivasa Rao
Modified: 2006-02-09 15:30 UTC (History)
1 user (show)



Attachments
Attached the source files which are required for this tag (18.72 KB, application/x-zip-compressed)
2006-01-09 11:46 UTC, Aravilli Srinivasa Rao
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aravilli Srinivasa Rao 2006-01-09 11:35:51 UTC
There is no built in grammar support for field in RDC Tags. RDC should support 
the builtin grammar like  
<field name="PNR" type="digits?minlength=3;maxlength=3;length=3">
Comment 1 Aravilli Srinivasa Rao 2006-01-09 11:44:04 UTC
I have added a new tag to support the builtin grammar in VoiceXML.

new Tag rdc:builtinGrammar>

Usage 

<rdc:builtinGrammar id="test" type="digits?minlength=1;maxlength=3; />
<rdc:builtinGrammar id="ticket_num" type="digits" />
<rdc:builtinGrammar id="testfield" type="boolean?y=7;n=9" />

The following files are added/modified in order to support the new tag

META-INF\tags\rdc\builtinGrammar.tag
META-INF\tags\rdc\builtinGrammar.rdc
META-INF\tags\rdc\config\builtinGrammar.xml
org\apache\taglibs\rdc\BuiltinGrammar.java
builtInGrammar-test.jsp    // to test using the VXML
builtin-test-xml.jsp	   //  to test using the Browser


META-INF\tags\rdc\fsm-input.tag
META-INF\talib.tld
org\apache\taglibs\rdc\core\BaseModel.java
org\apache\taglibs\rdc\resources\RDCBundle.properties
org\apache\taglibs\rdc\resources\RDCBundle_en_US.properties

Comment 2 Aravilli Srinivasa Rao 2006-01-09 11:46:24 UTC
Created attachment 17370 [details]
Attached the source files which are required for this tag
Comment 3 Aravilli Srinivasa Rao 2006-01-09 11:49:48 UTC
Modified and Tested with the latest code i.e 02-JAN-2006.
Comment 4 Rahul Akolkar 2006-01-09 17:00:04 UTC
Thanks, I'll take a look at this within the next couple of days.

Please leave ticket Assigned To: taglibs-dev@j.a.o

Comment 5 Rahul Akolkar 2006-01-09 17:07:38 UTC
Re-assigning correctly to taglibs-dev.
Comment 6 Rahul Akolkar 2006-02-07 08:20:20 UTC
This looks good, we should make a couple of changes:

1) "type" property doesn't belong in BaseModel, we should add it to 
BuiltinGrammar.java

2) The config file is fictitious and cannot be used. I suggest having a 
majorType property in BuiltinGrammar.java and using it in the config file. So 
the majorType for type "digits?minlength=1;maxlength=3" will be "digits", and 
the prompt can then read "Please specify the #{model.majorType}" -- which, in 
this case, will become "Please specify the digits".
Comment 7 Aravilli Srinivasa Rao 2006-02-07 12:01:32 UTC
Please make the required changes and include the tag in the next release.
Comment 8 Rahul Akolkar 2006-02-10 00:30:41 UTC
(In reply to comment #7)
> Please make the required changes and include the tag in the next release.

I intend to do that. Ofcourse, feel free to revise the patch yourself (if not, 
I'll take another look at this come time for 1.1).