[antlr-interest] String Template Questions
David Beckedorff
david.beckedorff at gmail.com
Fri Jun 6 13:20:59 PDT 2008
Q1.
I have a template hierarchy going, so
group WebAppSiLayer : FeatureBase ;
Now in my Java program, I have:
StringTemplateGroup featureBaseSTG =
StringTemplateGroup.loadGroup("FeatureBase");
featureBaseSTG.registerRenderer(Object.class, new StFormatRenderer());
…
StringTemplateGroup siLayerSTG =
StringTemplateGroup.loadGroup("WebAppSiLayer", featureBaseSTG);
siLayerSTG.registerRenderer(Object.class, new StFormatRenderer());
So the question is whether the second registration of my StFormatRenderer
class (implements AttributeRenderer) is actually necessary, since it has
already been registered with the super-template?
Q2.
In ANTLR's Java.stg file, there are, I guess, template interpolations like
<@imports>, <@end>, <@members>, <@preamble>, etc. What's the purpose of the
'@' characters? What's going on here?
Thanks,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080606/e8201193/attachment.html
More information about the antlr-interest
mailing list