aboutsummaryrefslogtreecommitdiffstats
path: root/vespajlib/src/main/java/com/yahoo/compress/Hasher.java
blob: 92a9ed26085dbdfafc12157e8540b7864a5d4d3f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.compress;

import net.openhft.hashing.LongHashFunction;

/**
 * Utility for hashing providing multiple hashing methods
 * @author baldersheim
 */
public class Hasher {
    /** Uses net.openhft.hashing.LongHashFunction.xx3() */
    public static long xxh3(byte [] data) {
        return LongHashFunction.xx3().hashBytes(data);
    }
}