Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 68271 invoked from network); 31 Jan 2008 01:12:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 31 Jan 2008 01:12:26 -0000 Received: (qmail 81277 invoked by uid 500); 31 Jan 2008 01:12:10 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 81266 invoked by uid 500); 31 Jan 2008 01:12:10 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 81255 invoked by uid 99); 31 Jan 2008 01:12:10 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 30 Jan 2008 17:12:10 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of clinton.begin@gmail.com designates 72.14.204.224 as permitted sender) Received: from [72.14.204.224] (HELO qb-out-0506.google.com) (72.14.204.224) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 31 Jan 2008 01:11:43 +0000 Received: by qb-out-0506.google.com with SMTP id a33so1725629qbd.0 for ; Wed, 30 Jan 2008 17:11:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:references:in-reply-to:subject:date:mime-version:content-type:content-transfer-encoding:x-mailer:thread-index:content-language:message-id; bh=0lmQLO7ZIGQfBWL0Ek2P7sS7Z4jfk5esv1BpgIamFsM=; b=Xl0ofdEnEgHBVQKSBQyo0zswDfzjr7ZHwJb3oQ5no6TVvqeaSja2gcwqM30lGH7CuuXHO8d9f9okyQX+XieyCLynihImdxcnGo2K1cgZWYFVFtb7wWTnUi36iM/Ik22RIxZdkwp5ZtGwYrP8jIrsxmVhHx6DOjEQ+41WPEDMzPw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:references:in-reply-to:subject:date:mime-version:content-type:content-transfer-encoding:x-mailer:thread-index:content-language:message-id; b=fISDrXqiVT6sOamrDKiUdXzlO9cqnxqe/DSYcl/6F24gCJzz8ZowwPAtXwzkAPC3LHM6IIa3+vlEJtdo6q74ZRXzVq4wtpedroKHA7HubX0TmgWsUN4I0HQlaxxnH4BeU8MBTcpBsSp/IE8KQUQdKWR2UGnTYvZdQhIgdduQ3dM= Received: by 10.114.204.7 with SMTP id b7mr1639702wag.124.1201741909372; Wed, 30 Jan 2008 17:11:49 -0800 (PST) Received: from DARKSTAR ( [24.66.203.119]) by mx.google.com with ESMTPS id l23sm3033244waf.5.2008.01.30.17.11.48 (version=SSLv3 cipher=OTHER); Wed, 30 Jan 2008 17:11:48 -0800 (PST) From: "Clinton Begin" To: , References: <1201716326.31524.1234151879@webmail.messagingengine.com> <2f55db670801301036l5f890babl37e8ec52aea7559d@mail.gmail.com> <1201719088.8102.1234163847@webmail.messagingengine.com> <47a0cd3e.1f588c0a.217e.ffffb5e1@mx.google.com> In-Reply-To: Subject: RE: Exit out of rowHandler Date: Wed, 30 Jan 2008 18:11:35 -0700 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: AchjmeE7KmlKhCZJQZqs20quc8xNogAC/eyA Content-Language: en-ca Message-ID: <47a12054.17bc720a.27d4.750b@mx.google.com> X-Virus-Checked: Checked by ClamAV on apache.org Hehe... Well, considering how much effort I've always put into iBATIS being backward compatible, why break tradition now? ;-) We can use an adapter and create a new RowHandler interface. iBATIS 3.0 can merge them into one...as it won't be fully backward compatible anyway. Clinton -----Original Message----- From: larry.meadors@gmail.com [mailto:larry.meadors@gmail.com] On Behalf Of Larry Meadors Sent: January-30-08 4:43 PM To: user-java@ibatis.apache.org Subject: Re: Exit out of rowHandler Meh, it'll break compatibility, but it adds a great deal of useful functionality for very little cost. In addition, the 'fix' is to add a "return true;" to existing code. I wouldn't consider that particularly onerous...unless you have like 1000 row handlers, in which case, you probably *deserve* some pain. ;-) I think it's a great idea. Larry On Jan 30, 2008 2:45 PM, Jeff Butler wrote: > I can't think of any other use for the return value, so I like the idea. > The only drawback is that this will break existing row handlers. This could > be an argument in favor of the two parameter approach - because it could be > an overloaded method. Of course, any change to the interface is going to > cause headaches for existing row handlers. Maybe we should provide adapter > classes like AWT? > > Did I just suggest using AWT as a model? > > Jeff Butler > > > > On Jan 30, 2008 1:17 PM, Clinton Begin wrote: > > > > > Hmmm... would it be horrible if the return value of handleRow() was a > > boolean for "continue"? > > > > // don't mind the verbosity or any misplaced > > // capital letters...thank you outlook > > public boolean handleRow (Object valueObject) { > > boolean continue = true; > > if (someCondition) { > > continue = false; > > } > > return continue; > > } > > > > I hate to suggest making use of the return value, because there is only > > one...but it isn't used right now. Is this the best use of the return > > value? The alternative is to use a second parameter for controls... > > > > public void handleRow (ResultSetControl control, Object valueObject) { > > if (someCondition) { > > control.setContinue(false); > > } > > } > > > > Sorry if this has already been discussed, it's more of a dev@ issue, but > > since we're talking about it here... > > > > Thoughts? > > > > Clinton > > > > > > > > >