Documentation
¶
Index ¶
Constants ¶
View Source
const BBHashGamma = 10
BBHashGamma is as stated in the paper, the "best theoretical speed" is achieved with 2.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BBHash ¶
type BBHash struct {
// contains filtered or unexported fields
}
BBHash is hash function data.
func NewMinimalPerfectHash ¶
NewMinimalPerfectHash returns a new BBHash. It takes in the pre-hashed values as a parameter.
type ConstructedHashFunction ¶
type ConstructedHashFunction struct {
// contains filtered or unexported fields
}
A ConstructedHashFunction holds information about the built perfect hash function.
func Build ¶
func Build(keys []string) *ConstructedHashFunction
Build builds a perfect hash function from keys using the "Hash, displace, and compress". Ref: http://cmph.sourceforge.net/papers/esa09.pdf.
func (*ConstructedHashFunction) Get ¶
func (chf *ConstructedHashFunction) Get(s string) uint32
Get searches for s in t and returns its index.
Click to show internal directories.
Click to hide internal directories.