Thanks, Christopher,

This has come up from time to time, and I figured it wouldn't hurt to add it in.

There is no caching.  Since the text is generated when the page is
rendered, the argument to #evaluate could change every time.  Hence
standard caching wouldn't work.  The performance of #evaluate() will
be very similar to Velocity.evaluate().

We could implement some other type of caching.  My feeling is that
#evaluate() will generally be used for short strings, so this is
probably not very important.

To Ahmed-- this isn't really opposed to your suggestions.  Start a
thread and discuss them.  For example-- what type of error reporting
are you looking for?

WILL

On 3/26/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Be curious if there are any comments.

Great! Many users have asked for such a feature, for
example when a string comes from a DB or internationalized
templates, etc.

In the past I solved this using a nicely wrapped tool,
which does exactly the same:
#macro( evaluate $param )$renderTool.eval($param)#end

Does your #evaluate directive implementation do some
AST caching of the string for performance improvement?


Most languages have such an "eval"-Functionality and
therefore there is no reason for Velocity missing it.

Maybe Ahmed did not manage to advocate Velocity to some
more projects, because the decision makers missed some
handy features ;) But I do agree with Ahmed on #5:
5. Better and simpler whitespace control for the output.

Cheers,
Christoph

P.S. It is like my other handy macro:
#macro( call $dummy )if($dummy)#end#end


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




--
Forio Business Simulations

Will Glass-Husain
[EMAIL PROTECTED]
www.forio.com

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

Reply via email to