DelayedCall constructor

DelayedCall(
  1. void action(),
  2. num delay, {
  3. int repeatCount = 1,
})

Creates a new DelayedCall.

The action function will be called after the specified delay (in seconds).

The optional repeatCount specifies the number of times the delayed call should be executed.

Implementation

DelayedCall(void Function() action, num delay, {this.repeatCount = 1})
    : _action = action {
  _totalTime = max(delay, 0.0001);
}