ubiware.util
Class SetOperation

java.lang.Object
  extended by ubiware.util.SetOperation

public class SetOperation
extends java.lang.Object

Provides some common operations on sets 12.4.2010

Author:
Michael Cochez for UBIWARE project

Constructor Summary
SetOperation()
           
 
Method Summary
static
<T> java.util.Set<T>
intersect3Sets(java.util.Set<T> set1, java.util.Set<T> set2, java.util.Set<T> set3)
          Generates a set containing the elements which are present in all provided sets.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SetOperation

public SetOperation()
Method Detail

intersect3Sets

public static <T> java.util.Set<T> intersect3Sets(java.util.Set<T> set1,
                                                  java.util.Set<T> set2,
                                                  java.util.Set<T> set3)
Generates a set containing the elements which are present in all provided sets. If a set is null, it is ignored.

Type Parameters:
T - The type of the elemets in the sets.
Parameters:
set1 - the first set in the intersection
set2 - the second set in the intersection
set3 - the third set in the intersection
Returns:
the set containing the elements which were present in all three sets.