[stringtemplate-interest] How to write a helper template/macro for common stuff in a template (i.e. model and controller independent)
Zenaan Harkness
zen at freedbms.net
Fri Jul 17 02:49:11 PDT 2009
On Fri, Jul 17, 2009 at 05:59:59PM +0930, Barrie Treloar wrote:
> > For my case, what I think I want is something like:
> > <[1..6]: {RETYPE [<it>] 0}>
> > where [1..6] creates a list on the fly for me of the values [1,2,3,4,5,6]
>
> Thanks for the suggestions, this prompted me to try
>
> <[1,2,3,4,5,6]: {RETYPE [<it>] 0<\n>}>
>
> which does what I want but not entirely sure its any better than
> pasting in the lines 6 times.
Better if you happen to want to change the numbers in the list, since
they're all in one place, not spread across 6 lines.
--
Homepage: www.SoulSound.net -- Free Australia: www.UPMART.org
Please respect the confidentiality of this email as sensibly warranted.
More information about the stringtemplate-interest
mailing list