terminate method
Requests to terminate the execution of a computation.
Parameters:
force: Determines whether the execution of the computation will be terminate immediately or when control is yielded back to the event loop.
Implementation
@override
void terminate({bool force = false}) {
_isTerminationRequested = true;
_isolate?.kill(
priority: force ? Isolate.immediate : Isolate.beforeNextEvent);
}