commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r1140582 - /commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java
Date Tue, 28 Jun 2011 13:13:10 GMT
Author: simonetripodi
Date: Tue Jun 28 13:13:10 2011
New Revision: 1140582

URL: http://svn.apache.org/viewvc?rev=1140582&view=rev
Log:
the comparator returns -1 even when the comparable are equals, easier inverting the compare
order

Modified:
    commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java

Modified: commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java
URL: http://svn.apache.org/viewvc/commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java?rev=1140582&r1=1140581&r2=1140582&view=diff
==============================================================================
--- commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java
(original)
+++ commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/coloring/GraphColoring.java
Tue Jun 28 13:13:10 2011
@@ -67,7 +67,7 @@ public final class GraphColoring
         {
             public int compare( Integer o1, Integer o2 )
             {
-                return o1.compareTo( o2 ) * -1;
+                return o2.compareTo( o1 );
             }
         } );
 



Mime
View raw message