complete method
Completes operation with value
.
If value
is a Future the operation will complete
with the result of that Future
once it is available.
In that case isCompleted will be true
before the operation
is complete.
If the type T
is not nullable value
may be not be omitted or null
.
This method may not be called after either complete or completeError has been called once. The isCompleted is true when either of these methods have been called.
Implementation
@override
void complete([value]) async {
super.complete(value);
_isCompleted = isCanceled ? false : true;
}