You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Emmanuel Bourg <eb...@micropole-univers.com> on 2004/06/16 20:06:18 UTC
[configuration] getProperties ?
I noticed the getProperties(String key, Properties defaultValue) method
is only defined in the AbstractConfiguration class, and not in the
Configuration interface. I didn't pay attention to this method before,
but what is the motivation for getProperties anyway? [configuration] is
supposed to provide a higher level replacement for the good old
java.util.Properties, so that seems a bit odd to return a Properties
here, returning a Configuration would be more appropriate.
Emmanuel Bourg
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
Re: [configuration] getProperties ?
Posted by Emmanuel Bourg <eb...@micropole-univers.com>.
Eric Pugh wrote:
> However, since it is only at the AbstractConfiguration level, I
> think delete it.
getProperties(String, Properties) is only defined in
AbstractConfiguration but getProperties(String) is defined in the
Configuration interface.
I guess getList and getProperties were added at the same time, one
method to operate on lists:
key = value1, value2, value3
and the other one to operate on maps:
key = key1=value1, key2=value2, key3=value3
I'd prefer renaming it to getConfiguration(String) rather than removing it.
Emmanuel Bourg
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
RE: [configuration] getProperties ?
Posted by Eric Pugh <ep...@upstate.com>.
I think maybe it is a laeft over method, or maybe something that was going
to be added to support
http://jakarta.apache.org/commons/collections/apidocs-COLLECTIONS_3_0/org/ap
ache/commons/collections/ExtendedProperties.html this class so it could be
removed.. However, since it is only at the AbstractConfiguration level, I
think delete it. This seems like a sort of special purpose method that
could be better placed in something like a PropertiesConfiguration or
PropertiesConfigurationUtil class...
Eric
> -----Original Message-----
> From: Emmanuel Bourg [mailto:ebourg@micropole-univers.com]
> Sent: Wednesday, June 16, 2004 8:06 PM
> To: Jakarta Commons Developers List
> Subject: [configuration] getProperties ?
>
>
> I noticed the getProperties(String key, Properties defaultValue) method
> is only defined in the AbstractConfiguration class, and not in the
> Configuration interface. I didn't pay attention to this method before,
> but what is the motivation for getProperties anyway? [configuration] is
> supposed to provide a higher level replacement for the good old
> java.util.Properties, so that seems a bit odd to return a Properties
> here, returning a Configuration would be more appropriate.
>
> Emmanuel Bourg
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org