Package net.runelite.cache.util
Class Djb2
- java.lang.Object
-
- net.runelite.cache.util.Djb2
-
public final class Djb2 extends Object
An implementation of thedjb2hash function.
-
-
Constructor Summary
Constructors Constructor Description Djb2()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static inthash(String str)An implementation of Dan Bernstein'sdjb2hash function which is slightly modified.
-
-
-
Method Detail
-
hash
public static int hash(String str)
An implementation of Dan Bernstein'sdjb2hash function which is slightly modified. Instead of the initial hash being 5381, it is zero.- Parameters:
str- The string to hash.- Returns:
- The hash code.
-
-