velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sebastien Chassande-Barrioz <>
Subject Re: macros in other templates
Date Sat, 09 Mar 2002 14:56:07 GMT
> I assume you meant #parse("file1.vm"), and yes, that doesn't work.

yes, sorry for my mistake

> The reason is that #parse() is a 'run-time' thing, and the decision of
> resolving #writeImports() to be VM is a 'parse-time' thing.

ok, I understand.

> Yes - there is a feature called Velocimacro libraries, in which you 
> can define lots of VMs, and they are accessible to all other 
> templates.
> See the docs on how to configure Velocity to load the libraries on 
> startup.

What does contain the velocimacro.library properties ?
A comma list of directories where to find .vm files or a comma list of 
.vm files ?

Is this (my) initialization is compatible with the velocimacro feature:

VelocityEngine ve = new VelocityEngine();
ve.setProperty( VelocityEngine.RUNTIME_LOG_LOGSYSTEM, this);
ve.setProperty( "velocimacro.library", "/src/templates/file2.vm");

Is it possible to specify the velocimacro property by this way ?

Chassande-Barrioz Sebastien
INRIALPES - SIRAC/SARDES Team - ObjectWeb initiative
Mail job :
Phone :

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message