At 10:46 PM 12/28/2005 +0100, you wrote:
>Oliver Heger wrote:
>> Agreed. We should try to restore compatibility to 1.0 in later releases
>> whereever possible.
>
>We could push a 1.2.1 release with the missing method in
>HierarchicalXMLConfiguration. I would just wait a couple weeks to gather
>more feedback about the latest release.
>

If you are going to do another release, please consider adding a configuration.subsets(String) method to return a list of subset configurations that match the string query. This corresponds to the configuration.subset(String) method that returns a single SubsetConfiguration. I mentioned this in a previous thread [1]. I hope it can be added in short order. I'm not sure whether returning a List or an Iterator would be best? In any case, I would use it like this (assuming, for now, that it returns a list)...

List subConfigs = config.subsets("tables.table");
for (Iterator iter = subConfigs.iterator(); iter.hasNext();) {
    SubsetConfiguration subConfig = (SubsetConfiguration) iter.next();
}

...where if I was only trying to get one subset configuration at a time, I might do...

SubsetConfiguration subConfig = (SubsetConfiguration) config.subset("tables.table(0)");

Of course, I always use the subset configuration in the context of a loop/iteration, since I need to deal with all of them (and where there may be any number "tables.table" entries in the XML), not just one at a time leading to the rather ugly while loop example I resorted to in the thread I referenced. Does this seem reasonable to add to the next release?

[1] - http://marc.theaimsgroup.com/?l=jakarta-commons-user&m=113528247017087&w=2


Jake

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

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

Reply via email to