FTXUI 6.1.9
C++ functional terminal UI.
|
#include <task_runner.hpp>
Public Member Functions | |
TaskRunner () | |
~TaskRunner () | |
auto | PostTask (Task task) -> void |
Schedules a task to be executed immediately. | |
auto | PostDelayedTask (Task task, std::chrono::steady_clock::duration duration) -> void |
Schedules a task to be executed after a certain duration. | |
auto | RunUntilIdle () -> std::optional< std::chrono::steady_clock::duration > |
Runs the tasks in the queue. | |
auto | Run () -> void |
bool | HasImmediateTasks () const |
size_t | ExecutedTasks () const |
Static Public Member Functions | |
static auto | Current () -> TaskRunner * |
Definition at line 12 of file task_runner.hpp.
TaskRunner | ( | ) |
Definition at line 13 of file task_runner.cpp.
~TaskRunner | ( | ) |
Definition at line 19 of file task_runner.cpp.
|
static |
Definition at line 24 of file task_runner.cpp.
auto PostTask | ( | Task | task | ) | -> void |
Schedules a task to be executed immediately.
Definition at line 29 of file task_runner.cpp.
auto PostDelayedTask | ( | Task | task, |
std::chrono::steady_clock::duration | duration ) -> void |
Schedules a task to be executed after a certain duration.
Definition at line 33 of file task_runner.cpp.
auto RunUntilIdle | ( | ) | -> std::optional<std::chrono::steady_clock::duration> |
Runs the tasks in the queue.
Runs the tasks in the queue, return the delay until the next delayed task can be executed.
Definition at line 40 of file task_runner.cpp.
auto Run | ( | ) | -> void |
Definition at line 62 of file task_runner.cpp.
|
inline |
Definition at line 34 of file task_runner.hpp.
|
inline |
Definition at line 36 of file task_runner.hpp.