startTimer

TimerHandle startTimer(nuint intervalMs, escaped delegate void(TimerHandle handle) callback)

Starts a repeating timer.

Remarks

The callback runs on a platform timer thread until stopTimer is called with the supplied handle. The callback is escaped because the timer may outlive the call to startTimer.

Returns

A non-default handle when the timer starts successfully; otherwise default.

Parameters

nuint
intervalMs

The number of milliseconds between callback invocations. A value of 0 does not start a timer.

escaped delegate void(TimerHandle handle)
callback

The function to invoke for each tick.

Generated with campc v0.4.0-preview.1+d50446ef951a6ed675f7086cf093dbc993f0041b.