aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2019-01-17 09:59:03 +0100
committerDimitri Sokolyuk <demon@dim13.org>2019-01-17 09:59:03 +0100
commitf45f307a647773f9489a8737e1ba796b36e8332c (patch)
tree4f7bdd9f6a594e203bfd16a09d6c0c919634816a
parenta09cffcde579451343e9ab9a614cf6a9b65ed812 (diff)
...
-rw-r--r--internal/hash/hash.go10
1 files changed, 7 insertions, 3 deletions
diff --git a/internal/hash/hash.go b/internal/hash/hash.go
index 8662817..861dd90 100644
--- a/internal/hash/hash.go
+++ b/internal/hash/hash.go
@@ -8,14 +8,18 @@ const (
)
type Hash struct {
- file *os.File
- hash func([]byte) uint32
+ file *os.File
+ BSize uint // hash table bucket size
+ FFactor uint // desired density within the hash table
+ CacheSize uint // suggested maximum size in bytes
+ LOrder uint // byte order for integers in metadata
+ Hash func([]byte) uint32 // user defined hash function
}
func New(file *os.File) *Hash {
return &Hash{
file: file,
- hash: defaultHash,
+ Hash: defaultHash,
}
}