Documentation ¶
Overview ¶
Package ticker implements a ticker that can be stopped and re-started.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Ticker ¶
type Ticker struct { C chan time.Time // The channel on which ticks are delivered. // contains filtered or unexported fields }
A Ticker holds a channel that delivers ticks at intervals.
func New ¶
New returns a new ticker that ticks every d seconds. It adjusts the intervals or drops ticks to make up for slow receivers. The ticker is initially in the stopped state.
func (*Ticker) Start ¶
func (t *Ticker) Start()
Start (re-)starts the ticker. Ticks will be delivered on the ticker's channel until Stop is called.
Click to show internal directories.
Click to hide internal directories.