Queue class

Queue to execute Futures in order. It awaits each future before executing the next one.

Constructors

Queue({Duration? delay, int parallel = 1, Duration? timeout})

Properties

activeItems Set<int>
getter/setter pair
delay Duration?
A delay to await between each future.
final
hashCode int
The hash code for this object.
no setterinherited
isCancelled bool
no setter
onComplete Future
Resolve when all items are complete
no setter
parallel int
The number of items to process at one time
getter/setter pair
remainingItems Stream<int>
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
timeout Duration?
A timeout before processing the next item in the queue
final

Methods

add<T>(Future<T> closure()) Future<T>
Adds the future-returning closure to the queue.
cancel() → void
Cancels the queue. Also cancels any unprocessed items throwing a QueueCancelledException
dispose() → void
Dispose of the queue
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited