Versions in this module Expand all Collapse all v1 v1.1.24 Mar 4, 2022 Changes in this version + func RegisterComponent() v1.1.23 Feb 22, 2022 v1.1.22 Feb 18, 2022 Changes in this version + const LoopForever + var GlobalTicker *time.Ticker + var Manager = &struct{ ... } + var Precision = time.Second + func AddTimer(t *Timer) + func Cron() + func RemoveTimer(id int64) + func SetTimerBacklog(c int) + type Component struct + func NewComponent() *Component + func (p *Component) Init() + func (p *Component) Name() string + func (p *Component) OnBeforeStop() + func (p *Component) OnStop() + type Condition interface + Check func(now time.Time) bool + type Func func() + type Timer struct + ID int64 + func NewCounterTimer(fn Func, interval, delay time.Duration, counter int) *Timer + func NewEveryDayTimer(fn Func, hour, minutes, seconds int) *Timer + func NewEveryHourTimer(fn Func, minute, second int) *Timer + func NewTimer(fn Func, interval, delay time.Duration) *Timer + func (t *Timer) SetCondition(condition Condition) + func (t *Timer) Stop()