commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1567759 - in /commons/proper/collections/trunk/src: changes/changes.xml main/java/org/apache/commons/collections4/ComparatorUtils.java
Date Wed, 12 Feb 2014 21:17:41 GMT
Author: tn
Date: Wed Feb 12 21:17:41 2014
New Revision: 1567759

URL: http://svn.apache.org/r1567759
Log:
[COLLECTIONS-507] Removed wrong type bounds for ComparatorUtils.chainedComparator. Thanks
to Gerson.

Modified:
    commons/proper/collections/trunk/src/changes/changes.xml
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java

Modified: commons/proper/collections/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1567759&r1=1567758&r2=1567759&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/changes/changes.xml (original)
+++ commons/proper/collections/trunk/src/changes/changes.xml Wed Feb 12 21:17:41 2014
@@ -22,6 +22,9 @@
   <body>
 
   <release version="4.0.1" date="TBD" description="">
+    <action issue="COLLECTIONS-507" dev="tn" type="fix" due-to="Gerson">
+      Removed wrong type bounds for "ComparatorUtils#chainedComparator(...)".
+    </action>
     <action issue="COLLECTIONS-506" dev="tn" type="fix" due-to="Anthony Communier">
       Added javadoc clarification to class "CollectionUtils" that input objects which
       override "Object#equals(Object)" must also maintain the general contract of

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java?rev=1567759&r1=1567758&r2=1567759&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ComparatorUtils.java
Wed Feb 12 21:17:41 2014
@@ -74,9 +74,7 @@ public class ComparatorUtils {
      * @throws NullPointerException if comparators array is null or contains a null
      * @see ComparatorChain
      */
-    public static <E extends Comparable<? super E>> Comparator<E> chainedComparator(
-            final Comparator<E>... comparators) {
-
+    public static <E> Comparator<E> chainedComparator(final Comparator<E>...
comparators) {
         final ComparatorChain<E> chain = new ComparatorChain<E>();
         for (final Comparator<E> comparator : comparators) {
             if (comparator == null) {
@@ -100,9 +98,7 @@ public class ComparatorUtils {
      * @see ComparatorChain
      */
     @SuppressWarnings("unchecked")
-    public static <E extends Comparable<? super E>> Comparator<E> chainedComparator(
-            final Collection<Comparator<E>> comparators) {
-
+    public static <E> Comparator<E> chainedComparator(final Collection<Comparator<E>>
comparators) {
         return chainedComparator(
             (Comparator<E>[]) comparators.toArray(new Comparator[comparators.size()])
         );



Mime
View raw message