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/06/16 17:56:36 UTC

svn commit: r1493523 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4: TrieUtils.java trie/AbstractPatriciaTrie.java trie/SynchronizedTrie.java trie/package-info.java

Author: tn
Date: Sun Jun 16 15:56:35 2013
New Revision: 1493523

URL: http://svn.apache.org/r1493523
Log:
Updates to tries: remove synchronized decorator, add javadoc.

Removed:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/SynchronizedTrie.java
Modified:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TrieUtils.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/package-info.java

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TrieUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TrieUtils.java?rev=1493523&r1=1493522&r2=1493523&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TrieUtils.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TrieUtils.java Sun Jun 16 15:56:35 2013
@@ -16,7 +16,6 @@
  */
 package org.apache.commons.collections4;
 
-import org.apache.commons.collections4.trie.SynchronizedTrie;
 import org.apache.commons.collections4.trie.UnmodifiableTrie;
 
 /**
@@ -33,17 +32,13 @@ public class TrieUtils {
     private TrieUtils() {}
 
     /**
-     * Returns a synchronized instance of a {@link Trie}
-     *
-     * @see java.util.Collections#synchronizedMap(java.util.Map)
-     */
-    public static <K, V> Trie<K, V> synchronizedTrie(final Trie<K, V> trie) {
-        return SynchronizedTrie.synchronizedTrie(trie);
-    }
-
-    /**
      * Returns an unmodifiable instance of a {@link Trie}
      *
+     * @param <K>  the key type
+     * @param <V>  the value type
+     * @param trie  the trie to make unmodifiable, must not be null
+     * @return an unmodifiable trie backed by the given trie
+     *
      * @see java.util.Collections#unmodifiableMap(java.util.Map)
      */
     public static <K, V> Trie<K, V> unmodifiableTrie(final Trie<K, V> trie) {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java?rev=1493523&r1=1493522&r2=1493523&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/AbstractPatriciaTrie.java Sun Jun 16 15:56:35 2013
@@ -34,6 +34,7 @@ import java.util.SortedMap;
 import java.util.Map.Entry;
 
 import org.apache.commons.collections4.OrderedMapIterator;
+import org.apache.commons.collections4.Trie;
 
 /**
  * This class implements the base PATRICIA algorithm and everything that
@@ -42,7 +43,7 @@ import org.apache.commons.collections4.O
  * @since 4.0
  * @version $Id$
  */
-abstract class AbstractPatriciaTrie<K, V> extends AbstractBitwiseTrie<K, V> {
+abstract class AbstractPatriciaTrie<K, V> extends AbstractBitwiseTrie<K, V> implements Trie<K, V> {
 
     private static final long serialVersionUID = 5155253417231339498L;
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/package-info.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/package-info.java?rev=1493523&r1=1493522&r2=1493523&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/package-info.java (original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/trie/package-info.java Sun Jun 16 15:56:35 2013
@@ -29,7 +29,6 @@
  * <p>
  * The following decorators are provided:
  * <ul>
- *   <li>Synchronized - synchronizes method access for multi-threaded environments
  *   <li>Unmodifiable - ensures the collection cannot be altered
  * </ul>
  *