Eelco Hillenius wrote:
The whitespace issue and the taglibs seem like a good idea. I make extensive
use of the Velocity Tools sub project. If I wanted to migrate from Velocity
(that, I must say, I have been using for years without any real complaints)
to Freemarker, should I re-implement those tools as custom tags, or do you
have other means of getting the 'pull' functionality?

well, in general, JSP taglibs are rather baroque and complicated, like everything else related to JSP. And typically, if you want to expose some functionality to the template, you would not roll it up as a JSP taglib. You would do exactly what you do in Velocity. You would either put an object (i.e. a tool) in the context or write a macro in FTL (FreeMarker template language). Which approach you took would depend on the case at hand.


The reason we introduced JSP taglib support was so that third-party JSP taglibs such as CeWolf and SiteMesh and things like that would also be available from FreeMarker templates.

As for the Velocity Tools subproject, my take on things is that it largely came into existence as a set of workarounds for limitations that existed in the core template engine. Velocity development came to a standstill at least a year ago, and probably things that normally might have been added to Velocity itself were put in a tools project. Now, FreeMarker has no separate "tools" subproject. If something is deemed to be generally useful, it's just added to the main distribution.

So, in other words, I don't know what these separate "tools" do, but you might find that the functionality that you use these tools for is already in the FreeMarker core. I can only speculate on that, you'd have to tell me what functionality it is that you're getting from velocity-tools.

Aside from that, the tools are, I assume, for the most part, just javabeans you stick in the context. You could probably use them with FreeMarker!

I hope that answers your question.

Best Regards,

Jonathan Revusky
--
lead developer, FreeMarker project, http://freemarker.org/
Velocity-FreeMarker template conversion tool: http://freemarker.org/usCavalry.html




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to