[stringtemplate-interest] problem parsing template 'anonymous'

Tuan.Le2 at AlconLabs.com Tuan.Le2 at AlconLabs.com
Wed Sep 13 09:02:11 PDT 2006


Hi Terence -

Thanks for your response. I'm using Oracle Jdeveloper 10g. I searched
against antlr*.jar and I found that there were two older ANTLR jar files
in Jdeveloper directories 

C:\jdeveloper\jakarta-struts\lib
C:\jdeveloper\toplink\jlib

In my Web application lib directory (WEB-INF\lib) I have a new ANTLR jar
file which is antlr-2.7.7.jar. What is the best option to get this
working without interfering with the old antlr.jar that could be used by
other applications?

BTW, I'm using StringTemplate 3.0b4. Does that work with the older
verion of ANTLR or they are independent jar files?

Thanks,
Tuan



-----Original Message-----
From: stringtemplate-interest-bounces at antlr.org
[mailto:stringtemplate-interest-bounces at antlr.org] On Behalf Of Terence
Parr
Sent: Wednesday, September 13, 2006 8:23 AM
To: stringtemplate-interest
Subject: Re: [stringtemplate-interest] problem parsing template
'anonymous'

seems a classpath issue...old version of ANTLR in your path?
Ter
On Sep 13, 2006, at 7:48 AM, <Tuan.Le2 at AlconLabs.com> wrote:

> 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" );
>
>
> 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 
> (StringTemplate.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.java: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.
>
> _______________________________________________
> stringtemplate-interest mailing list
> stringtemplate-interest at antlr.org
> http://www.antlr.org:8080/mailman/listinfo/stringtemplate-interest

_______________________________________________
stringtemplate-interest mailing list
stringtemplate-interest at antlr.org
http://www.antlr.org:8080/mailman/listinfo/stringtemplate-interest


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.


More information about the stringtemplate-interest mailing list