Class Hash

  • All Implemented Interfaces:
    java.util.function.LongToIntFunction

    public class Hash
    extends java.lang.Object
    implements java.util.function.LongToIntFunction
    This uses the Murmur3F (64-bit optimized) version of Murmur3, not as a checksum, but as a simple hash. It doesn't bother pushing the high-64 bits of input, since it only uses the lower 64 bits of output. It does, however, return the absolute value. This is to make it play nice with users and other libraries.
    • Constructor Summary

      Constructors 
      Constructor Description
      Hash()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int applyAsInt​(long value)  
      • Methods inherited from class java.lang.Object

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

      • Hash

        public Hash()
    • Method Detail

      • applyAsInt

        public int applyAsInt​(long value)
        Specified by:
        applyAsInt in interface java.util.function.LongToIntFunction