harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Ellison (JIRA)" <j...@apache.org>
Subject [jira] Closed: (HARMONY-1491) [classlib][beans] PropertyEditorSupport#setSource(null) throws NullPointerException
Date Tue, 19 Sep 2006 13:25:24 GMT
     [ http://issues.apache.org/jira/browse/HARMONY-1491?page=all ]

Tim Ellison closed HARMONY-1491.
--------------------------------

    Resolution: Fixed

Agreed resolution according to dev list.


> [classlib][beans] PropertyEditorSupport#setSource(null) throws NullPointerException
> -----------------------------------------------------------------------------------
>
>                 Key: HARMONY-1491
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1491
>             Project: Harmony
>          Issue Type: Improvement
>          Components: Non-bug differences from RI
>         Environment: winXP
>            Reporter: Alexei Zakharov
>
> The RI has inconsistent behavior in PropertyEditorSupport. There are two ways of specifying
the source of the generated events in PropertyEditorSupport:
> 1) Pass the source object to the constructor
> 2) Pass it to the specialized setSource(Object) method
> If null is passed to the constructor (case 1) RI throws NullPointerException. If null
is passed to setSource(Object) (case 2) RI does nothing. It was decided in the list [1] that
we don't want to follow this inconsistent behavior and our implementation of setSource() also
throws NullPointerException if null is passed. One more argument for NullPointerException
is the following sentence from the java.beans package description:
> "Unless explicitly stated, null values or empty Strings are not valid parameters for
the methods in this package. You may expect to see exceptions if these parameters are used."
> [1] http://mail-archives.apache.org/mod_mbox/incubator-harmony-dev/200609.mbox/%3c6e47b64f0609130310n5b95e33dl6994d132abdba5a5@mail.gmail.com%3e

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message