Documentation ¶
Index ¶
Constants ¶
View Source
const ( // multiple of two MaxSlotSize = 8 // better if bucket size multiple of 2 DefaultBucketSize = MaxSlotSize )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTB ¶
type HTB struct {
// contains filtered or unexported fields
}
Implement simple hash table (not thread safe). Inspired from Go Map type implem (very simplified). I guess it is common approach but I looked example in Go source code. hash table (where key/value a string type) size of buckets should be multiple of 8 number slots in bucket 8 when slot overflow double size of buckets bucket size never reduced (after delete key)
Click to show internal directories.
Click to hide internal directories.