From 25aa22b560ef8561acc5d6ff2437452456f3e96c Mon Sep 17 00:00:00 2001 From: JFronny Date: Sun, 5 Jun 2022 15:34:27 +0200 Subject: [PATCH] [commons] Return murmur2 hash as long --- src/main/java/io/gitlab/jfronny/commons/HashUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/io/gitlab/jfronny/commons/HashUtils.java b/src/main/java/io/gitlab/jfronny/commons/HashUtils.java index 4d3528e..435f122 100644 --- a/src/main/java/io/gitlab/jfronny/commons/HashUtils.java +++ b/src/main/java/io/gitlab/jfronny/commons/HashUtils.java @@ -27,7 +27,7 @@ public class HashUtils { return formatter.toString(); } - public static String murmur2(byte[] data) { + public static long murmur2(byte[] data) { final int m = 0x5bd1e995; final int r = 24; long k = 0x0L; @@ -105,6 +105,6 @@ public class HashUtils { h = h ^ (h >> 15); h = 0x00000000FFFFFFFFL & h; - return String.valueOf(h); + return h; } }