avalon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: Cascading Configuration
Date Tue, 12 Feb 2002 20:07:36 GMT
On Tue, 12 Feb 2002 23:10, Torsten Curdt wrote:
> Wouldn't it make sense to also have a
>  class CascadingConfiguration extends AbstractConfiguration {
>    public CascadingConfiguration( Configuration conf ) {
>     ...
> So we can apply the same pattern as for the ComponentManager or the
> RoleManager? So you easily split configuration files...

I think there is two things here that you may be trying to do. One is to 
merge two Configuration trees (ie a tree of defaults and a tree of real 
values) and another may to be include one default tree in another tree.

So instead of altering configuration in any way it may be best to add a 
method like

Configuration mergedTree = ConfigurationUtil.merge( realTree, defaultsTree );

and use xinclude to do the including.



| The best defense against logic is ignorance. |

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

View raw message