jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mdue...@apache.org
Subject svn commit: r1336712 - /jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java
Date Thu, 10 May 2012 14:17:29 GMT
Author: mduerig
Date: Thu May 10 14:17:28 2012
New Revision: 1336712

URL: http://svn.apache.org/viewvc?rev=1336712&view=rev
Log:
remove unused/redundant method

Modified:
    jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java

Modified: jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java?rev=1336712&r1=1336711&r2=1336712&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java
(original)
+++ jackrabbit/oak/trunk/oak-commons/src/main/java/org/apache/jackrabbit/oak/commons/ArrayUtils.java
Thu May 10 14:17:28 2012
@@ -225,17 +225,4 @@ public class ArrayUtils {
         return new HashSet<T>(java.util.Arrays.asList(elements));
     }
 
-    // TODO duplicate of copyArrayAdd?
-    /**
-     * Create a new array of the same type with an additional element added.
-     * @param array
-     * @param value
-     * @param <T>
-     * @return array of {@code array.length + 1} with {@code value} as its last element.
-     */
-    public static <T> T[] add(T[] array, T value) {
-        T[] copy = java.util.Arrays.copyOf(array, array.length + 1);
-        copy[array.length] = value;
-        return copy;
-    }
 }



Mime
View raw message