Flutter Engine
fml::DelayedTask Class Reference

#include <delayed_task.h>

Public Member Functions

 DelayedTask (size_t order, const fml::closure &task, fml::TimePoint target_time, fml::TaskSourceGrade task_source_grade)
 
 DelayedTask (const DelayedTask &other)
 
 ~DelayedTask ()
 
const fml::closureGetTask () const
 
fml::TimePoint GetTargetTime () const
 
fml::TaskSourceGrade GetTaskSourceGrade () const
 
bool operator> (const DelayedTask &other) const
 

Detailed Description

Definition at line 16 of file delayed_task.h.

Constructor & Destructor Documentation

◆ DelayedTask() [1/2]

fml::DelayedTask::DelayedTask ( size_t  order,
const fml::closure task,
fml::TimePoint  target_time,
fml::TaskSourceGrade  task_source_grade 
)

Definition at line 11 of file delayed_task.cc.

References ~DelayedTask().

15  : order_(order),
16  task_(task),
17  target_time_(target_time),
18  task_source_grade_(task_source_grade) {}

◆ DelayedTask() [2/2]

fml::DelayedTask::DelayedTask ( const DelayedTask other)
default

◆ ~DelayedTask()

fml::DelayedTask::~DelayedTask ( )
default

Referenced by DelayedTask().

Member Function Documentation

◆ GetTargetTime()

fml::TimePoint fml::DelayedTask::GetTargetTime ( ) const

Definition at line 28 of file delayed_task.cc.

Referenced by fml::MessageLoopTaskQueues::GetNextTaskToRun().

28  {
29  return target_time_;
30 }

◆ GetTask()

const fml::closure & fml::DelayedTask::GetTask ( ) const

Definition at line 24 of file delayed_task.cc.

Referenced by fml::MessageLoopTaskQueues::GetNextTaskToRun(), and fml::testing::TEST().

24  {
25  return task_;
26 }

◆ GetTaskSourceGrade()

fml::TaskSourceGrade fml::DelayedTask::GetTaskSourceGrade ( ) const

Definition at line 32 of file delayed_task.cc.

Referenced by fml::MessageLoopTaskQueues::GetNextTaskToRun(), and fml::TaskSource::RegisterTask().

32  {
33  return task_source_grade_;
34 }

◆ operator>()

bool fml::DelayedTask::operator> ( const DelayedTask other) const

Definition at line 36 of file delayed_task.cc.

36  {
37  if (target_time_ == other.target_time_) {
38  return order_ > other.order_;
39  }
40  return target_time_ > other.target_time_;
41 }

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