Mono Class Library: System.Threading.Timer Overview | MembersSystem.Threading.Timer Constructor |
Constructs and initializes a new instance of the Timer class. [Edit]
|
- callback
- A System.Threading.TimerCallback delegate. [Edit]
- state
- A object containing application-specific information relevant to the methods invoked by callback, or null. [Edit]
- dueTime
- A int containing the amount of time to delay before callback invokes its methods, in milliseconds. Specify Timeout.Infinite to prevent the timer from starting. Specify zero to start the timer immediately. [Edit]
- period
- A int containing the time interval between invocations of the methods referenced by callback, in milliseconds. Specify Timeout.Infinite to disable periodic signaling. [Edit]
Type Reason ArgumentOutOfRangeException dueTime or period is negative and is not equal to Timeout.Infinite. [Edit] ArgumentNullException callback is a null reference. [Edit]
callback invokes its methods once after dueTime elapses, and then invokes its methods each time the period time interval elapses.
If dueTime is zero, callback performs its first invocation immediately. If dueTime is Timeout.Infinite, callback does not invoke its methods; the timer is disabled, but can be re-enabled using the Timer.Change(int, int) method.
If period is zero or Timeout.Infinite and dueTime is not Timeout.Infinite, callback invokes its methods exactly once; the periodic behavior of the timer is disabled, but can be re-enabled using the Timer.Change(int, int) method.
[Edit]
Namespace: System.Threading
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0