Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Direction ¶
type HitCounter ¶
type HitCounter struct { Clock *Clock Count *RunningCount *server.Server }
func NewHitCounter ¶
func NewHitCounter(directions []Direction) *HitCounter
type RunningCount ¶
type RunningCount struct {
// contains filtered or unexported fields
}
RunningCount is a counter where every increment is temporary. After the duration has passed, the counter decrements.
func NewRunningCount ¶
func NewRunningCount(Granularity int, Duration time.Duration) *RunningCount
func (*RunningCount) Count ¶
func (r *RunningCount) Count() uint64
func (*RunningCount) Inc ¶
func (r *RunningCount) Inc()
Click to show internal directories.
Click to hide internal directories.