Return-Path: Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: (qmail 96589 invoked from network); 25 Jan 2006 15:51:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 25 Jan 2006 15:51:37 -0000 Received: (qmail 27237 invoked by uid 500); 25 Jan 2006 15:51:35 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 27203 invoked by uid 500); 25 Jan 2006 15:51:34 -0000 Mailing-List: contact dev-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Development" Delivered-To: mailing list dev@myfaces.apache.org Received: (qmail 27192 invoked by uid 99); 25 Jan 2006 15:51:34 -0000 X-ASF-Spam-Status: No, hits=1.3 required=10.0 tests=SPF_FAIL X-Spam-Check-By: apache.org Received: from [192.87.106.226] (HELO ajax.apache.org) (192.87.106.226) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jan 2006 07:51:32 -0800 Received: from ajax.apache.org (ajax.apache.org [127.0.0.1]) by ajax.apache.org (Postfix) with ESMTP id 3AE38E1 for ; Wed, 25 Jan 2006 16:51:11 +0100 (CET) Message-ID: <2106874313.1138204271239.JavaMail.jira@ajax.apache.org> Date: Wed, 25 Jan 2006 16:51:11 +0100 (CET) From: "Christophe Jolif (JIRA)" To: dev@myfaces.apache.org Subject: [jira] Commented: (MYFACES-458) javax.faces.component._ComponentAttributesMap implementation not correct In-Reply-To: <1163163783.1125355266275.JavaMail.jira@ajax.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/MYFACES-458?page=comments#action_12363969 ] Christophe Jolif commented on MYFACES-458: ------------------------------------------ Hi Martin, Indeed the javadoc says: "Any attempt to add a null key or value must throw a NullPointerException." But on the other hand: 1/ the JSF specification doesn't talk about that 2/ the javadoc of the put method also says: "If the property is not writeable, or an attempt is made to set a property of primitive type to null, throw IllegalArgumentException." which sounds to me as if it implies that null on non primitive types is accepted. 3/ the RI accepts null 4/ setters accept null Thus, my understanding would be that you cannot add a new pair with null key (*add*, i.e. put without previous key), but you can put a previously set value back to null. Did you check with the JSR if is it not a javadoc that is just unclear? Indeed we have code failing because of this "fix" in MyFaces. Thanks. > javax.faces.component._ComponentAttributesMap implementation not correct > ------------------------------------------------------------------------ > > Key: MYFACES-458 > URL: http://issues.apache.org/jira/browse/MYFACES-458 > Project: MyFaces > Type: Bug > Components: JSR-127 > Reporter: Oliver Rossmueller > Assignee: Martin Marinschek > Fix For: 1.1.0 > > according the UIComponent.getAttributes javadoc the Map implementation returned by this method for any attempt to add a null key or value must throw a NullPointerException > The current implementation is correct for null keys but not does not check for null values. -- 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