| Modifier and Type | Field and Description |
|---|---|
| public static final Collection | EMPTY_COLLECTION
Deprecated
use
java. or java. instead
|
| public static final List | EMPTY_LIST
Deprecated
use
java. or java. instead
|
| public static final Map | EMPTY_MAP
Deprecated
use
java. or java. instead
|
| public static final float | |
| public static final int |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static <T> ArrayList | |
| public static < The map key type K, The map value type V> ConcurrentHashMap | Returns: The created map.The expected number of elements for the created map expectedNumberOfElements)Create a properly sized |
| public static < The map key type K, The map value type V> ConcurrentHashMap | Returns: The created map.The expected number of elements for the created map expectedNumberOfElements, float The collection load factor loadFactor)Create a properly sized |
| public static int | Returns: The proper size.The original map original)Given a map, determine the proper initial size for a new Map to hold the same number of values. |
| public static int | Returns: The proper size.The original set original)Given a set, determine the proper initial size for a new set to hold the same number of values. |
| public static int | Returns: The proper size.The number of elements to be stored. numberOfElements)Determine the proper initial size for a new collection in order for it to hold the given a number of elements. |
| public static boolean | |
| public static boolean | |
| public static boolean | |
| public static boolean | |
| public static boolean | |
| public static <X, Y> Map | |
| public static <K, V> HashMap | |
| public static <T> Set | |
| public static <K, V> Map | |
| public static <K, V, E> Map | |
| public static <K, V> Map | Returns: The sized map.The size to make the map. size)Build a properly sized map, especially handling load size and load factor to prevent immediate resizing. |
| public static <V> List | toSmallList(ArrayList<V> arrayList)
Use to convert ArrayList instances which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. |
| public static <K, V> Map | toSmallMap(final Map<K, V> map)
Use to convert Maps which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. |
| public static <T> Set | Returns: will never return null, but might return an immutable collection.Use to convert sets which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. |
| EMPTY_COLLECTION | back to summary |
|---|---|
| public static final Collection<E> EMPTY_COLLECTION
Deprecated use | |
| EMPTY_LIST | back to summary |
|---|---|
| public static final List<E> EMPTY_LIST
Deprecated use | |
| EMPTY_MAP | back to summary |
|---|---|
| public static final Map<K, V> EMPTY_MAP
Deprecated use | |
| LOAD_FACTOR | back to summary |
|---|---|
| public static final float LOAD_FACTOR | |
| MINIMUM_INITIAL_CAPACITY | back to summary |
|---|---|
| public static final int MINIMUM_INITIAL_CAPACITY | |
| CollectionHelper | back to summary |
|---|---|
| private CollectionHelper() | |
| arrayList | back to summary |
|---|---|
| public static <T> ArrayList | |
| concurrentMap | back to summary |
|---|---|
| public static <K, V> ConcurrentHashMap Create a properly sized
| |
| concurrentMap | back to summary |
|---|---|
| public static <K, V> ConcurrentHashMap Create a properly sized
| |
| determineProperSizing | back to summary |
|---|---|
| public static int determineProperSizing(Map<K, V> original) Given a map, determine the proper initial size for a new Map to hold the same number of values. Specifically we want to account for load size and load factor to prevent immediate resizing.
| |
| determineProperSizing | back to summary |
|---|---|
| public static int determineProperSizing(Set<E> original) Given a set, determine the proper initial size for a new set to hold the same number of values. Specifically we want to account for load size and load factor to prevent immediate resizing.
| |
| determineProperSizing | back to summary |
|---|---|
| public static int determineProperSizing(int numberOfElements) Determine the proper initial size for a new collection in order for it to hold the given a number of elements. Specifically we want to account for load size and load factor to prevent immediate resizing.
| |
| isEmpty | back to summary |
|---|---|
| public static boolean isEmpty(Collection<E> collection) | |
| isEmpty | back to summary |
|---|---|
| public static boolean isEmpty(Map<K, V> map) | |
| isEmpty | back to summary |
|---|---|
| public static boolean isEmpty(Object[] objects) | |
| isNotEmpty | back to summary |
|---|---|
| public static boolean isNotEmpty(Collection<E> collection) | |
| isNotEmpty | back to summary |
|---|---|
| public static boolean isNotEmpty(Map<K, V> map) | |
| makeCopy | back to summary |
|---|---|
| public static <X, Y> Map | |
| makeCopy | back to summary |
|---|---|
| public static <K, V> HashMap | |
| makeCopy | back to summary |
|---|---|
| public static <T> Set | |
| makeMap | back to summary |
|---|---|
| public static <K, V> Map | |
| makeMap | back to summary |
|---|---|
| public static <K, V, E> Map | |
| mapOfSize | back to summary |
|---|---|
| public static <K, V> Map Build a properly sized map, especially handling load size and load factor to prevent immediate resizing. Especially helpful for copy map contents.
| |
| toSmallList | back to summary |
|---|---|
| public static <V> List Use to convert ArrayList instances which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. The returned List might be immutable, but there is no guarantee of this: consider it immutable but don't rely on this. The goal is to save memory. | |
| toSmallMap | back to summary |
|---|---|
| public static <K, V> Map Use to convert Maps which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. The returned Map might be immutable, but there is no guarantee of this: consider it immutable but don't rely on this. The goal is to save memory. | |
| toSmallSet | back to summary |
|---|---|
| public static <T> Set Use to convert sets which will be retained for a long time, such as for the lifetime of the Hibernate ORM instance. The returned Set might be immutable, but there is no guarantee of this: consider it immutable but don't rely on this. The goal is to save memory.
| |