Return-Path: Delivered-To: apmail-incubator-cxf-dev-archive@locus.apache.org Received: (qmail 74466 invoked from network); 3 Apr 2007 21:10:41 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 Apr 2007 21:10:41 -0000 Received: (qmail 41435 invoked by uid 500); 3 Apr 2007 21:10:47 -0000 Delivered-To: apmail-incubator-cxf-dev-archive@incubator.apache.org Received: (qmail 41398 invoked by uid 500); 3 Apr 2007 21:10:47 -0000 Mailing-List: contact cxf-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cxf-dev@incubator.apache.org Delivered-To: mailing list cxf-dev@incubator.apache.org Received: (qmail 41384 invoked by uid 99); 3 Apr 2007 21:10:47 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2007 14:10:47 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of polar.humenn@iona.com designates 65.223.216.181 as permitted sender) Received: from [65.223.216.181] (HELO amereast-smg1.iona.com) (65.223.216.181) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2007 14:10:40 -0700 Received: from amer-ems1.IONAGLOBAL.COM ([10.65.6.25]) by amereast-smg1.iona.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id l33L8uMs006639 for ; Tue, 3 Apr 2007 17:08:56 -0400 (EDT) Received: from [10.59.0.24] ([10.59.0.24]) by amer-ems1.IONAGLOBAL.COM with Microsoft SMTPSVC(6.0.3790.1830); Tue, 3 Apr 2007 17:10:18 -0400 Message-ID: <4612C2C3.7020102@iona.com> Date: Tue, 03 Apr 2007 17:10:27 -0400 From: Polar Humenn User-Agent: Thunderbird 1.5.0.10 (X11/20070306) MIME-Version: 1.0 To: cxf-dev@incubator.apache.org Subject: Checkstyle Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 03 Apr 2007 21:10:18.0284 (UTC) FILETIME=[7B542EC0:01C77634] X-Virus-Checked: Checked by ClamAV on apache.org Is there a "good" motivation of why "abstract" classes have to be named "Abstract" "Base" or "Factory"? If a class is declared "abstract", I want the *compiler* to tell the developer that s/he has not filled out a particular functionality when s/he extends the abstract class. Not that I want it named "Abstract". For example, abstract class Muffin { ...... abstract Kind kind(); } I really don't want my code littered with method definitions like: void eat(AbstractMuffin muff) { I want it to be: void eat(Muffin muff); because that's what it is. It's not an AbstractMuffin, it's a Muffin! Can we get rid of that particular checkstyle rule? I say that, because it forces, either a) illogical names, like AbstractMuffin, to be used in definitions, making for awkwardness. (i.e. eat(AbstractMuffin muff); b) default implementations, just to avoid the illogical names! This particular avoidance causes errors to be caught at run time instead of compile time, where it should be caught! And sometimes causing a loss of time to find it. For example, with the current checkstyle rule I could be forced to write the class with a default implementation expecting it to be overridden. (Except there is no way to tell a compiler that). class Muffin { ..... Kind kind() { return Kind.BLUEBERRY; } } void eat(Muffin muff) { System.out.println("I'm eating a " + muff.kind() + " muffin!"); } and a developer goes ahead and writes: class CornMuffin extends Muffin { Kind kiend() { return Kind.CORN; } } and it compiles fine without problems. Subsequently he can't figure out why his application still says he has a BLUEBERRY muffin, especially when he has used "eat(new CornMuffin())". This kind of pattern complete adverted the use of compiler protections. Cheers, -Polar