2008-06-11 18:56:53 UTC
Unfortunately the syntax for templates is not as clean as it should be. But there are plenty of examples.
The users guide is pretty thorough:
http://fdsapi.sourceforge.net/htmldocs/TemplateUsersGuide.htm
Templates can be created from files, strings or simply by calling methods on the Template API. Also, if you want to use an existing template as your starting point, simpy call Template myTemplate=template.copy();
The templates class has examples of all out of the box templates. This class uses Strings to generate the templates, but the data could just as easily be put in a file.
Scroll, down to line 157 and you will see how they are defined. Note how small most of them are.
http://fdsapi.cvs.sourceforge.net/fdsapi/fdsapi/Code/com/fdsapi/Templates.java?revision=1.8&view=markup