commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1188396 - /commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java
Date Mon, 24 Oct 2011 21:40:18 GMT
Author: sebb
Date: Mon Oct 24 21:40:17 2011
New Revision: 1188396

URL: http://svn.apache.org/viewvc?rev=1188396&view=rev
Log:
Rename to avoid hiding super field

Modified:
    commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java

Modified: commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java
URL: http://svn.apache.org/viewvc/commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java?rev=1188396&r1=1188395&r2=1188396&view=diff
==============================================================================
--- commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java
(original)
+++ commons/proper/functor/trunk/src/main/java/org/apache/commons/functor/core/collection/FilteredIterable.java
Mon Oct 24 21:40:17 2011
@@ -102,18 +102,18 @@ public class FilteredIterable<T> impleme
 
     /**
      * Retain only elements matching <code>predicate</code>.
-     * @param predicate filter, non-<code>null</code>
+     * @param filter filter predicate, non-<code>null</code>
      * @return <code>this</code>, fluently
      */
-    public FilteredIterable<T> retain(UnaryPredicate<? super T> predicate) {
-        if (predicate == null) {
+    public FilteredIterable<T> retain(UnaryPredicate<? super T> filter) {
+        if (filter == null) {
             throw new NullPointerException("filtering predicate was null");
         }
         synchronized (this) {
             if (this.predicate == null) {
                 this.predicate = new UnaryAnd<T>();
             }
-            this.predicate.and(predicate);
+            this.predicate.and(filter);
         }
         return this;
     }



Mime
View raw message