Class MurmurHash

java.lang.Object
org.apache.hadoop.hbase.util.Hash
org.apache.hadoop.hbase.util.MurmurHash

@Private @Stable public class MurmurHash extends Hash
This is a very fast, non-cryptographic hash suitable for general hash-based lookup. See http://murmurhash.googlepages.com/ for more details.

The C version of MurmurHash 2.0 found at that site was ported to Java by Andrzej Bialecki (ab at getopt org).

  • Field Details

  • Constructor Details

  • Method Details

    • getInstance

      public static Hash getInstance()
    • hash

      public <T> int hash(HashKey<T> hashKey, int seed)
      Description copied from class: Hash
      Calculate a hash using bytes from HashKey and the provided seed value.
      Specified by:
      hash in class Hash
      Parameters:
      hashKey - key to extract the hash
      seed - the seed value
      Returns:
      hash value