public class StringHashing extends Object
|Modifier and Type||Method and Description|
Encodes the length of the string in UTF-16 code units, then the UTF-16 code units of the string.
public static void hashStringAndLength(com.google.common.hash.Hasher hasher, String string)
Useful to ensure hash codes are different when multiple strings are hashed in order ("foo" then "bar" should hash differently from "foobar").