[stringtemplate-interest] problem parsing template 'anonymous'
Tuan.Le2 at AlconLabs.com
Tuan.Le2 at AlconLabs.com
Wed Sep 13 07:48:55 PDT 2006
Hi,
Obviously, I'm missing or not using StringTemplate API correctly. I
followed the exact code in the StringTemplate example code, but I
couldn't get it to work because of the parsing problem.
Could you please give me a hint?
Thanks,
Tuan
________________________________
From: Le,Tuan,IRVINE,IT
Sent: Tuesday, September 12, 2006 4:41 PM
To: 'stringtemplate-interest at antlr.org'
Subject: problem parsing template 'anonymous'
Hi,
I'm using StringTemplate 3.0b4. It threw a parsing exception when
intializing the StringTemplate. Do you know what I'm missing?
StringTemplate t = new StringTemplate("$fromAddress$",
DefaultTemplateLexer.class);
t.setAttribute("fromAddress", "myname at xyz.com
<mailto:myname at xyz.com> " );
Source breakpoint occurred at line 62 of ManualEmailAction.java.
06/09/12 16:34:16 problem parsing template 'anonymous'
06/09/12 16:34:16 java.lang.NullPointerException
06/09/12 16:34:16 at java.lang.Class.forName0(Native Method)
06/09/12 16:34:16 at java.lang.Class.forName(Class.java:164)
06/09/12 16:34:16 at
antlr.CharScanner.setTokenObjectClass(CharScanner.java:337)
06/09/12 16:34:16 at
org.antlr.stringtemplate.StringTemplate.breakTemplateIntoChunks(StringTe
mplate.java:929)
06/09/12 16:34:16 at
org.antlr.stringtemplate.StringTemplate.setTemplate(StringTemplate.java:
532)
06/09/12 16:34:16 at
org.antlr.stringtemplate.StringTemplate.<init>(StringTemplate.java:380)
06/09/12 16:34:16 at
com.alcon.ezra.action.ManualEmailAction.initFormBean(ManualEmailAction.j
ava:68)
06/09/12 16:34:16 at
com.alcon.ezra.action.ManualEmailAction.doExecute(ManualEmailAction.java
:51)
Thanks,
Tuan
This e-mail (including any attachments) is confidential and may be legally privileged. If you are not an intended recipient or an authorized representative of an intended recipient, you are prohibited from using, copying or distributing the information in this e-mail or its attachments. If you have received this e-mail in error, please notify the sender immediately by return e-mail and delete all copies of this message and any attachments.
Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org:8080/pipermail/stringtemplate-interest/attachments/20060913/6fe8112a/attachment.html
More information about the stringtemplate-interest
mailing list