FTXUI 7.0.3
C++ functional terminal UI.
Loading...
Searching...
No Matches
PendingTask Struct Reference

PendingTask 代表一個預計在特定時間或盡快執行的任務。 More...

#include <task_internal.hpp>

Public Member Functions

 PendingTask (Task t)
 
 PendingTask (Task t, std::chrono::steady_clock::duration duration)
 
bool operator< (const PendingTask &other) const
 

Public Attributes

Task task
 要執行的 task。
 
std::optional< std::chrono::steady_clock::time_point > time
 

Detailed Description

PendingTask 代表一個預計在特定時間或盡快執行的任務。

Definition at line 17 of file task_internal.hpp.

Constructor & Destructor Documentation

◆ PendingTask() [1/2]

PendingTask ( Task t)
inline

Definition at line 19 of file task_internal.hpp.

◆ PendingTask() [2/2]

PendingTask ( Task t,
std::chrono::steady_clock::duration duration )
inline

Definition at line 22 of file task_internal.hpp.

Member Function Documentation

◆ operator<()

bool operator< ( const PendingTask & other) const

根據時間比較兩個 PendingTask。 如果兩個任務都沒有時間,則視為相等。

Definition at line 7 of file task.cpp.

Member Data Documentation

◆ task

Task task

要執行的 task。

Definition at line 26 of file task_internal.hpp.

◆ time

std::optional<std::chrono::steady_clock::time_point> time

task 應該被執行的時間。如果時間為空,則該 task 應該盡快執行。

Definition at line 30 of file task_internal.hpp.


The documentation for this struct was generated from the following files: