Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Clock ¶
type Clock struct {
// contains filtered or unexported fields
}
func NewClock ¶
func NewClock(tickerFactory TickerFactory, nowFunc func() int64) *Clock
type EvenTicker ¶
type EvenTicker struct {
// contains filtered or unexported fields
}
func NewEvenTicker ¶
func NewEvenTicker(atInterval uint, sleep func(time.Duration)) *EvenTicker
func (*EvenTicker) Add ¶
func (et *EvenTicker) Add(c chan time.Time)
func (*EvenTicker) ETA ¶
func (et *EvenTicker) ETA(nowNanosecond int64) float64
func (*EvenTicker) Remove ¶
func (et *EvenTicker) Remove(c chan time.Time)
func (*EvenTicker) Run ¶
func (et *EvenTicker) Run(nowNanosecond int64)
func (*EvenTicker) Stop ¶
func (et *EvenTicker) Stop()
type RealTickerFactory ¶
type RealTickerFactory struct { }
type TickerFactory ¶
type WaitTicker ¶
type WaitTicker struct {
// contains filtered or unexported fields
}
func NewWaitTicker ¶
func NewWaitTicker(atInterval uint) *WaitTicker
func (*WaitTicker) Add ¶
func (wt *WaitTicker) Add(c chan time.Time)
func (*WaitTicker) ETA ¶
func (wt *WaitTicker) ETA(now int64) float64
func (*WaitTicker) Remove ¶
func (wt *WaitTicker) Remove(c chan time.Time)
func (*WaitTicker) Run ¶
func (wt *WaitTicker) Run(nowNanosecond int64)
func (*WaitTicker) Stop ¶
func (wt *WaitTicker) Stop()
Click to show internal directories.
Click to hide internal directories.