Return-Path: Delivered-To: apmail-commons-commits-archive@locus.apache.org Received: (qmail 14442 invoked from network); 26 Oct 2007 06:14:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 26 Oct 2007 06:14:36 -0000 Received: (qmail 11068 invoked by uid 500); 26 Oct 2007 06:14:23 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 10644 invoked by uid 500); 26 Oct 2007 06:14:21 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 10635 invoked by uid 99); 26 Oct 2007 06:14:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Oct 2007 23:14:21 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Oct 2007 06:14:33 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 3CC2F1A983A; Thu, 25 Oct 2007 23:14:11 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r588536 - /commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java Date: Fri, 26 Oct 2007 06:14:11 -0000 To: commits@commons.apache.org From: bayard@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20071026061411.3CC2F1A983A@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: bayard Date: Thu Oct 25 23:14:10 2007 New Revision: 588536 URL: http://svn.apache.org/viewvc?rev=588536&view=rev Log: Applying the javadoc sample usage change from LANG-353 as reported by Christoph Kutzinski Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java?rev=588536&r1=588535&r2=588536&view=diff ============================================================================== --- commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java (original) +++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/builder/EqualsBuilder.java Thu Oct 25 23:14:10 2007 @@ -46,11 +46,10 @@ *

Typical use for the code is as follows:

*
  * public boolean equals(Object obj) {
- *   if (obj instanceof MyClass == false) {
+ *   if (obj == null) { return false; }
+ *   if (obj == this) { return true; }
+ *   if (obj.getClass() == getClass()) {
  *     return false;
- *   }
- *   if (this == obj) {
- *     return true;
  *   }
  *   MyClass rhs = (MyClass) obj;
  *   return new EqualsBuilder()