Return-Path: Delivered-To: apmail-myfaces-users-archive@www.apache.org Received: (qmail 5866 invoked from network); 7 Jul 2007 18:55:08 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 7 Jul 2007 18:55:08 -0000 Received: (qmail 26364 invoked by uid 500); 7 Jul 2007 18:55:07 -0000 Delivered-To: apmail-myfaces-users-archive@myfaces.apache.org Received: (qmail 26323 invoked by uid 500); 7 Jul 2007 18:55:06 -0000 Mailing-List: contact users-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Discussion" Delivered-To: mailing list users@myfaces.apache.org Received: (qmail 26312 invoked by uid 99); 7 Jul 2007 18:55:06 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Jul 2007 11:55:06 -0700 X-ASF-Spam-Status: No, hits=0.3 required=10.0 tests=MAILTO_TO_SPAM_ADDR,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of andrew.rw.robinson@gmail.com designates 209.85.132.245 as permitted sender) Received: from [209.85.132.245] (HELO an-out-0708.google.com) (209.85.132.245) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Jul 2007 11:55:02 -0700 Received: by an-out-0708.google.com with SMTP id c3so130972ana for ; Sat, 07 Jul 2007 11:54:41 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=K5IfT8cNTWoiREFIO3QDi/qfbQ7aaA+gNtSsoACQmFRVDGOUyM5UxlAm30TpvdYqA4Lm2Rb54NyRem5/XeQt9fNPcknOLsw8RG5t8jQ9FtmHGp6uu3hO8HHI6rAeNW3uixCdPerfZB7rlYKoDRAP7w8U1WRGVU1rfyJSHko/GQA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ttKJbEb2pXQSFUYDz5KIQoSpU/cYVckizzyvLIpsyEm+PwtHKRDD/iZ2O8NG73SYzcLQk91xIWd4f4WvCb2OV3zkaslVStdzdjNyktb2rstM2Pj6QX5WlVniLK9SVO/QV2KVEnhWucqapz3lvdAOeKi8+CT6WaRLEUJW5gAwAYY= Received: by 10.100.12.18 with SMTP id 18mr897773anl.1183834481742; Sat, 07 Jul 2007 11:54:41 -0700 (PDT) Received: by 10.100.191.4 with HTTP; Sat, 7 Jul 2007 11:54:41 -0700 (PDT) Message-ID: Date: Sat, 7 Jul 2007 12:54:41 -0600 From: "Andrew Robinson" To: "MyFaces Discussion" Subject: Re: ValueChangeListener challenges In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <11471319.post@talk.nabble.com> X-Virus-Checked: Checked by ClamAV on apache.org I you change a component's code and that component is reusable, then you will affect its behavior everywhere you use it. That was all I was saying. In terms of affecting the value change event for one component on a page, it wouldn't hurt anything that I am aware of. Most of the time valueChangeEvents are not used. On 7/7/07, Vladimir Isakovich wrote: > You've lost me. What you mean by 'Depends on who is listening for the > events'? I thought - #{myBean.someMethod} is. > Am I missing something? > > And there is no garantee from introducing a bug with any new code - this is > our life. Testing is always a part of dev. But how is it relevant to what > we're discussing? > > vlad > > > On 7/7/07, Andrew Robinson wrote: > > Depends on who is listening for the events. Can you guarantee that > > there will be no bugs in your code from doing this? > > > > On 7/6/07, Vladimir Isakovich wrote: > > > Andrew, > > > could you give me an example (use case) when I'm sending out a null > value, > > > then on submit get "" back, and there is any harm of stopping > > > valueChangeEvent from being fired. > > > > > > I can't come up with one. > > > > > > Sure, I may write some logic or a converter wraper in order to prevent > this > > > unwanted event, I just was pointing to the fact that I was expected this > > > from non altered framework. > > > > > > vlad > > > > > > On 7/6/07, Andrew Robinson wrote: > > > > null has a special meaning, and thus why null != "" in terms of > > > > UIInput. Null means that the value was not submitted at all. "" means > > > > the value was submitted with no value. Thus why you need to convert "" > > > > to null if that is what you wish. If the renderer converted "" to > > > > null, then there would never be an update of the model. > > > > > > > > If you want, write a chain converter or a converter wrapper that > > > > converts "" to null. > > > > > > > > It may look like: > > > > > > > > > > > > > > > > > > > > > > > > then you can first check for "" and convert it to null, and if not, > > > > delegate the check to the "inner converter" > > > > > > > > On 7/6/07, Vladimir Isakovich < ivlad10@gmail.com> wrote: > > > > > Although null and date are two separate issues, but I'm gettin the > > > picture. > > > > > I may create my own converters and attach them to all my fields as > I'm > > > > > pleased. But I'm trying to have some common services (if thay're > > > missing in > > > > > the framework) in a single place, well this may be arguable what's > > > better. > > > > > Sorry for annoyance, but still, why JSF would not check for nulls > for me > > > > > (you've pointed the right method to be changed). > > > > > > > > > > With the date conversion I'll postpone the issue, I have to spend > more > > > time > > > > > tracing it. > > > > > > > > > > vlad > > > > > > > > > > > > > >