BytesToBloom converts a byte slice to a bloom filter. It panics if b is not of suitable size.
(b []byte)
| 42 | // BytesToBloom converts a byte slice to a bloom filter. |
| 43 | // It panics if b is not of suitable size. |
| 44 | func BytesToBloom(b []byte) Bloom { |
| 45 | var bloom Bloom |
| 46 | bloom.SetBytes(b) |
| 47 | return bloom |
| 48 | } |
| 49 | |
| 50 | // SetBytes sets the content of b to the given bytes. |
| 51 | // It panics if d is not of suitable size. |