scala.util
JenkinsHash
object
JenkinsHash extends AnyRef
Value Members
-
val
MAX_VALUE: Long
-
def
equals(arg0: Any): Boolean
-
def
hash(buffer: Array[Byte], initialValue: Long): Long
-
def
hashCode(): Int
-
def
hashSeq(xs: Seq[Any]): Int
-
def
toString(): String
Original algorithm due to Bob Jenkins. http://burtleburtle.net/bob/c/lookup3.c Scala version partially adapted from java version by Gray Watson. http://256.com/sources/jenkins_hash_java/JenkinsHash.java
This is based on the 1996 version, not the 2006 version, and could most likely stand some improvement; the collision rate is negligible in my tests, but performance merits investigation.