public class CollectionHelper
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static <V> java.util.Set<V> |
difference(java.util.Set<V> set1,
java.util.Set<V> set2)
Deprecated.
renamed to
differenceMutable(Set, Set) to clarify |
static <V> java.util.Set<V> |
differenceMutable(java.util.Set<V> set1,
java.util.Set<V> set2)
Returns the difference of two sets (S1\S2).
|
static <V> java.util.Set<V> |
intersection(java.util.Set<V> set1,
java.util.Set<V> set2)
Deprecated.
renamed to
intersectionMutable(Set, Set) to clarify |
static <V> java.util.Set<V> |
intersectionMutable(java.util.Set<V> set1,
java.util.Set<V> set2)
Returns the intersection of two sets.
|
public static <V> java.util.Set<V> intersectionMutable(java.util.Set<V> set1,
java.util.Set<V> set2)
Set.retainAll(java.util.Collection) but returns a new set
containing the elements of the intersection.set1 - the first set (can be null, interpreted as empty)set2 - the second set (can be null, interpreted as empty)@Deprecated
public static <V> java.util.Set<V> intersection(java.util.Set<V> set1,
java.util.Set<V> set2)
intersectionMutable(Set, Set) to clarifypublic static <V> java.util.Set<V> differenceMutable(java.util.Set<V> set1,
java.util.Set<V> set2)
Set.removeAll(java.util.Collection) but returns a
new set containing the elements of the difference.set1 - the first set (can be null, interpreted as empty)set2 - the second set (can be null, interpreted as empty)@Deprecated
public static <V> java.util.Set<V> difference(java.util.Set<V> set1,
java.util.Set<V> set2)
differenceMutable(Set, Set) to clarify