Package org.camunda.bpm.engine.impl.util
Class CollectionUtil
java.lang.Object
org.camunda.bpm.engine.impl.util.CollectionUtil
helper/convience methods for working with collections.
- Author:
- Joram Barrez
- 
Method SummaryModifier and TypeMethodDescriptionstatic <S,T> void addCollectionToMapOfSets(Map<S, Set<T>> map, S key, Collection<T> values) static <S,T> void addToMapOfLists(Map<S, List<T>> map, S key, T value) static <S,T> void addToMapOfSets(Map<S, Set<T>> map, S key, T value) static <T> List<T>asArrayList(T[] values) Arrays.asList cannot be reliably used for SQL parameters on MyBatis < 3.3.0static <T> Set<T>asHashSet(T... elements) static <T> List<T>collectInList(Iterator<T> iterator) static booleanisEmpty(Collection<?> collection) static <S,T> void mergeMapsOfLists(Map<S, List<T>> map, Map<S, List<T>> toAdd) Chops a list into non-view sublists of length partitionSize.singletonMap(String key, Object value) Helper method that creates a singleton map.
- 
Method Details- 
singletonMapHelper method that creates a singleton map. Alternative for Collections.singletonMap(), since that method returns a generic typed map <K,T> depending on the input type, but we often need a <String, Object> map.
- 
asArrayListArrays.asList cannot be reliably used for SQL parameters on MyBatis < 3.3.0
- 
asHashSet
- 
addToMapOfLists
- 
mergeMapsOfLists
- 
addToMapOfSets
- 
addCollectionToMapOfSets
- 
partitionChops a list into non-view sublists of length partitionSize. Note: the argument list may be included in the result.
- 
collectInList
- 
isEmpty
 
-