Re: Functions

Nathan Bubna <[email protected]> Thu, 19 Feb 2015 07:52:32 -0800
Newsgroups gmane.comp.jakarta.velocity.user
Message-ID <CAFyaDjFi7CY=46eKAuFGJdQXN-gr8pO3u3LaEcDx4iJEONYdZQ@mail.gmail.com>
(shaking his head)

please use a tool object, if at all possible. using macros as functions
gives me the willies. :)  they're meant to clean/simplify repetition of
content. just because they can be used as functions, doesn't mean they
should be. things can get ugly down that road. :)

On Thu, Feb 19, 2015 at 7:47 AM, <[email protected]> wrote:

> Ah, I never thought of using macros as methods/functions. Thanks.
>
> ----- Mail original -----
> De: "Erik Hatcher" <[email protected]>
> À: "Velocity Users List" <[email protected]>
> Envoyé: Jeudi 19 Février 2015 16:43:43
> Objet: Re: Functions
>
> You mean like the macros?  Since you’re in Solr-land, look at the
> VM_global_library.vm file and how those pieces are used.  (it’s a bit
> uglier than it should be in the Solr example macro library, but should give
> you some insight there).
>
>
> —
> Erik Hatcher, Senior Solutions Architect
> http://www.lucidworks.com <http://www.lucidworks.com/>
>
>
>
>
> > On Feb 19, 2015, at 10:22 AM, [email protected] wrote:
> >
> >
> > Is there a way to create dynamic methods/functions in Velocity Templates?
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [email protected]
> > For additional commands, e-mail: [email protected]
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>