On Jan 24, 2007, at 5:35 AM, Nicole Hochleiter wrote:

Hi,
I need to extend the PropertiesFileModule (in fact I already have implemented my own Version of the class and use it). But I wonder if the community would like
to have this extension in the project:
instead of only reading one file to one name I read several files which can
contain the same properties and the last one in the list is taken.

This is interesting e.g. if you have a default.properties and a local.properties file where in the default you can define the default values and if a local installation needs to add specific properties or only specific values this can
be configured in the local.properties which overwrite the default.

Hi Nicole,

In terms of the current code base, for overriding one properties file with another the most parsimonious solution is to instantiate a ChainMetaModule in cocoon.xconf. Declare it to chain two PropertiesFileModule instances — first the one for local.properties, then the one for default.properties. No new classes required :-)

But maybe it will be felt that supporting multiple properties files in a single output module is desirable — in that case, it might be better to just enhance PropertiesFileModule rather than add an additional class....?

cheers,
—ml—


Reply via email to