documented (nearly) ever class
This commit is contained in:
+1
-3
@@ -27,9 +27,7 @@
|
||||
#include "task/taskthread.h"
|
||||
|
||||
/**
|
||||
* @brief The Task class
|
||||
*
|
||||
* A base class for background tasks running in Olive.
|
||||
* @brief A base class for background tasks running in Olive.
|
||||
*
|
||||
* Tasks are multithreaded by design (i.e. they will always spawn
|
||||
* a new thread and run in it).
|
||||
|
||||
+12
-1
@@ -27,7 +27,7 @@
|
||||
#include "task/task.h"
|
||||
|
||||
/**
|
||||
* @brief The TaskManager class
|
||||
* @brief An object that manages background Task objects, handling their start and end
|
||||
*
|
||||
* TaskManager handles the life of a Task object. After a new Task is created, it should be sent to TaskManager through
|
||||
* AddTask(). TaskManager will take ownership of the task and add it to a queue until it system resources are available
|
||||
@@ -99,8 +99,19 @@ public:
|
||||
public:
|
||||
AddTaskCommand(TaskPtr t, QUndoCommand* parent = nullptr);
|
||||
|
||||
/**
|
||||
* @brief Adds the Task to the TaskManager
|
||||
*
|
||||
* If there are available threads, TaskManager will start running it.
|
||||
*/
|
||||
virtual void redo() override;
|
||||
|
||||
/**
|
||||
* @brief Undoes adding the Task
|
||||
*
|
||||
* If the Task is running, it is cancelled. Then the Task is removed from the TaskManager and the Task's state is
|
||||
* reset.
|
||||
*/
|
||||
virtual void undo() override;
|
||||
|
||||
private:
|
||||
|
||||
@@ -26,9 +26,9 @@
|
||||
class Task;
|
||||
|
||||
/**
|
||||
* @brief The TaskThread class
|
||||
* @brief An internal class only used by Task.
|
||||
*
|
||||
* An internal class only used by Task. TaskThread is a simple QThread subclass designed to create a thread and run the
|
||||
* TaskThread is a simple QThread subclass designed to create a thread and run the
|
||||
* Task's Action() function. It also stores the result of Action() which can be read using result() when the thread
|
||||
* signals that it has finished().
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user