Class SetUtils


  • public final class SetUtils
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      SetUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean equivalentDisregardingSort​(java.util.Set a, java.util.Set b)  
      static int hashContentsDisregardingSort​(java.util.Set s)
      finds a hash value which takes into account the value of all elements, such that two sets for which equivalentDisregardingSort(a, b) returns true will hashContentsDisregardingSort() to the same value
      static java.util.Set oneElementUnmodifiableSet​(java.lang.Object elem)  
      static java.util.Set setFromArray​(java.lang.Object[] array)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SetUtils

        public SetUtils()
    • Method Detail

      • oneElementUnmodifiableSet

        public static java.util.Set oneElementUnmodifiableSet​(java.lang.Object elem)
      • setFromArray

        public static java.util.Set setFromArray​(java.lang.Object[] array)
      • equivalentDisregardingSort

        public static boolean equivalentDisregardingSort​(java.util.Set a,
                                                         java.util.Set b)
      • hashContentsDisregardingSort

        public static int hashContentsDisregardingSort​(java.util.Set s)
        finds a hash value which takes into account the value of all elements, such that two sets for which equivalentDisregardingSort(a, b) returns true will hashContentsDisregardingSort() to the same value