Interface ITimerFactory
Defines a factory for ITimer.
public interface ITimerFactory
- Extension Methods
Methods
Create(TimerCallback, int, int, object?)
Create a new timer.
ITimer Create(TimerCallback callback, int dueTime, int period, object? state = null)
Parameters
callback
TimerCallbackA System.Threading.TimerCallback delegate representing a method to be executed.
dueTime
intThe amount of time to delay before callback is invoked, in milliseconds. Specify System.Threading.Timeout.Infinite to prevent the timer from starting. Specify zero (0) to start the timer immediately.
period
intThe time interval between invocations of callback, in milliseconds. Specify System.Threading.Timeout.Infinite to disable periodic signaling.
state
objectOptionally an object containing information to be used by the callback method, or null.