velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sebastien Chassande-Barrioz <sebastien.chassa...@inrialpes.fr>
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");
ve.init();

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


Seb
-- 
Chassande-Barrioz Sebastien
INRIALPES - SIRAC/SARDES Team - ObjectWeb initiative
Mail job : sebastien.chassande@inrialpes.fr
Phone : 04.76.61.55.16


--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message