List of usage examples for java.util.concurrent ConcurrentHashMap ConcurrentHashMap
public ConcurrentHashMap(Map<? extends K, ? extends V> m)
From source file:Main.java
public static <K, V> ConcurrentMap<K, V> newConcurrentMap(int initCap) { return new ConcurrentHashMap<K, V>(initCap); }
From source file:Main.java
public static <T> Set<T> newConcurentHashSet(int initialCapacity) { return Collections.newSetFromMap(new ConcurrentHashMap<T, Boolean>(initialCapacity)); }
From source file:Main.java
public static <K, V> ConcurrentMap<K, V> createConcurrentMap(Map<? extends K, ? extends V> map) { if (map == null) { return null; }//from w ww .j av a2 s .c o m return new ConcurrentHashMap<K, V>(map); }
From source file:Main.java
/** * new concurrentHashMap and initialCapacity * @param size/*from w w w . jav a 2 s .co m*/ * @return */ public static <K, V> ConcurrentHashMap<K, V> newConcurrentHashMap(int size) { return new ConcurrentHashMap<K, V>(size); }
From source file:Main.java
public static <K, V> ConcurrentHashMap<K, V> newConcurrentHashMap(int initialCapacity) { return new ConcurrentHashMap<K, V>(initialCapacity); }
From source file:Main.java
public static <K, V> ConcurrentMap<K, V> createConcurrentMap(int initialCapacity) { return new ConcurrentHashMap<K, V>(initialCapacity); }
From source file:Main.java
public static <K, V> ConcurrentMap<K, V> createConcurrentMap(int initial_capacity) { return new ConcurrentHashMap<K, V>(initial_capacity); }
From source file:Main.java
public static <K, V> ConcurrentHashMap<K, V> newConcurrentHashMap(Map<? extends K, ? extends V> other) { return new ConcurrentHashMap<K, V>(other); }
From source file:Main.java
public static <K, V> ConcurrentHashMap<K, V> newConcurrentHashMap(final int capacity) { return new ConcurrentHashMap<K, V>(capacity); }
From source file:Main.java
public static <K, V> ConcurrentHashMap<K, V> newConcurrentHashMap(final int initialCapacity) { return new ConcurrentHashMap<K, V>(initialCapacity); }