onDone method
Callback from the app when this task is done.
If dequeue
is true
the task is removed from the queue.
result
can specify the result obtained from this task, if available.
Implementation
@mustCallSuper
void onDone({bool dequeue = false, Data? result}) {
this.result = result;
state = UserTaskState.done;
AppTaskController().done(id, result);
if (dequeue) AppTaskController().dequeue(id);
// _removeExecutor();
}