velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ChadDavis <chadmichaelda...@gmail.com>
Subject Re: continue processing templates after resource not found?
Date Fri, 28 Aug 2009 20:42:25 GMT
Okay.  I can answer my first question and pose another.

> If a template contains a parse directive that results in a resource
> not found, the whole thing blows up.  Is there a configuration setting
> that would allow the processing to continue, perhaps just writing a
> message in line.  I see that the #include directive can insert a
> message into the stream and keep going; how can I do this with #parse?

The answer is that the #include directive doesn't actually handle
missing resources, or appears not to.  I wonder what kind of problems
it does handle?

I'm now using the org.apache.velocity.app.event.implement.IncludeNotFound
event handler.  This works great.  But . . .

I now would like to be able to have access to the name of the missing
resource so i can inline it into the notfound.vm template that takes
over when the resource is not found.  Is this information in the
context ?

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


Mime
View raw message