scheduleTask<T> method
Future<T>
scheduleTask<T>(
- TaskCallback<
T> task, - Priority priority,
- ValueGetter<
bool> canIgnore, { - String? debugLabel,
- Flow? flow,
- String? id,
Implementation
Future<T> scheduleTask<T>(
TaskCallback<T> task, Priority priority, ValueGetter<bool> canIgnore,
{String? debugLabel, Flow? flow, String? id}) {
final TaskEntry<T> entry =
TaskEntry<T>(task, priority.value, canIgnore, debugLabel, flow, id: id);
_addTask(entry);
_ensureEventLoopCallback();
return entry.completer.future;
}