cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jorg Heymans ...@domek.be>
Subject Re: Can not configure components by web.xml
Date Tue, 17 Feb 2004 11:52:43 GMT

> 
> It could simply be done by adding one line to the CocoonServlet in the 
> init(ServletConfig) method:
> 
> // conf is the ServletConfig in the init() method
> this.appContext.put("servletconfig", conf);
seems a simple enough change, but i understand that you don't want to do 
this for every new cocoon release.
> 
> This would fix all my problems. Then I could get the 'servletconfig' 
> from the ObjectModel.
> I currently created a ConfigurationServlet that has the configuration I 
> need in it's web.xml when my Transformator needs the configuration I do:
> 
> ConfigurationServlet configServlet = ConfigurationServlet.getInstance();
This seems to me also an acceptable solution. Why is it not beautiful 
enough? You're just working around a cocoon "limitation" in a very 
simple way - to me it's a KISS certified solution.
Maybe put a configuration interface in between that abstracts the fact 
you're pulling values from a configuration servlet, just to beautify it ;)


Jorg


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message