farmhash64

package
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 23, 2024 License: MIT Imports: 0 Imported by: 1

Documentation

Overview

Package farmhash64 implements the FarmHash64 hash function.

The code in this file is an extract from: https://github.com/dgryski/go-farm/commits/master

That is a golang translation of the Google's C++ code: https://github.com/google/farmhash

  • Copyright (c) 2014 Google, Inc.
  • Copyright (c) 2014 Damian Gryski
  • Copyright (c) 2016-2017 Nicola Asuni

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FarmHash32

func FarmHash32(s []byte) uint32

FarmHash32 returns a 32-bit fingerprint hash for a string. NOTE: This is NOT equivalent to the original Fingerprint32 function.

func FarmHash64

func FarmHash64(s []byte) uint64

FarmHash64 returns a 64-bit fingerprint hash for a string.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL