We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents bb11d04 + ddfde51 commit 1a7c5a5Copy full SHA for 1a7c5a5
bloom.go
@@ -85,6 +85,12 @@ func New(m uint, k uint) *BloomFilter {
85
// functions. The data slice is not going to be reset.
86
func From(data []uint64, k uint) *BloomFilter {
87
m := uint(len(data) * 64)
88
+ return FromWithM(data, m, k)
89
+}
90
+
91
+// FromWithM creates a new Bloom filter with _m_ length, _k_ hashing functions.
92
+// The data slice is not going to be reset.
93
+func FromWithM(data []uint64, m, k uint) *BloomFilter {
94
return &BloomFilter{m, k, bitset.From(data)}
95
}
96
0 commit comments