Is it possible using the Javascript API to create a "model" – something like Map root = new HashMap(), that can be processed against a Freemarker template – processTemplate? I want to do this within a behavior, not as part of a web script. I want to calculate some values in the javascript and then pass them to a Freemarker template – something like var result = mygeneratedmodel.processTemplate(mytemplate).