You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by tn...@apache.org on 2013/01/20 22:13:19 UTC

svn commit: r1435965 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/

Author: tn
Date: Sun Jan 20 21:13:18 2013
New Revision: 1435965

URL: http://svn.apache.org/viewvc?rev=1435965&view=rev
Log:
Add javadoc, minor formatting.

Modified:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ChainedTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/CloneTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ClosureTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ComparatorPredicate.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantFactory.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/DefaultEquator.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionFactory.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionPredicate.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FactoryTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FunctorUtils.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/IfClosure.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateFactory.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InvokerTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/MapTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/NOPTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/OrPredicate.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PredicateTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PrototypeFactory.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/StringValueTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/SwitchTransformer.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/TransformedPredicate.java

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ChainedTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ChainedTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ChainedTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ChainedTransformer.java Sun Jan 20 21:13:18 2013
@@ -40,7 +40,8 @@ public class ChainedTransformer<T> imple
 
     /**
      * Factory method that performs validation and copies the parameter array.
-     * 
+     *
+     * @param <T>  the object type
      * @param transformers  the transformers to chain, copied, no nulls
      * @return the <code>chained</code> transformer
      * @throws IllegalArgumentException if the transformers array is null
@@ -58,7 +59,8 @@ public class ChainedTransformer<T> imple
      * Create a new Transformer that calls each transformer in turn, passing the 
      * result into the next transformer. The ordering is that of the iterator()
      * method on the collection.
-     * 
+     *
+     * @param <T>  the object type
      * @param transformers  a collection of transformers to chain
      * @return the <code>chained</code> transformer
      * @throws IllegalArgumentException if the transformers collection is null

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/CloneTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/CloneTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/CloneTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/CloneTransformer.java Sun Jan 20 21:13:18 2013
@@ -38,7 +38,8 @@ public class CloneTransformer<T> impleme
 
     /**
      * Factory returning the singleton instance.
-     * 
+     *
+     * @param <T>  the type of the objects to be cloned
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ClosureTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ClosureTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ClosureTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ClosureTransformer.java Sun Jan 20 21:13:18 2013
@@ -38,7 +38,8 @@ public class ClosureTransformer<T> imple
 
     /**
      * Factory method that performs validation.
-     * 
+     *
+     * @param <T>  the type of the object to transform
      * @param closure  the closure to call, not null
      * @return the <code>closure</code> transformer
      * @throws IllegalArgumentException if the closure is null

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ComparatorPredicate.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ComparatorPredicate.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ComparatorPredicate.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ComparatorPredicate.java Sun Jan 20 21:13:18 2013
@@ -118,7 +118,8 @@ public class ComparatorPredicate<T> impl
      * @return the predicate
      * @throws IllegalArgumentException if comparator is null of criterion is invalid
      */
-    public static <T> Predicate<T> comparatorPredicate(final T object, final Comparator<T> comparator, final Criterion criterion) {
+    public static <T> Predicate<T> comparatorPredicate(final T object, final Comparator<T> comparator,
+                                                       final Criterion criterion) {
         if (comparator == null) {
             throw new IllegalArgumentException("Comparator must not be null.");
         }
@@ -157,6 +158,8 @@ public class ComparatorPredicate<T> impl
      * @see org.apache.commons.collections.Predicate#evaluate(java.lang.Object)
      * @see java.util.Comparator#compare(java.lang.Object first, java.lang.Object second)
      * 
+     * @param target  the target object to compare to
+     * @return {@code true} if the comparison succeeds according to the selected criterion
      * @throws IllegalStateException if the criterion is invalid (really not possible)
      */
     public boolean evaluate(final T target) {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantFactory.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantFactory.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantFactory.java Sun Jan 20 21:13:18 2013
@@ -44,6 +44,7 @@ public class ConstantFactory<T> implemen
     /**
      * Factory method that performs validation.
      *
+     * @param <T>  the type of the constant
      * @param constantToReturn  the constant object to return each time in the factory
      * @return the <code>constant</code> factory.
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ConstantTransformer.java Sun Jan 20 21:13:18 2013
@@ -43,8 +43,9 @@ public class ConstantTransformer<I, O> i
 
     /**
      * Get a typed null instance.
-     * @param <I>
-     * @param <O>
+     *
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @return Transformer<I, O> that always returns null.
      */
     @SuppressWarnings("unchecked")
@@ -55,6 +56,8 @@ public class ConstantTransformer<I, O> i
     /**
      * Transformer method that performs validation.
      *
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param constantToReturn  the constant object to return each time in the factory
      * @return the <code>constant</code> factory.
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/DefaultEquator.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/DefaultEquator.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/DefaultEquator.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/DefaultEquator.java Sun Jan 20 21:13:18 2013
@@ -19,7 +19,7 @@ package org.apache.commons.collections.f
 /**
  * Default {@link Equator} implementation.
  * 
- * @param <T>
+ * @param <T>  the types of object this {@link Equator} can evaluate.
  * @since 4.0
  * @version $Id$
  */
@@ -56,7 +56,7 @@ public class DefaultEquator<T> implement
     /**
      * Get a typed {@link DefaultEquator} instance.
      * 
-     * @param <T>
+     * @param <T>  the object type
      * @return {@link DefaultEquator#INSTANCE}
      */
     @SuppressWarnings("unchecked")

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionFactory.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionFactory.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionFactory.java Sun Jan 20 21:13:18 2013
@@ -38,6 +38,7 @@ public final class ExceptionFactory<T> i
     /**
      * Factory returning the singleton instance.
      * 
+     * @param <T>  the type the factory creates
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionPredicate.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionPredicate.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionPredicate.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionPredicate.java Sun Jan 20 21:13:18 2013
@@ -38,6 +38,7 @@ public final class ExceptionPredicate<T>
     /**
      * Factory returning the singleton instance.
      *
+     * @param <T>  the object type
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/ExceptionTransformer.java Sun Jan 20 21:13:18 2013
@@ -38,6 +38,8 @@ public final class ExceptionTransformer<
     /**
      * Factory returning the singleton instance.
      *
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FactoryTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FactoryTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FactoryTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FactoryTransformer.java Sun Jan 20 21:13:18 2013
@@ -38,6 +38,8 @@ public class FactoryTransformer<I, O> im
     /**
      * Factory method that performs validation.
      * 
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param factory  the factory to call, not null
      * @return the <code>factory</code> transformer
      * @throws IllegalArgumentException if the factory is null

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FunctorUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FunctorUtils.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FunctorUtils.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/FunctorUtils.java Sun Jan 20 21:13:18 2013
@@ -105,7 +105,8 @@ class FunctorUtils {
         for (final Predicate<T> predicate : predicates) {
             preds[i] = predicate;
             if (preds[i] == null) {
-                throw new IllegalArgumentException("The predicate collection must not contain a null predicate, index " + i + " was null");
+                throw new IllegalArgumentException(
+                        "The predicate collection must not contain a null predicate, index " + i + " was null");
             }
             i++;
         }
@@ -137,7 +138,8 @@ class FunctorUtils {
         }
         for (int i = 0; i < closures.length; i++) {
             if (closures[i] == null) {
-                throw new IllegalArgumentException("The closure array must not contain a null closure, index " + i + " was null");
+                throw new IllegalArgumentException(
+                        "The closure array must not contain a null closure, index " + i + " was null");
             }
         }
     }

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/IfClosure.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/IfClosure.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/IfClosure.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/IfClosure.java Sun Jan 20 21:13:18 2013
@@ -102,7 +102,8 @@ public class IfClosure<E> implements Clo
      * @param trueClosure  closure used if true, not null
      * @param falseClosure  closure used if false, not null
      */
-    public IfClosure(final Predicate<? super E> predicate, final Closure<? super E> trueClosure, final Closure<? super E> falseClosure) {
+    public IfClosure(final Predicate<? super E> predicate, final Closure<? super E> trueClosure,
+                     final Closure<? super E> falseClosure) {
         super();
         iPredicate = predicate;
         iTrueClosure = trueClosure;

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateFactory.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateFactory.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateFactory.java Sun Jan 20 21:13:18 2013
@@ -46,12 +46,14 @@ public class InstantiateFactory<T> imple
     /**
      * Factory method that performs validation.
      * 
+     * @param <T>  the type the factory creates
      * @param classToInstantiate  the class to instantiate, not null
      * @param paramTypes  the constructor parameter types
      * @param args  the constructor arguments
      * @return a new instantiate factory
      */
-    public static <T> Factory<T> instantiateFactory(final Class<T> classToInstantiate, Class<?>[] paramTypes, Object[] args) {
+    public static <T> Factory<T> instantiateFactory(final Class<T> classToInstantiate, Class<?>[] paramTypes,
+                                                    Object[] args) {
         if (classToInstantiate == null) {
             throw new IllegalArgumentException("Class to instantiate must not be null");
         }

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InstantiateTransformer.java Sun Jan 20 21:13:18 2013
@@ -44,7 +44,8 @@ public class InstantiateTransformer<T> i
 
     /**
      * Get a typed no-arg instance.
-     * @param <T>
+     *
+     * @param <T>  the type of the objects to be created
      * @return Transformer<Class<? extends T>, T>
      */
     public static <T> Transformer<Class<? extends T>, T> instantiateTransformer() {
@@ -54,6 +55,7 @@ public class InstantiateTransformer<T> i
     /**
      * Transformer method that performs validation.
      *
+     * @param <T>  the type of the objects to be created
      * @param paramTypes  the constructor parameter types
      * @param args  the constructor arguments
      * @return an instantiate transformer

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InvokerTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InvokerTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InvokerTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/InvokerTransformer.java Sun Jan 20 21:13:18 2013
@@ -44,6 +44,8 @@ public class InvokerTransformer<I, O> im
     /**
      * Gets an instance of this transformer calling a specific method with no arguments.
      * 
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param methodName  the method name to call
      * @return an invoker transformer
      * @since 3.1
@@ -57,13 +59,16 @@ public class InvokerTransformer<I, O> im
 
     /**
      * Gets an instance of this transformer calling a specific method with specific values.
-     * 
+     *
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param methodName  the method name to call
      * @param paramTypes  the parameter types of the method
      * @param args  the arguments to pass to the method
      * @return an invoker transformer
      */
-    public static <I, O> Transformer<I, O> invokerTransformer(final String methodName, Class<?>[] paramTypes, Object[] args) {
+    public static <I, O> Transformer<I, O> invokerTransformer(final String methodName, Class<?>[] paramTypes,
+                                                              Object[] args) {
         if (methodName == null) {
             throw new IllegalArgumentException("The method to invoke must not be null");
         }

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/MapTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/MapTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/MapTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/MapTransformer.java Sun Jan 20 21:13:18 2013
@@ -41,6 +41,8 @@ public final class MapTransformer<I, O> 
      * <p>
      * If the map is null, a transformer that always returns null is returned.
      *
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param map the map, not cloned
      * @return the transformer
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/NOPTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/NOPTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/NOPTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/NOPTransformer.java Sun Jan 20 21:13:18 2013
@@ -37,6 +37,7 @@ public class NOPTransformer<T> implement
     /**
      * Factory returning the singleton instance.
      *
+     * @param <T>  the input/output type
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/OrPredicate.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/OrPredicate.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/OrPredicate.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/OrPredicate.java Sun Jan 20 21:13:18 2013
@@ -45,7 +45,8 @@ public final class OrPredicate<T> implem
      * @return the <code>and</code> predicate
      * @throws IllegalArgumentException if either predicate is null
      */
-    public static <T> Predicate<T> orPredicate(final Predicate<? super T> predicate1, final Predicate<? super T> predicate2) {
+    public static <T> Predicate<T> orPredicate(final Predicate<? super T> predicate1,
+                                               final Predicate<? super T> predicate2) {
         if (predicate1 == null || predicate2 == null) {
             throw new IllegalArgumentException("Predicate must not be null");
         }

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PredicateTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PredicateTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PredicateTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PredicateTransformer.java Sun Jan 20 21:13:18 2013
@@ -39,6 +39,7 @@ public class PredicateTransformer<T> imp
     /**
      * Factory method that performs validation.
      * 
+     * @param <T>  the input type
      * @param predicate  the predicate to call, not null
      * @return the <code>predicate</code> transformer
      * @throws IllegalArgumentException if the predicate is null

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PrototypeFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PrototypeFactory.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PrototypeFactory.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/PrototypeFactory.java Sun Jan 20 21:13:18 2013
@@ -48,6 +48,7 @@ public class PrototypeFactory {
      * <li>serialization clone
      * <ul>
      *
+     * @param <T>  the type the factory creates
      * @param prototype  the object to clone each time in the factory
      * @return the <code>prototype</code> factory, or a {@link ConstantFactory#NULL_INSTANCE} if
      * the {@code prototype} is {@code null}

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/StringValueTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/StringValueTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/StringValueTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/StringValueTransformer.java Sun Jan 20 21:13:18 2013
@@ -38,6 +38,7 @@ public final class StringValueTransforme
     /**
      * Factory returning the singleton instance.
      *
+     * @param <T>  the input type
      * @return the singleton instance
      * @since 3.1
      */

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/SwitchTransformer.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/SwitchTransformer.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/SwitchTransformer.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/SwitchTransformer.java Sun Jan 20 21:13:18 2013
@@ -44,6 +44,8 @@ public class SwitchTransformer<I, O> imp
     /**
      * Factory method that performs validation and copies the parameter arrays.
      * 
+     * @param <I>  the input type
+     * @param <O>  the output type
      * @param predicates  array of predicates, cloned, no nulls
      * @param transformers  matching array of transformers, cloned, no nulls
      * @param defaultTransformer  the transformer to use if no match, null means return null
@@ -61,7 +63,8 @@ public class SwitchTransformer<I, O> imp
             throw new IllegalArgumentException("The predicate and transformer arrays must be the same size");
         }
         if (predicates.length == 0) {
-            return (Transformer<I, O>) (defaultTransformer == null ? ConstantTransformer.<I, O>nullTransformer() : defaultTransformer);
+            return (Transformer<I, O>) (defaultTransformer == null ? ConstantTransformer.<I, O>nullTransformer() :
+                                                                     defaultTransformer);
         }
         return new SwitchTransformer<I, O>(FunctorUtils.copy(predicates),
                                            FunctorUtils.copy(transformers),
@@ -79,7 +82,9 @@ public class SwitchTransformer<I, O> imp
      * null key. The ordering is that of the iterator() method on the entryset 
      * collection of the map.
      * 
-     * @param predicatesAndTransformers  a map of predicates to transformers
+     * @param <I>  the input type
+     * @param <O>  the output type
+     * @param map  a map of predicates to transformers
      * @return the <code>switch</code> transformer
      * @throws IllegalArgumentException if the map is null
      * @throws IllegalArgumentException if any transformer in the map is null
@@ -87,23 +92,26 @@ public class SwitchTransformer<I, O> imp
      */
     @SuppressWarnings("unchecked")
     public static <I, O> Transformer<I, O> switchTransformer(
-            final Map<? extends Predicate<? super I>, ? extends Transformer<? super I, ? extends O>> predicatesAndTransformers) {
-        if (predicatesAndTransformers == null) {
+            final Map<? extends Predicate<? super I>, ? extends Transformer<? super I, ? extends O>> map) {
+
+        if (map == null) {
             throw new IllegalArgumentException("The predicate and transformer map must not be null");
         }
-        if (predicatesAndTransformers.size() == 0) {
+        if (map.size() == 0) {
             return ConstantTransformer.<I, O>nullTransformer();
         }
         // convert to array like this to guarantee iterator() ordering
-        final Transformer<? super I, ? extends O> defaultTransformer = predicatesAndTransformers.remove(null);
-        final int size = predicatesAndTransformers.size();
+        final Transformer<? super I, ? extends O> defaultTransformer = map.remove(null);
+        final int size = map.size();
         if (size == 0) {
-            return (Transformer<I, O>) (defaultTransformer == null ? ConstantTransformer.<I, O>nullTransformer() : defaultTransformer);
+            return (Transformer<I, O>) (defaultTransformer == null ? ConstantTransformer.<I, O>nullTransformer() :
+                                                                     defaultTransformer);
         }
         final Transformer<? super I, ? extends O>[] transformers = new Transformer[size];
         final Predicate<? super I>[] preds = new Predicate[size];
         int i = 0;
-        for (final Map.Entry<? extends Predicate<? super I>, ? extends Transformer<? super I, ? extends O>> entry : predicatesAndTransformers.entrySet()) {
+        for (final Map.Entry<? extends Predicate<? super I>,
+                             ? extends Transformer<? super I, ? extends O>> entry : map.entrySet()) {
             preds[i] = entry.getKey();
             transformers[i] = entry.getValue();
             i++;
@@ -126,7 +134,8 @@ public class SwitchTransformer<I, O> imp
         super();
         iPredicates = predicates;
         iTransformers = transformers;
-        iDefault = (Transformer<? super I, ? extends O>) (defaultTransformer == null ? ConstantTransformer.<I, O>nullTransformer() : defaultTransformer);
+        iDefault = (Transformer<? super I, ? extends O>) (defaultTransformer == null ?
+                ConstantTransformer.<I, O>nullTransformer() : defaultTransformer);
     }
 
     /**

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/TransformedPredicate.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/TransformedPredicate.java?rev=1435965&r1=1435964&r2=1435965&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/TransformedPredicate.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/functors/TransformedPredicate.java Sun Jan 20 21:13:18 2013
@@ -66,7 +66,8 @@ public final class TransformedPredicate<
      * @param transformer  the transformer to use
      * @param predicate  the predicate to decorate
      */
-    public TransformedPredicate(final Transformer<? super T, ? extends T> transformer, final Predicate<? super T> predicate) {
+    public TransformedPredicate(final Transformer<? super T, ? extends T> transformer,
+                                final Predicate<? super T> predicate) {
         iTransformer = transformer;
         iPredicate = predicate;
     }