public class CollectionUtils extends Object
Constructor and Description |
---|
CollectionUtils() |
Modifier and Type | Method and Description |
---|---|
static HashMap<String,Integer> |
getOrCreateValue(HashMap<Integer,HashMap<String,Integer>> map,
Integer key) |
static HashSet<String> |
getOrCreateValue(Map<String,HashSet<String>> map,
String key) |
static ArrayList<String>[] |
getUniqueElements(Collection<? extends String> list1,
Collection<? extends String> list2)
Returns two ArrayLists, containing the elements only present in the first and second argument, respectively.
|
static ArrayList<String>[] |
getUniqueElements(String[] array1,
String[] array2) |
static int |
indexOf(ArrayList<String> list,
String value) |
static <E> ArrayList<E> |
toList(E... contents) |
public static ArrayList<String>[] getUniqueElements(Collection<? extends String> list1, Collection<? extends String> list2)
public static ArrayList<String>[] getUniqueElements(String[] array1, String[] array2)
public static HashSet<String> getOrCreateValue(Map<String,HashSet<String>> map, String key)
public static HashMap<String,Integer> getOrCreateValue(HashMap<Integer,HashMap<String,Integer>> map, Integer key)
public static <E> ArrayList<E> toList(E... contents)