Java Hash Calculate hashToLong(final byte[] hash)

Here you can find the source of hashToLong(final byte[] hash)

Description

hash To Long

License

Open Source License

Declaration

public static long hashToLong(final byte[] hash) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    /**//from   w  w  w  .  jav  a  2s  .  c o  m
     * @author sci4me
     */
    public static long hashToLong(final byte[] hash) {
        long ret = 0;
        for (int i = 5; i >= 0; i--)
            ret += (hash[i] & 0xFF) * Math.pow(256, 5 - i);
        return ret;
    }
}

Related

  1. hashpair(Object o1, Object o2)
  2. hashPoint(int hashlength, double fraction)
  3. hashSetSize(final int nrOfElements)
  4. hashThem(Object one, Object two)
  5. hashToFloat(int x, int y, long seed)
  6. hashToName(long l)
  7. hashV(Object... a)
  8. hashValueFor(final boolean b)
  9. toHash(Long number)