Task<A> class abstract

Abstract class Task that represents a computation that may produce a result of type A in the future.

Example:

Task<int> sampleTask = Task<int>(() => Future.value(10));

Constructors

Task(Future<A> task())
Factory constructor that creates a task from a computation.
factory

Properties

hashCode int
The hash code for this object.
read-onlyinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
task Future<A> Function()
The computation of this task represented as a Future.
read-only

Methods

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