func (b *Buckets) Increment(bucket uint, delta int32) *Buckets {
	val := int32(b.getBits(bucket*uint(b.bucketSize), uint(b.bucketSize))) + delta
	if val > int32(b.max) {
		val = int32(b.max)
	} else if val < 0 {
		val = 0
	}
	b.setBits(uint32(bucket)*uint32(b.bucketSize), uint32(b.bucketSize), uint32(val))
	return b
}
Increment will increment the value in the specified bucket by the provided
delta. A bucket can be decremented by providing a negative delta. The value
is clamped to zero and the maximum bucket value. Returns itself to allow for
chaining.
package boom
import (
	"bytes"
	"encoding/binary"
	"io"
)
type Buckets struct {
	data       []byte
	bucketSize uint8
	max        uint8
	count      uint
}
func NewBuckets(count uint, bucketSize uint8) *Buckets {
	return &Buckets{
		count:      count,
		data:       make([]byte, (count*uint(bucketSize)+7)/8),
		bucketSize: bucketSize,
		max:        (1 << bucketSize) - 1,
	}
}
func (b *Buckets) MaxBucketValue() uint8 {
	return b.max
}
func (b *Buckets) Count() uint {
	return b.count
}