CFRunLoopAddTimer(_:_:_:)
Adds a CFRunLoopTimer object to a run loop mode.
Declaration
func CFRunLoopAddTimer(_ rl: CFRunLoop!, _ timer: CFRunLoopTimer!, _ mode: CFRunLoopMode!)Parameters
- rl:
The run loop to modify.
- timer:
The run loop timer to add.
- mode:
The run loop mode of
rlto which to addtimer. Use the constant Commonmodes to addtimerto the set of objects monitored by all the common modes.
Discussion
A run loop timer can be registered in only one run loop at a time, although it can be added to multiple run loop modes within that run loop.
If rl already contains timer in mode, this function does nothing.