public UInt64 HashByteArray(byte[] b) { xxHash h = new xxHash(64); byte[] x = h.ComputeHash(b); return BitConverter.ToUInt64(x, 0); }
public UInt64 HashStringJaccard(String s, int iteration) { xxHash h = new xxHash(); byte[] x = h.ComputeHash(s); for (int i = 0; i < iteration; i++) { x = h.ComputeHash(x); } return BitConverter.ToUInt64(x, 0); }
public byte[] HashString(String s, int iteration) { xxHash h = new xxHash(64); byte[] x = h.ComputeHash(s); //lav et loop der bliver ved med at hashe den. for (int i = 0; i < iteration; i++) { x = h.ComputeHash(x); } return x; }