I don't know if I'll have time to look at the patch today, but I'll get to it ASAP. See one comment below:

On Jun 6, 2006, at 7:28 AM, Antonio Petrelli wrote:


But I think that most of the time addDefinitions() will be called at servlet init time and many of the components in TilesContext will not be available. But there are already cases where that situation exists.

If there is no TilesContext, probably there would not be a Locale either (but I could miss something) and the non-locale definitions are read by DefinitionsFactory.readDefinitions(). I don't get the point...

That's probably true (no context == no locale), but in the servlet init phase we are processing definitions files that have locale information encoded into the filename (i.e. tiles-defs_en_US.xml). There we have a locale and a partial TilesContext, one with Servlet/ Portlet context info but not request info. I can think of a couple of places where TilesContext is used like this right now. Maybe it calls for a context interface that is used in the init phase and another more complete context interface that is used in the request phase but, personally, that would be more complicated than I want. You just have to be aware of your "context" when using TilesContext. Does that clear it up?

Again, I'll look at your patch. I think I'm in favor of what you are proposing. But the devil's in the details, right? :-)

Greg

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to