Class SimpleIdentityHashSet


  • public final class SimpleIdentityHashSet
    extends java.lang.Object
    Identity hash set implementation optimized for JOL uses. Cuts corners where it can.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean add​(java.lang.Object o)  
      private static int capacity​(int expectedMaxSize)  
      private static int hash​(java.lang.Object x, int length)  
      private static int nextIndex​(int i, int len)  
      private boolean resize​(int newCapacity)  
      • Methods inherited from class java.lang.Object

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

      • table

        private java.lang.Object[] table
      • size

        private int size
    • Constructor Detail

      • SimpleIdentityHashSet

        public SimpleIdentityHashSet()
    • Method Detail

      • capacity

        private static int capacity​(int expectedMaxSize)
      • hash

        private static int hash​(java.lang.Object x,
                                int length)
      • nextIndex

        private static int nextIndex​(int i,
                                     int len)
      • add

        public boolean add​(java.lang.Object o)
      • resize

        private boolean resize​(int newCapacity)