Documentation
¶
Index ¶
Constants ¶
View Source
const ( LifeTime = 1800 PrecomputedLen = 64 HalfLife = 60 Lambda = math.Ln2 / HalfLife )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DynamicBanScore ¶
type DynamicBanScore struct {
// contains filtered or unexported fields
}
func (*DynamicBanScore) Increase ¶
func (dynamicBanScore *DynamicBanScore) Increase(persistent, transient uint32) uint32
func (*DynamicBanScore) Int ¶
func (dynamicBanScore *DynamicBanScore) Int() uint32
func (*DynamicBanScore) Reset ¶
func (dynamicBanScore *DynamicBanScore) Reset()
func (*DynamicBanScore) String ¶
func (dynamicBanScore *DynamicBanScore) String() string
type Int64Sorter ¶
type Int64Sorter []int64
func (Int64Sorter) Len ¶
func (sorter Int64Sorter) Len() int
func (Int64Sorter) Less ¶
func (sorter Int64Sorter) Less(i, j int) bool
func (Int64Sorter) Swap ¶
func (sorter Int64Sorter) Swap(i, j int)
type LRUCache ¶
type LRUCache struct { Length int // contains filtered or unexported fields }
func NewLRUCache ¶
Click to show internal directories.
Click to hide internal directories.