BaseExecutor<O> class

Class that runs the AsyncTasks in a random order

Constructors

BaseExecutor({List<AsyncTask<O>>? initialTasks, int maxConcurrentTasks = 1})
Class that runs the AsyncTasks in a random order

Properties

hashCode int
The hash code for this object.
no setterinherited
isDisposed bool
Returns true if Executor.dispose was called
no setterinherited
isDone bool
Returns true if the Executor has finished all its jobs
no setterinherited
isRunning bool
Returns true if the semaphore has some running tasks or some waiting tasks
no setterinherited
runningTasks int
Returns the number of tasks that are currently running
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
semaphore → Semaphore
final
tasks List<AsyncTask<O>>
final
waitingTasks int
Returns the number of tasks that are currently waiting
no setterinherited
waitUntilDone Future<void>
Returns when all the tasks are done
no setterinherited

Methods

addTask(AsyncTask<O> task) → void
Adds a new AsyncTask to the BaseExecutor
inherited
dispose() → void
Closes all the running AsyncTasks and disposes the Executor
inherited
getResult(int taskId) Future<O?>
Returns the Future that will complete when the task of id is finished
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerTasks() → void
inherited
start() → void
Executes all the AsyncTasks defined in the constructor with the _maxConcurrentTasks parameter specified
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited