提交 7e0a5f20 authored 作者: Noel Grandin's avatar Noel Grandin

remove unused type parameters

上级 acf14056
......@@ -10,7 +10,6 @@ import java.util.HashSet;
import java.util.List;
import java.util.Map.Entry;
import java.util.Random;
import org.h2.mvstore.cache.CacheLongKeyLIRS;
import org.h2.test.TestBase;
import org.h2.util.New;
......@@ -455,7 +454,7 @@ public class TestCacheLongKeyLIRS extends TestBase {
}
}
private static <K, V> String toString(CacheLongKeyLIRS<V> cache) {
private static <V> String toString(CacheLongKeyLIRS<V> cache) {
StringBuilder buff = new StringBuilder();
buff.append("mem: " + cache.getUsedMemory());
buff.append(" stack:");
......@@ -473,7 +472,7 @@ public class TestCacheLongKeyLIRS extends TestBase {
return buff.toString();
}
private <K, V> void verify(CacheLongKeyLIRS<V> cache, String expected) {
private <V> void verify(CacheLongKeyLIRS<V> cache, String expected) {
if (expected != null) {
String got = toString(cache);
assertEquals(expected, got);
......
......@@ -193,13 +193,13 @@ public class IntPerfectHash {
* @param list the data
* @return the hash function description
*/
public static <K> byte[] generate(ArrayList<Integer> list) {
public static byte[] generate(ArrayList<Integer> list) {
ByteStream out = new ByteStream();
generate(list, 0, out);
return out.toByteArray();
}
private static <K> void generate(ArrayList<Integer> list, int level, ByteStream out) {
private static void generate(ArrayList<Integer> list, int level, ByteStream out) {
int size = list.size();
if (size <= 1) {
out.write((byte) size);
......
......@@ -528,7 +528,7 @@ public class MinimalPerfectHash<K> {
return (x & (-1 >>> 1)) % size;
}
private static <K> int hash(int x, int level, int offset, int size) {
private static int hash(int x, int level, int offset, int size) {
x += level + offset * 32;
x = ((x >>> 16) ^ x) * 0x45d9f3b;
x = ((x >>> 16) ^ x) * 0x45d9f3b;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论