hash

package
v1.6.0-beta.2 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2023 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 3 more Imports: 6 Imported by: 0

Documentation

Overview

Package hash provides hash functions

Index

Constants

View Source
const DefaultHashFuncName = "murmur3"

DefaultHashFuncName is the name of murmur3 hash function.

Variables

This section is empty.

Functions

func RegisterHashFunc

func RegisterHashFunc(name string, hashFunc HashFuncWithSeed)

RegisterHashFunc 注册hash函数

func WriteBuffer

func WriteBuffer(writer io.Writer, buf []byte) error

WriteBuffer 写入buffer

Types

type HashFuncWithSeed

type HashFuncWithSeed func([]byte, uint32) (uint64, error)

HashFuncWithSeed 可接受种子的hash函数

func GetHashFunc

func GetHashFunc(name string) (HashFuncWithSeed, error)

GetHashFunc 获取函数函数

Jump to

Keyboard shortcuts

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