Class Timer
An interface for creating Timers.
Inheritance
System.Object
Timer
Namespace: Mannequin.Bindings
Assembly: Collapse.dll
Syntax
public static class Timer : object
Methods
After(Double, Closure)
Fire a callback after X seconds.
Declaration
public static PendingTimer After(double seconds, Closure callback)
Parameters
Type | Name | Description |
---|---|---|
System.Double | seconds | The number of seconds to wait before firing |
Closure | callback | The callback to fire |
Returns
Type | Description |
---|---|
PendingTimer | A Timer representing what was just set |
Cancel(PendingTimer)
Cancel a timer. See also: Cancel()
Declaration
public static void Cancel(PendingTimer t)
Parameters
Type | Name | Description |
---|---|---|
PendingTimer | t | The Timer to cancel |
Every(Double, Closure)
Fire a callback every X seconds.
Declaration
public static PendingTimer Every(double seconds, Closure callback)
Parameters
Type | Name | Description |
---|---|---|
System.Double | seconds | The number of seconds to wait before firing |
Closure | callback | The callback to fire |
Returns
Type | Description |
---|---|
PendingTimer | A Timer representing what was just set |