DurationExtensions extension

Extensions on num to easily construct Duration instances and delay execution.

on

Properties

days → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in days.
no setter
hours → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in hours.
no setter
microseconds → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in microseconds.
no setter
milliseconds → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in milliseconds.
no setter
minutes → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in minutes.
no setter
seconds → Duration

Available on num, provided by the DurationExtensions extension

Creates a Duration in seconds.
no setter

Methods

delay([FutureOr<void> callback()?]) → Future<void>

Available on num, provided by the DurationExtensions extension

Returns a Future that completes after this duration in seconds (or optional milliseconds).
delayMs([FutureOr<void> callback()?]) → Future<void>

Available on num, provided by the DurationExtensions extension

Returns a Future that completes after this duration in milliseconds.