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/04/30 21:56:12 UTC

svn commit: r1477799 [2/2] - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java Tue Apr 30 19:56:11 2013
@@ -48,7 +48,7 @@ import java.io.Serializable;
  * Attempting to add a null key or value to the map will raise a <code>NullPointerException</code>.
  * <p>
  * This implementation is not synchronized.
- * You can use {@link java.util.Collections#synchronizedMap} to 
+ * You can use {@link java.util.Collections#synchronizedMap} to
  * provide synchronized access to a <code>ReferenceMap</code>.
  * Remember that synchronization will not stop the garbage collector removing entries.
  * <p>
@@ -58,7 +58,7 @@ import java.io.Serializable;
  * <strong>Note that ReferenceMap is not synchronized and is not thread-safe.</strong>
  * If you wish to use this map from multiple threads concurrently, you must use
  * appropriate synchronization. The simplest approach is to wrap this map
- * using {@link java.util.Collections#synchronizedMap}. This class may throw 
+ * using {@link java.util.Collections#synchronizedMap}. This class may throw
  * exceptions when accessed by concurrent threads without synchronization.
  * <p>
  * NOTE: As from Commons Collections 3.1 this map extends <code>AbstractReferenceMap</code>
@@ -89,8 +89,8 @@ public class ReferenceMap<K, V> extends 
      * use the specified types of references.
      *
      * @param keyType  the type of reference to use for keys;
-     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD}, 
-     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT}, 
+     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
+     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT},
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
      * @param valueType  the type of reference to use for values;
      *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
@@ -106,15 +106,15 @@ public class ReferenceMap<K, V> extends 
      * use the specified types of references.
      *
      * @param keyType  the type of reference to use for keys;
-     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD}, 
-     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT}, 
+     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
+     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT},
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
      * @param valueType  the type of reference to use for values;
      *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
      *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT},
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
-     * @param purgeValues should the value be automatically purged when the 
-     *   key is garbage collected 
+     * @param purgeValues should the value be automatically purged when the
+     *   key is garbage collected
      */
     public ReferenceMap(final ReferenceStrength keyType, final ReferenceStrength valueType, final boolean purgeValues) {
         super(keyType, valueType, DEFAULT_CAPACITY, DEFAULT_LOAD_FACTOR, purgeValues);
@@ -126,8 +126,8 @@ public class ReferenceMap<K, V> extends 
      * capacity.
      *
      * @param keyType  the type of reference to use for keys;
-     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD}, 
-     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT}, 
+     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
+     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT},
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
      * @param valueType  the type of reference to use for values;
      *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
@@ -147,8 +147,8 @@ public class ReferenceMap<K, V> extends 
      * capacity.
      *
      * @param keyType  the type of reference to use for keys;
-     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD}, 
-     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT}, 
+     *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
+     *   {@link AbstractReferenceMap.ReferenceStrength#SOFT SOFT},
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
      * @param valueType  the type of reference to use for values;
      *   must be {@link AbstractReferenceMap.ReferenceStrength#HARD HARD},
@@ -156,8 +156,8 @@ public class ReferenceMap<K, V> extends 
      *   {@link AbstractReferenceMap.ReferenceStrength#WEAK WEAK}
      * @param capacity  the initial capacity for the map
      * @param loadFactor  the load factor for the map
-     * @param purgeValues  should the value be automatically purged when the 
-     *   key is garbage collected 
+     * @param purgeValues  should the value be automatically purged when the
+     *   key is garbage collected
      */
     public ReferenceMap(final ReferenceStrength keyType, final ReferenceStrength valueType, final int capacity,
             final float loadFactor, final boolean purgeValues) {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/SingletonMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/SingletonMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/SingletonMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/SingletonMap.java Tue Apr 30 19:56:11 2013
@@ -43,7 +43,7 @@ import org.apache.commons.collections4.k
  * <p>
  * If trying to remove or clear the map, an UnsupportedOperationException is thrown.
  * If trying to put a new mapping into the map, an  IllegalArgumentException is thrown.
- * The put method will only suceed if the key specified is the same as the 
+ * The put method will only suceed if the key specified is the same as the
  * singleton key.
  * <p>
  * The key and value can be obtained by:
@@ -131,7 +131,7 @@ public class SingletonMap<K, V>
     /**
      * Gets the key.
      *
-     * @return the key 
+     * @return the key
      */
     public K getKey() {
         return key;
@@ -171,7 +171,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the maximum size of the map, always 1.
-     * 
+     *
      * @return 1 always
      */
     public int maxSize() {
@@ -182,7 +182,7 @@ public class SingletonMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Gets the value mapped to the key specified.
-     * 
+     *
      * @param key  the key
      * @return the mapped value, null if no match
      */
@@ -195,7 +195,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the size of the map, always 1.
-     * 
+     *
      * @return the size of 1
      */
     public int size() {
@@ -204,7 +204,7 @@ public class SingletonMap<K, V>
 
     /**
      * Checks whether the map is currently empty, which it never is.
-     * 
+     *
      * @return false always
      */
     public boolean isEmpty() {
@@ -214,7 +214,7 @@ public class SingletonMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Checks whether the map contains the specified key.
-     * 
+     *
      * @param key  the key to search for
      * @return true if the map contains the key
      */
@@ -224,7 +224,7 @@ public class SingletonMap<K, V>
 
     /**
      * Checks whether the map contains the specified value.
-     * 
+     *
      * @param value  the value to search for
      * @return true if the map contains the key
      */
@@ -238,7 +238,7 @@ public class SingletonMap<K, V>
      * <p>
      * An IllegalArgumentException is thrown if the key does not match as the map
      * is fixed size.
-     * 
+     *
      * @param key  the key to set, must be the key of the map
      * @param value  the value to set
      * @return the value previously mapped to this key, null if none
@@ -257,7 +257,7 @@ public class SingletonMap<K, V>
      * The map must be of size 0 or size 1.
      * If it is size 1, the key must match the key of this map otherwise an
      * IllegalArgumentException is thrown.
-     * 
+     *
      * @param map  the map to add, must be size 0 or 1, and the key must match
      * @throws NullPointerException if the map is null
      * @throws IllegalArgumentException if the key does not match
@@ -276,10 +276,10 @@ public class SingletonMap<K, V>
                 throw new IllegalArgumentException("The map size must be 0 or 1");
         }
     }
-    
+
     /**
      * Unsupported operation.
-     * 
+     *
      * @param key  the mapping to remove
      * @return the value mapped to the removed key, null if key not in map
      * @throws UnsupportedOperationException always
@@ -300,19 +300,19 @@ public class SingletonMap<K, V>
      * Gets the entrySet view of the map.
      * Changes made via <code>setValue</code> affect this map.
      * To simply iterate through the entries, use {@link #mapIterator()}.
-     * 
+     *
      * @return the entrySet view
      */
     public Set<Map.Entry<K, V>> entrySet() {
         final Map.Entry<K, V> entry = new TiedMapEntry<K, V>(this, getKey());
         return Collections.singleton(entry);
     }
-    
+
     /**
      * Gets the unmodifiable keySet view of the map.
      * Changes made to the view affect this map.
      * To simply iterate through the keys, use {@link #mapIterator()}.
-     * 
+     *
      * @return the keySet view
      */
     public Set<K> keySet() {
@@ -323,7 +323,7 @@ public class SingletonMap<K, V>
      * Gets the unmodifiable values view of the map.
      * Changes made to the view affect this map.
      * To simply iterate through the values, use {@link #mapIterator()}.
-     * 
+     *
      * @return the values view
      */
     public Collection<V> values() {
@@ -339,7 +339,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the first (and only) key in the map.
-     * 
+     *
      * @return the key
      */
     public K firstKey() {
@@ -348,7 +348,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the last (and only) key in the map.
-     * 
+     *
      * @return the key
      */
     public K lastKey() {
@@ -357,7 +357,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the next key after the key specified, always null.
-     * 
+     *
      * @param key  the next key
      * @return null always
      */
@@ -367,7 +367,7 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the previous key before the key specified, always null.
-     * 
+     *
      * @param key  the next key
      * @return null always
      */
@@ -378,7 +378,7 @@ public class SingletonMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Compares the specified key to the stored key.
-     * 
+     *
      * @param key  the key to compare
      * @return true if equal
      */
@@ -388,7 +388,7 @@ public class SingletonMap<K, V>
 
     /**
      * Compares the specified value to the stored value.
-     * 
+     *
      * @param value  the value to compare
      * @return true if equal
      */
@@ -404,7 +404,7 @@ public class SingletonMap<K, V>
         private final SingletonMap<K, V> parent;
         private boolean hasNext = true;
         private boolean canGetSet = false;
-        
+
         SingletonMapIterator(final SingletonMap<K, V> parent) {
             super();
             this.parent = parent;
@@ -459,11 +459,11 @@ public class SingletonMap<K, V>
             }
             return parent.setValue(value);
         }
-        
+
         public void reset() {
             hasNext = true;
         }
-        
+
         @Override
         public String toString() {
             if (hasNext) {
@@ -472,7 +472,7 @@ public class SingletonMap<K, V>
             return "Iterator[" + getKey() + "=" + getValue() + "]";
         }
     }
-    
+
     /**
      * Values implementation for the SingletonMap.
      * This class is needed as values is a view that must update as the map updates.
@@ -507,7 +507,7 @@ public class SingletonMap<K, V>
             return new SingletonIterator<V>(parent.getValue(), false);
         }
     }
-    
+
     //-----------------------------------------------------------------------
     /**
      * Clones the map without cloning the key or value.
@@ -526,7 +526,7 @@ public class SingletonMap<K, V>
 
     /**
      * Compares this map with another.
-     * 
+     *
      * @param obj  the object to compare to
      * @return true if equal
      */
@@ -548,18 +548,18 @@ public class SingletonMap<K, V>
 
     /**
      * Gets the standard Map hashCode.
-     * 
+     *
      * @return the hash code defined in the Map interface
      */
     @Override
     public int hashCode() {
         return (getKey() == null ? 0 : getKey().hashCode()) ^
-               (getValue() == null ? 0 : getValue().hashCode()); 
+               (getValue() == null ? 0 : getValue().hashCode());
     }
 
     /**
      * Gets the map as a String.
-     * 
+     *
      * @return a string version of the map
      */
     @Override

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java Tue Apr 30 19:56:11 2013
@@ -31,7 +31,7 @@ import org.apache.commons.collections4.K
  * A StaticBucketMap is an efficient, thread-safe implementation of
  * <code>java.util.Map</code> that performs well in in a highly
  * thread-contentious environment.  The map supports very efficient
- * {@link #get(Object) get}, {@link #put(Object,Object) put}, 
+ * {@link #get(Object) get}, {@link #put(Object,Object) put},
  * {@link #remove(Object) remove} and {@link #containsKey(Object) containsKey}
  * operations, assuming (approximate) uniform hashing and
  * that the number of entries does not exceed the number of buckets.  If the
@@ -40,16 +40,16 @@ import org.apache.commons.collections4.K
  * scenario that is proportional to the number of elements in the map
  * (<i>O(n)</i>).<p>
  *
- * Each bucket in the hash table has its own monitor, so two threads can 
- * safely operate on the map at the same time, often without incurring any 
+ * Each bucket in the hash table has its own monitor, so two threads can
+ * safely operate on the map at the same time, often without incurring any
  * monitor contention.  This means that you don't have to wrap instances
  * of this class with {@link java.util.Collections#synchronizedMap(Map)};
- * instances are already thread-safe.  Unfortunately, however, this means 
- * that this map implementation behaves in ways you may find disconcerting.  
+ * instances are already thread-safe.  Unfortunately, however, this means
+ * that this map implementation behaves in ways you may find disconcerting.
  * Bulk operations, such as {@link #putAll(Map) putAll} or the
- * {@link Collection#retainAll(Collection) retainAll} operation in collection 
- * views, are <i>not</i> atomic.  If two threads are simultaneously 
- * executing 
+ * {@link Collection#retainAll(Collection) retainAll} operation in collection
+ * views, are <i>not</i> atomic.  If two threads are simultaneously
+ * executing
  *
  * <pre>
  *   staticBucketMapInstance.putAll(map);
@@ -62,23 +62,23 @@ import org.apache.commons.collections4.K
  * </pre>
  *
  * then the results are generally random.  Those two statement could cancel
- * each other out, leaving <code>staticBucketMapInstance</code> essentially 
- * unchanged, or they could leave some random subset of <code>map</code> in 
+ * each other out, leaving <code>staticBucketMapInstance</code> essentially
+ * unchanged, or they could leave some random subset of <code>map</code> in
  * <code>staticBucketMapInstance</code>.<p>
  *
- * Also, much like an encyclopedia, the results of {@link #size()} and 
+ * Also, much like an encyclopedia, the results of {@link #size()} and
  * {@link #isEmpty()} are out-of-date as soon as they are produced.<p>
  *
  * The iterators returned by the collection views of this class are <i>not</i>
- * fail-fast.  They will <i>never</i> raise a 
- * {@link java.util.ConcurrentModificationException}.  Keys and values 
+ * fail-fast.  They will <i>never</i> raise a
+ * {@link java.util.ConcurrentModificationException}.  Keys and values
  * added to the map after the iterator is created do not necessarily appear
- * during iteration.  Similarly, the iterator does not necessarily fail to 
+ * during iteration.  Similarly, the iterator does not necessarily fail to
  * return keys and values that were removed after the iterator was created.<p>
  *
  * Finally, unlike {@link java.util.HashMap}-style implementations, this
- * class <i>never</i> rehashes the map.  The number of buckets is fixed 
- * at construction time and never altered.  Performance may degrade if 
+ * class <i>never</i> rehashes the map.  The number of buckets is fixed
+ * at construction time and never altered.  Performance may degrade if
  * you do not allocate enough buckets upfront.<p>
  *
  * The {@link #atomic(Runnable)} method is provided to allow atomic iterations
@@ -86,8 +86,8 @@ import org.apache.commons.collections4.K
  * will basically result in a map that's slower than an ordinary synchronized
  * {@link java.util.HashMap}.
  *
- * Use this class if you do not require reliable bulk operations and 
- * iterations, or if you can make your own guarantees about how bulk 
+ * Use this class if you do not require reliable bulk operations and
+ * iterations, or if you can make your own guarantees about how bulk
  * operations will affect the map.<p>
  *
  * @since 3.0 (previously in main package v2.1)
@@ -168,7 +168,7 @@ public final class StaticBucketMap<K, V>
     /**
      * Gets the current size of the map.
      * The value is computed fresh each time the method is called.
-     * 
+     *
      * @return the current size
      */
     public int size() {
@@ -184,7 +184,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Checks if the size is currently zero.
-     * 
+     *
      * @return true if empty
      */
     public boolean isEmpty() {
@@ -193,7 +193,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Gets the value associated with the key.
-     * 
+     *
      * @param key  the key to retrieve
      * @return the associated value
      */
@@ -216,7 +216,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Checks if the map contains the specified key.
-     * 
+     *
      * @param key  the key to check
      * @return true if found
      */
@@ -239,7 +239,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Checks if the map contains the specified value.
-     * 
+     *
      * @param value  the value to check
      * @return true if found
      */
@@ -263,7 +263,7 @@ public final class StaticBucketMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Puts a new key value mapping into the map.
-     * 
+     *
      * @param key  the key to use
      * @param value  the value to use
      * @return the previous mapping for the key
@@ -309,7 +309,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Removes the specified key from the map.
-     * 
+     *
      * @param key  the key to remove
      * @return the previous value at this key
      */
@@ -344,7 +344,7 @@ public final class StaticBucketMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Gets the key set.
-     * 
+     *
      * @return the key set
      */
     public Set<K> keySet() {
@@ -353,7 +353,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Gets the values.
-     * 
+     *
      * @return the values
      */
     public Collection<V> values() {
@@ -362,7 +362,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Gets the entry set.
-     * 
+     *
      * @return the entry set
      */
     public Set<Map.Entry<K, V>> entrySet() {
@@ -373,7 +373,7 @@ public final class StaticBucketMap<K, V>
     /**
      * Puts all the entries from the specified map into this map.
      * This operation is <b>not atomic</b> and may have undesired effects.
-     * 
+     *
      * @param map  the map of entries to add
      */
     public void putAll(final Map<? extends K, ? extends V> map) {
@@ -397,7 +397,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Compares this map to another, as per the Map specification.
-     * 
+     *
      * @param obj  the object to compare to
      * @return true if equal
      */
@@ -415,7 +415,7 @@ public final class StaticBucketMap<K, V>
 
     /**
      * Gets the hash code, as per the Map specification.
-     * 
+     *
      * @return the hash code
      */
     @Override
@@ -667,7 +667,7 @@ public final class StaticBucketMap<K, V>
     /**
      *  Prevents any operations from occurring on this map while the
      *  given {@link Runnable} executes.  This method can be used, for
-     *  instance, to execute a bulk operation atomically: 
+     *  instance, to execute a bulk operation atomically:
      *
      *  <pre>
      *    staticBucketMapInstance.atomic(new Runnable() {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedMap.java Tue Apr 30 19:56:11 2013
@@ -147,7 +147,7 @@ public class TransformedMap<K, V>
      * @throws ClassNotFoundException
      * @since 3.1
      */
-    @SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect 
+    @SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect
     private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException {
         in.defaultReadObject();
         map = (Map<K, V>) in.readObject(); // (1)

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedSortedMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedSortedMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedSortedMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/TransformedSortedMap.java Tue Apr 30 19:56:11 2013
@@ -33,7 +33,7 @@ import org.apache.commons.collections4.T
  * <strong>Note that TransformedSortedMap is not synchronized and is not thread-safe.</strong>
  * If you wish to use this map from multiple threads concurrently, you must use
  * appropriate synchronization. The simplest approach is to wrap this map
- * using {@link java.util.Collections#synchronizedSortedMap}. This class may throw 
+ * using {@link java.util.Collections#synchronizedSortedMap}. This class may throw
  * exceptions when accessed by concurrent threads without synchronization.
  * <p>
  * This class is Serializable from Commons Collections 3.1.
@@ -47,13 +47,13 @@ public class TransformedSortedMap<K, V>
 
     /** Serialization version */
     private static final long serialVersionUID = -8751771676410385778L;
-    
+
     /**
      * Factory method to create a transforming sorted map.
      * <p>
      * If there are any elements already in the map being decorated, they are NOT transformed.
      * Contrast this with {@link #transformedSortedMap(SortedMap, Transformer, Transformer)}.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param map  the map to decorate, must not be null
@@ -75,7 +75,7 @@ public class TransformedSortedMap<K, V>
      * If there are any elements already in the map being decorated, they
      * will be transformed by this method.
      * Contrast this with {@link #transformingSortedMap(SortedMap, Transformer, Transformer)}.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param map  the map to decorate, must not be null
@@ -105,7 +105,7 @@ public class TransformedSortedMap<K, V>
      * <p>
      * If there are any elements already in the collection being decorated, they
      * are NOT transformed.</p>
-     * 
+     *
      * @param map  the map to decorate, must not be null
      * @param keyTransformer  the predicate to validate the keys, null means no transformation
      * @param valueTransformer  the predicate to validate to values, null means no transformation
@@ -120,7 +120,7 @@ public class TransformedSortedMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Gets the map being decorated.
-     * 
+     *
      * @return the decorated map
      */
     protected SortedMap<K, V> getSortedMap() {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableEntrySet.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableEntrySet.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableEntrySet.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableEntrySet.java Tue Apr 30 19:56:11 2013
@@ -30,7 +30,7 @@ import org.apache.commons.collections4.k
 /**
  * Decorates a map entry <code>Set</code> to ensure it can't be altered.
  * <p>
- * Attempts to modify it will result in an UnsupportedOperationException. 
+ * Attempts to modify it will result in an UnsupportedOperationException.
  *
  * @since 3.0
  * @version $Id$
@@ -43,7 +43,7 @@ public final class UnmodifiableEntrySet<
 
     /**
      * Factory method to create an unmodifiable set of Map Entry objects.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param set  the set to decorate, must not be null
@@ -60,7 +60,7 @@ public final class UnmodifiableEntrySet<
     //-----------------------------------------------------------------------
     /**
      * Constructor that wraps (not copies).
-     * 
+     *
      * @param set  the set to decorate, must not be null
      * @throws IllegalArgumentException if set is null
      */
@@ -104,7 +104,7 @@ public final class UnmodifiableEntrySet<
     public Iterator<Map.Entry<K, V>> iterator() {
         return new UnmodifiableEntrySetIterator(collection.iterator());
     }
-    
+
     @Override
     @SuppressWarnings("unchecked")
     public Object[] toArray() {
@@ -114,7 +114,7 @@ public final class UnmodifiableEntrySet<
         }
         return array;
     }
-    
+
     @Override
     @SuppressWarnings("unchecked")
     public <T> T[] toArray(final T[] array) {
@@ -141,7 +141,7 @@ public final class UnmodifiableEntrySet<
         }
         return array;
     }
-    
+
     //-----------------------------------------------------------------------
     /**
      * Implementation of an entry set iterator.

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableMap.java Tue Apr 30 19:56:11 2013
@@ -37,7 +37,7 @@ import org.apache.commons.collections4.i
  * <p>
  * This class is Serializable from Commons Collections 3.1.
  * <p>
- * Attempts to modify it will result in an UnsupportedOperationException. 
+ * Attempts to modify it will result in an UnsupportedOperationException.
  *
  * @since 3.0
  * @version $Id$
@@ -51,7 +51,7 @@ public final class UnmodifiableMap<K, V>
 
     /**
      * Factory method to create an unmodifiable map.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param map  the map to decorate, must not be null
@@ -68,7 +68,7 @@ public final class UnmodifiableMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Constructor that wraps (not copies).
-     * 
+     *
      * @param map  the map to decorate, must not be null
      * @throws IllegalArgumentException if map is null
      */
@@ -79,7 +79,7 @@ public final class UnmodifiableMap<K, V>
     //-----------------------------------------------------------------------
     /**
      * Write the map out using a custom routine.
-     * 
+     *
      * @param out  the output stream
      * @throws IOException
      * @since 3.1
@@ -91,7 +91,7 @@ public final class UnmodifiableMap<K, V>
 
     /**
      * Read the map in using a custom routine.
-     * 
+     *
      * @param in  the input stream
      * @throws IOException
      * @throws ClassNotFoundException

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableOrderedMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableOrderedMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableOrderedMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableOrderedMap.java Tue Apr 30 19:56:11 2013
@@ -36,7 +36,7 @@ import org.apache.commons.collections4.i
  * <p>
  * This class is Serializable from Commons Collections 3.1.
  * <p>
- * Attempts to modify it will result in an UnsupportedOperationException. 
+ * Attempts to modify it will result in an UnsupportedOperationException.
  *
  * @since 3.0
  * @version $Id$
@@ -49,7 +49,7 @@ public final class UnmodifiableOrderedMa
 
     /**
      * Factory method to create an unmodifiable sorted map.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param map  the map to decorate, must not be null
@@ -66,7 +66,7 @@ public final class UnmodifiableOrderedMa
     //-----------------------------------------------------------------------
     /**
      * Constructor that wraps (not copies).
-     * 
+     *
      * @param map  the map to decorate, must not be null
      * @throws IllegalArgumentException if map is null
      */
@@ -77,7 +77,7 @@ public final class UnmodifiableOrderedMa
     //-----------------------------------------------------------------------
     /**
      * Write the map out using a custom routine.
-     * 
+     *
      * @param out  the output stream
      * @throws IOException
      * @since 3.1
@@ -89,13 +89,13 @@ public final class UnmodifiableOrderedMa
 
     /**
      * Read the map in using a custom routine.
-     * 
+     *
      * @param in  the input stream
      * @throws IOException
      * @throws ClassNotFoundException
      * @since 3.1
      */
-    @SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect 
+    @SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect
     private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException {
         in.defaultReadObject();
         map = (Map<K, V>) in.readObject(); // (1)

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableSortedMap.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableSortedMap.java?rev=1477799&r1=1477798&r2=1477799&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableSortedMap.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/UnmodifiableSortedMap.java Tue Apr 30 19:56:11 2013
@@ -35,7 +35,7 @@ import org.apache.commons.collections4.c
  * <p>
  * This class is Serializable from Commons Collections 3.1.
  * <p>
- * Attempts to modify it will result in an UnsupportedOperationException. 
+ * Attempts to modify it will result in an UnsupportedOperationException.
  *
  * @since 3.0
  * @version $Id$
@@ -49,7 +49,7 @@ public final class UnmodifiableSortedMap
 
     /**
      * Factory method to create an unmodifiable sorted map.
-     * 
+     *
      * @param <K>  the key type
      * @param <V>  the value type
      * @param map  the map to decorate, must not be null
@@ -66,18 +66,18 @@ public final class UnmodifiableSortedMap
     //-----------------------------------------------------------------------
     /**
      * Constructor that wraps (not copies).
-     * 
+     *
      * @param map  the map to decorate, must not be null
      * @throws IllegalArgumentException if map is null
      */
     private UnmodifiableSortedMap(final SortedMap<K, V> map) {
         super(map);
     }
-    
+
     //-----------------------------------------------------------------------
     /**
      * Write the map out using a custom routine.
-     * 
+     *
      * @param out  the output stream
      * @throws IOException
      * @since 3.1
@@ -89,7 +89,7 @@ public final class UnmodifiableSortedMap
 
     /**
      * Read the map in using a custom routine.
-     * 
+     *
      * @param in  the input stream
      * @throws IOException
      * @throws ClassNotFoundException