Class ImmutableShortMapKeySet

    • Field Detail

      • keys

        private final short[] keys
      • occupiedWithData

        private final int occupiedWithData
      • containsZeroKey

        private final boolean containsZeroKey
      • containsOneKey

        private final boolean containsOneKey
    • Constructor Detail

      • ImmutableShortMapKeySet

        ImmutableShortMapKeySet​(short[] keys,
                                int occupiedWithData,
                                boolean containsZeroKey,
                                boolean containsOneKey)
    • Method Detail

      • isEmptyKey

        private static boolean isEmptyKey​(short key)
      • isRemovedKey

        private static boolean isRemovedKey​(short key)
      • isNonSentinel

        private static boolean isNonSentinel​(short key)
      • shortIterator

        public ShortIterator shortIterator()
        Description copied from interface: ShortIterable
        Returns a primitive iterator that can be used to iterate over the ShortIterable in an imperative style.
        Specified by:
        shortIterator in interface ShortIterable
      • toArray

        public short[] toArray()
        Description copied from interface: ShortIterable
        Converts the ShortIterable to a primitive short array.
        Specified by:
        toArray in interface ShortIterable
      • toArray

        public short[] toArray​(short[] array)
        Description copied from interface: ShortIterable
        Converts the ShortIterable to a primitive short array. If the collection fits into the provided array it is used to store its elements and is returned from the method, otherwise a new array of the appropriate size is allocated and returned. If the iterable is empty, the target array is returned unchanged.
        Specified by:
        toArray in interface ShortIterable
      • contains

        public boolean contains​(short value)
        Description copied from interface: ShortIterable
        Returns true if the value is contained in the ShortIterable, and false if it is not.
        Specified by:
        contains in interface ShortIterable
      • count

        public int count​(ShortPredicate predicate)
        Description copied from interface: ShortIterable
        Returns a count of the number of elements in the ShortIterable that return true for the specified predicate.
        Specified by:
        count in interface ShortIterable
      • anySatisfy

        public boolean anySatisfy​(ShortPredicate predicate)
        Description copied from interface: ShortIterable
        Returns true if any of the elements in the ShortIterable return true for the specified predicate, otherwise returns false.
        Specified by:
        anySatisfy in interface ShortIterable
      • allSatisfy

        public boolean allSatisfy​(ShortPredicate predicate)
        Description copied from interface: ShortIterable
        Returns true if all of the elements in the ShortIterable return true for the specified predicate, otherwise returns false.
        Specified by:
        allSatisfy in interface ShortIterable
      • noneSatisfy

        public boolean noneSatisfy​(ShortPredicate predicate)
        Description copied from interface: ShortIterable
        Returns true if none of the elements in the ShortIterable return true for the specified predicate, otherwise returns false.
        Specified by:
        noneSatisfy in interface ShortIterable
      • writeReplace

        private java.lang.Object writeReplace()
      • probe

        int probe​(short element)
      • probeTwo

        int probeTwo​(short element,
                     int removedIndex)
      • probeThree

        int probeThree​(short element,
                       int removedIndex)
      • spreadAndMask

        int spreadAndMask​(short element)
      • spreadTwoAndMask

        int spreadTwoAndMask​(short element)
      • mask

        private int mask​(int spread)