Project: QGIS

Version: 3.0.0

Feature: Task manager

Introduces a framework for creating background tasks, which are interacted with through a centralised manager

Adds new classes:
- QgsTask. An interface for long-running background tasks
- QgsTaskManager. Handles groups of tasks - also available as a QgsApplication member  for tracking application wide tasks

Add simple python method QgsTask.fromFunction for creation of tasks     from a function without having to create a QgsTask subclass

Support for dependent tasks

Cancelling a task on which others depend leads to all these other
tasks getting cancelled as well.

Add handling of dependent layers to task manager

If a task has dependent layers which are about to be removed,
the task will automatically be cancelled

QgsTasks can have subtasks

Now, a QgsTask can have subtask QgsTasks set by calling
QgsTask::addSubTask. Sub tasks can have their own set of
dependent tasks.

Subtasks are not visible to users, and users only see the overall
progress and status of the parent task.

This allows creation of tasks which are themselves built off
many smaller component tasks. The task manager will still handle
firing up and scheduling the subtasks, so eg subtasks can run
in parallel (if their dependancies allow this).

Subtasks can themselves have subtasks.

This change is designed to allow the processing concept of
algorithms and modeller algorithms to be translatable
directly to the task manager architecture.

This feature was funded by QGIS Grant Program

This feature was developed by Nyall Dawson (North Road)