Documentation ¶ Index ¶ type TaskTimer func NewTask(duration time.Duration, function func()) *TaskTimer func (t *TaskTimer) Pause() func (t *TaskTimer) Restart() func (t *TaskTimer) Running() bool func (t *TaskTimer) Start() func (t *TaskTimer) Stop() Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type TaskTimer ¶ type TaskTimer struct { // contains filtered or unexported fields } func NewTask ¶ func NewTask(duration time.Duration, function func()) *TaskTimer 新建定时器 func (*TaskTimer) Pause ¶ func (t *TaskTimer) Pause() 暂停定时器 func (*TaskTimer) Restart ¶ func (t *TaskTimer) Restart() 继续定时器 func (*TaskTimer) Running ¶ func (t *TaskTimer) Running() bool func (*TaskTimer) Start ¶ func (t *TaskTimer) Start() 启动定时器 func (*TaskTimer) Stop ¶ func (t *TaskTimer) Stop() 停止定时器 Source Files ¶ View all Source files task_timer.go Click to show internal directories. Click to hide internal directories.