Documentation
¶
Overview ¶
Package xxhash implements the 32-bit variant of xxHash (XXH32) as described at https://xxhash.com/.
Package xxhash implements the 64-bit variant of xxHash (XXH64) as described at https://xxhash.com/.
Index ¶
- func Sum32(b []byte) uint32
- func Sum64(b []byte) uint64
- type Digest32
- func (d *Digest32) BlockSize() int
- func (d *Digest32) MarshalBinary() ([]byte, error)
- func (d *Digest32) Reset()
- func (d *Digest32) ResetWithSeed(seed uint32)
- func (d *Digest32) Size() int
- func (d *Digest32) Sum(b []byte) []byte
- func (d *Digest32) Sum32() uint32
- func (d *Digest32) UnmarshalBinary(b []byte) error
- func (d *Digest32) Write(b []byte) (n int, err error)
- type Digest64
- func (d *Digest64) BlockSize() int
- func (d *Digest64) MarshalBinary() ([]byte, error)
- func (d *Digest64) Reset()
- func (d *Digest64) ResetWithSeed(seed uint64)
- func (d *Digest64) Size() int
- func (d *Digest64) Sum(b []byte) []byte
- func (d *Digest64) Sum64() uint64
- func (d *Digest64) UnmarshalBinary(b []byte) error
- func (d *Digest64) Write(b []byte) (n int, err error)
- type Uint128
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Digest32 ¶
type Digest32 struct {
// contains filtered or unexported fields
}
Digest32 implements hash.Hash32.
Note that a zero-valued Digest32 is not ready to receive writes. Call Reset or create a Digest32 using New32 before calling other methods.
func New32WithSeed ¶
New32WithSeed creates a new Digest32 with the given seed.
func (*Digest32) MarshalBinary ¶
MarshalBinary implements the encoding.BinaryMarshaler interface.
func (*Digest32) Reset ¶
func (d *Digest32) Reset()
Reset clears the Digest32's state so that it can be reused. It uses a seed value of zero.
func (*Digest32) ResetWithSeed ¶
ResetWithSeed clears the Digest32's state so that it can be reused. It uses the given seed to initialize the state.
func (*Digest32) UnmarshalBinary ¶
UnmarshalBinary implements the encoding.BinaryUnmarshaler interface.
type Digest64 ¶
type Digest64 struct {
// contains filtered or unexported fields
}
Digest64 implements hash.Hash64.
Note that a zero-valued Digest64 is not ready to receive writes. Call Reset or create a Digest64 using New before calling other methods.
func NewWithSeed64 ¶
NewWithSeed64 creates a new Digest64 with the given seed.
func (*Digest64) MarshalBinary ¶
MarshalBinary implements the encoding.BinaryMarshaler interface.
func (*Digest64) Reset ¶
func (d *Digest64) Reset()
Reset clears the Digest's state so that it can be reused. It uses a seed value of zero.
func (*Digest64) ResetWithSeed ¶
ResetWithSeed clears the Digest's state so that it can be reused. It uses the given seed to initialize the state.
func (*Digest64) UnmarshalBinary ¶
UnmarshalBinary implements the encoding.BinaryUnmarshaler interface.
type Uint128 ¶
type Uint128 struct {
Hi, Lo uint64
}