The BlockingTaskExecutor is a task execution list, which executes tasks one after another. The difference to the TaskExecutor is that it only uses macro tasks and that task executions can be tracked by clients.

Example

import BlockingTaskExecutor from "apprt-core/BlockingTaskExecutor";
let executor = new BlockingTaskExecutor();
let task = function(){ doSomething(); };
// execute the task if others pushed before are finished.
let promise = executor.push(task);
promise.then((result)=> {...});

Accessors

Methods

Accessors

  • get length(): number
  • Number of waiting tasks.

    Returns number

Methods

  • Cancels all tasks in the queue, as well as the currently running one.

    Returns void

Generated using TypeDoc