aboutsummaryrefslogtreecommitdiffstats
path: root/vespalib/src/vespa/vespalib/util/string_hash.h
blob: 8d7fe125cf7ccae8f09b1254f2d519a2985bb6ab (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

#include <vespa/vespalib/stllike/string.h>

namespace vespalib {

/**
 * simple string hashing function similar to the one used by Java.
 **/
double hash2d(const char *str, size_t len);
double hash2d(vespalib::stringref str);

} // namespace vespalib