Documentation
¶
Index ¶
- Variables
- type IPartitioner
- type OrderPreservingPartitioner
- type RandomPartitioner
- func (r *RandomPartitioner) Compare(s1, s2 string) int
- func (r *RandomPartitioner) DecorateKey(key string) string
- func (r *RandomPartitioner) GetDefaultToken() string
- func (r *RandomPartitioner) GetToken(key string) string
- func (r *RandomPartitioner) Hash(key string) string
- func (r *RandomPartitioner) UndecorateKey(decoratedKey string) string
- type Range
Constants ¶
This section is empty.
Variables ¶
View Source
var (
RandomPartInstance = NewRandomPartitioner()
)
RandomPartInstance ...
Functions ¶
This section is empty.
Types ¶
type IPartitioner ¶
type IPartitioner interface {
DecorateKey(key string) string
UndecorateKey(decoreateddKey string) string
Compare(s1, s2 string) int
GetToken(key string) string
}
IPartitioner ...
type OrderPreservingPartitioner ¶
type OrderPreservingPartitioner struct{}
OrderPreservingPartitioner ...
func (*OrderPreservingPartitioner) Compare ¶
func (r *OrderPreservingPartitioner) Compare(s1, s2 string) int
Compare ...
func (*OrderPreservingPartitioner) DecorateKey ¶
func (r *OrderPreservingPartitioner) DecorateKey(key string) string
DecorateKey ...
func (*OrderPreservingPartitioner) GetToken ¶
func (r *OrderPreservingPartitioner) GetToken(key string) string
GetToken ...
func (*OrderPreservingPartitioner) UndecorateKey ¶
func (r *OrderPreservingPartitioner) UndecorateKey(decoratedKey string) string
UndecorateKey ...
type RandomPartitioner ¶
type RandomPartitioner struct {
}
RandomPartitioner ...
func (*RandomPartitioner) Compare ¶
func (r *RandomPartitioner) Compare(s1, s2 string) int
Compare ...
func (*RandomPartitioner) DecorateKey ¶
func (r *RandomPartitioner) DecorateKey(key string) string
DecorateKey ...
func (*RandomPartitioner) GetDefaultToken ¶
func (r *RandomPartitioner) GetDefaultToken() string
GetDefaultToken ...
func (*RandomPartitioner) GetToken ¶
func (r *RandomPartitioner) GetToken(key string) string
GetToken ...
func (*RandomPartitioner) UndecorateKey ¶
func (r *RandomPartitioner) UndecorateKey(decoratedKey string) string
UndecorateKey ...
Click to show internal directories.
Click to hide internal directories.