openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r439548 - /incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java
Date Sat, 02 Sep 2006 06:17:07 GMT
Author: skim
Date: Fri Sep  1 23:17:06 2006
New Revision: 439548

URL: http://svn.apache.org/viewvc?rev=439548&view=rev
Log:
bug in ordering

Modified:
    incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java

Modified: incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java
URL: http://svn.apache.org/viewvc/incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java?rev=439548&r1=439547&r2=439548&view=diff
==============================================================================
--- incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java
(original)
+++ incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/meta/InheritanceComparator.java
Fri Sep  1 23:17:06 2006
@@ -22,7 +22,7 @@
  *
  * @author Abe White
  */
-class InheritanceComparator
+public class InheritanceComparator
     implements Comparator {
 
     private Class _base = Object.class;
@@ -64,9 +64,9 @@
         int i2 = levels(c2);
         if (i1 == i2) {
             // sort simple interfaces as well as simple order test will fail.
-            if (c1.isAssignableFrom(o2.getClass()))
+            if (c1.isAssignableFrom(c2))
                 return -1;
-            if (c2.isAssignableFrom(o1.getClass()))
+            if (c2.isAssignableFrom(c1))
                 return 1;
             return c1.getName().compareTo(c2.getName());
         }



Mime
View raw message