Liferay 7.0-ce-b4

com.liferay.portal.kernel.util
Class SetUtil

java.lang.Object
  extended by com.liferay.portal.kernel.util.SetUtil
Direct Known Subclasses:
SetUtil

public class SetUtil
extends Object


Constructor Summary
SetUtil()
           
 
Method Summary
static Set<Boolean> fromArray(boolean[] array)
           
static Set<Byte> fromArray(byte[] array)
           
static Set<Character> fromArray(char[] array)
           
static Set<Double> fromArray(double[] array)
           
static
<E> Set<E>
fromArray(E[] array)
           
static Set<Float> fromArray(float[] array)
           
static Set<Integer> fromArray(int[] array)
           
static Set<Long> fromArray(long[] array)
           
static Set<Short> fromArray(short[] array)
           
static
<E> Set<E>
fromCollection(Collection<? extends E> c)
           
static
<E> Set<E>
fromEnumeration(Enumeration<? extends E> enu)
           
static Set<String> fromFile(File file)
           
static Set<String> fromFile(String fileName)
           
static
<E> Set<E>
fromIterator(Iterator<E> itr)
           
static
<E> Set<E>
fromList(List<? extends E> array)
           
static Set<String> fromString(String s)
           
static
<T> Set<T>
intersect(Collection<T> collection1, Collection<T> collection2)
           
static Set<Long> intersect(long[] array1, long[] array2)
           
static boolean isEmpty(Set<?> set)
           
static boolean isNotEmpty(Set<?> set)
           
static
<T> Set<T>
symmetricDifference(Collection<T> collection1, Collection<T> collection2)
           
static Set<Long> symmetricDifference(long[] array1, long[] array2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SetUtil

public SetUtil()
Method Detail

fromArray

public static Set<Boolean> fromArray(boolean[] array)

fromArray

public static Set<Byte> fromArray(byte[] array)

fromArray

public static Set<Character> fromArray(char[] array)

fromArray

public static Set<Double> fromArray(double[] array)

fromArray

public static <E> Set<E> fromArray(E[] array)

fromArray

public static Set<Float> fromArray(float[] array)

fromArray

public static Set<Integer> fromArray(int[] array)

fromArray

public static Set<Long> fromArray(long[] array)

fromArray

public static Set<Short> fromArray(short[] array)

fromCollection

public static <E> Set<E> fromCollection(Collection<? extends E> c)

fromEnumeration

public static <E> Set<E> fromEnumeration(Enumeration<? extends E> enu)

fromFile

public static Set<String> fromFile(File file)
                            throws IOException
Throws:
IOException

fromFile

public static Set<String> fromFile(String fileName)
                            throws IOException
Throws:
IOException

fromIterator

public static <E> Set<E> fromIterator(Iterator<E> itr)

fromList

public static <E> Set<E> fromList(List<? extends E> array)

fromString

public static Set<String> fromString(String s)

intersect

public static <T> Set<T> intersect(Collection<T> collection1,
                                   Collection<T> collection2)

intersect

public static Set<Long> intersect(long[] array1,
                                  long[] array2)

isEmpty

public static boolean isEmpty(Set<?> set)

isNotEmpty

public static boolean isNotEmpty(Set<?> set)

symmetricDifference

public static <T> Set<T> symmetricDifference(Collection<T> collection1,
                                             Collection<T> collection2)

symmetricDifference

public static Set<Long> symmetricDifference(long[] array1,
                                            long[] array2)

Liferay 7.0-ce-b4