avalon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephen McConnell <mcconn...@apache.org>
Subject Re: [VOTE] DefaultConfiguration.setAttribute(String,<null>)
Date Wed, 10 Dec 2003 15:35:07 GMT


Niclas Hedhman wrote:

>On Wednesday 10 December 2003 22:35, Leo Sutic wrote:
>  
>
>>When DefaultConfiguration.setAttribute(key,value) is called with a null
>>as the value parameter, it should...
>>
>> 1. ...throw a NullPointerException.
>>
>> 2. ...throw an IllegalArgumentException.
>>
>> 3. ...act as if called with DefaultConfiguration.setAttribute( key, ""
>>).
>>       I.e. set the attribute to the empty string.
>>
>> 4. ...remove the attribute if it exists.
>>
>>My vote is for 4. Why? Because setValue(null) removes any existing
>>value from a DefaultConfiguration.
>>    
>>
>
>
>1. [   ]
>2. [   ]
>3. [   ]
>4. [ x ]
>
>Also, most folks are used to that behavior in HashMap.
>

dito

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

-- 

Stephen J. McConnell
mailto:mcconnell@apache.org

|------------------------------------------------|
| Magic by Merlin                                |
| Production by Avalon                           |
|                                                |
| http://avalon.apache.org/merlin                |
| http://dpml.net/                               |
|------------------------------------------------|





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


Mime
View raw message