Package io.deephaven.enterprise.util
Class CollectionUtil
java.lang.Object
io.deephaven.enterprise.util.CollectionUtil
Utility methods for creating collections.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final SetThe universal set (immutable).static final byte[]static final double[]static final double[][]static final float[]static final int[]static final int[][]static final long[]static final Object[]static final short[]static final String[]static final String[][] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <K,V> Map<K, V> mapFromArray(Class<K> typeK, Class<V> typeV, boolean allowDuplicateKeys, Object... data) static <K,V> Map<K, V> mapFromArray(Class<K> typeK, Class<V> typeV, Object... data) static <K,V> Map<K, V> newSizedLinkedHashMap(int nEntries) Returns an emptyLinkedHashMapwith a big enough capacity such that the given number of entries can be added without resizing.static <E> Set<E>newSizedLinkedHashSet(int nEntries) Returns an emptyLinkedHashSetwith a big enough capacity such that the given number of entries can be added without resizing.static <E> Set<E>setFromArray(E... data) static <T> Set<T>Returns the universal set (immutable).
-
Field Details
-
ZERO_LENGTH_BYTE_ARRAY
public static final byte[] ZERO_LENGTH_BYTE_ARRAY -
ZERO_LENGTH_SHORT_ARRAY
public static final short[] ZERO_LENGTH_SHORT_ARRAY -
ZERO_LENGTH_INT_ARRAY
public static final int[] ZERO_LENGTH_INT_ARRAY -
ZERO_LENGTH_INT_ARRAY_ARRAY
public static final int[][] ZERO_LENGTH_INT_ARRAY_ARRAY -
ZERO_LENGTH_LONG_ARRAY
public static final long[] ZERO_LENGTH_LONG_ARRAY -
ZERO_LENGTH_FLOAT_ARRAY
public static final float[] ZERO_LENGTH_FLOAT_ARRAY -
ZERO_LENGTH_DOUBLE_ARRAY
public static final double[] ZERO_LENGTH_DOUBLE_ARRAY -
ZERO_LENGTH_DOUBLE_ARRAY_ARRAY
public static final double[][] ZERO_LENGTH_DOUBLE_ARRAY_ARRAY -
ZERO_LENGTH_OBJECT_ARRAY
-
ZERO_LENGTH_STRING_ARRAY
-
ZERO_LENGTH_STRING_ARRAY_ARRAY
-
UNIVERSAL_SET
The universal set (immutable). This set is serializable.
-
-
Constructor Details
-
CollectionUtil
public CollectionUtil()
-
-
Method Details
-
mapFromArray
-
mapFromArray
-
setFromArray
-
newSizedLinkedHashMap
Returns an emptyLinkedHashMapwith a big enough capacity such that the given number of entries can be added without resizing. -
newSizedLinkedHashSet
Returns an emptyLinkedHashSetwith a big enough capacity such that the given number of entries can be added without resizing. -
universalSet
Returns the universal set (immutable). This set is serializable.
-