hash

package
v0.0.0-...-6f9c769 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultSeed uint64 = 0xa0761d6478bd642f // s0

)

Variables

This section is empty.

Functions

func Bytes

func Bytes(b []byte) uint64

func F32

func F32(v float32) uint64

func F64

func F64(v float64) uint64

func FNV32

func FNV32(v uint32) uint32

func FNV32a

func FNV32a(v uint32) uint32

func FNV64

func FNV64(v uint64) uint64

func FNV64a

func FNV64a(v uint64) uint64

func Hash

func Hash(bytes unsafe.Pointer, length uint64, seed uint64) uint64

func HashBytes

func HashBytes(b []byte) uint64

func I16

func I16(v int16) uint64

func I32

func I32(v int32) uint64

func I64

func I64(v int64) uint64

func I8

func I8(v int8) uint64

func MakeSecret

func MakeSecret(seed uint64) [4]uint64

func Next

func Next() uint64

func NextFloat

func NextFloat() float64

func NextGaussian

func NextGaussian() float64

func SetSeed

func SetSeed(s uint64)

func String

func String(s string) uint64

func U16

func U16(v uint16) uint64

func U32

func U32(v uint32) uint64

func U64

func U64(v uint64) uint64

func U8

func U8(v uint8) uint64

func WithSecret

func WithSecret(bytes unsafe.Pointer, length uint64, secret *[4]uint64) uint64

Types

type Rand

type Rand struct {
	// contains filtered or unexported fields
}

func (*Rand) Next

func (w *Rand) Next() uint64

func (*Rand) NextFloat

func (w *Rand) NextFloat() float64

func (*Rand) NextGaussian

func (w *Rand) NextGaussian() float64

Jump to

Keyboard shortcuts

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