This `how to' will emerge in the next four or five days (currently 10/3/04). It will describe how to code a template from scratch, using a text editor and Ant and the Nukes codebase.
Pitfalls
Be careful when choosing the context variable names. They must only contain dots if they are inside a loop. For ordinary names, IMG_LEFT is ok. IMG.LEFT is not.
This leads to something like
java.lang.IndexOutOfBoundsException: Index: 2, Size: 1 at java.util.LinkedList.entry(LinkedList.java:360) at java.util.LinkedList.get(LinkedList.java:303) at org.jboss.nukes.common.template.TemplateBuilder.generateRender(TemplateBuilder.java:174) at org.jboss.nukes.common.template.TemplateBuilder.implementRender(TemplateBuilder.java:119) at org.jboss.nukes.common.template.TemplateBuilder.build(TemplateBuilder.java:91) at org.jboss.nukes.common.template.TemplateRepository$TemplateClassLoader.addTemplate(TemplateRepository.java:157) at org.jboss.nukes.common.template.TemplateRepository.generate(TemplateRepository.java:118) at org.jboss.nukes.common.template.TemplateRepository.addTemplate(TemplateRepository.java:106) at org.jboss.nukes.common.template.TemplateRepository.addTemplate(TemplateRepository.java:96) ....
Comments