velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jarkko Viinamäki <jarjarli...@gmail.com>
Subject Re: WebappResourceLoader: ResourceNotFoundException
Date Mon, 19 Jan 2009 18:23:37 GMT

Hi,

I haven't really verified this but according to JavaDoc VelocityEngine.init
will initialize the engine with default settings (which overrides the
settings that you pass to the constructor). If you pass a Properties object
to the constructor, velocity is already initialized and there's no need to
call init anymore. Another way is to call the empty constructor and then
pass the properties to the init method.

http://velocity.apache.org/engine/releases/velocity-1.6.1/apidocs/org/apache/velocity/app/VelocityEngine.html


lacco wrote:
> 
> VelocityEngine ve = new VelocityEngine(props);
> ve.init();
> Template t = ve.getTemplate( "my.template.vm" );
> 

-- 
View this message in context: http://www.nabble.com/WebappResourceLoader%3A-ResourceNotFoundException-tp21548077p21548631.html
Sent from the Velocity - User mailing list archive at Nabble.com.


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


Mime
View raw message