Flutter Engine Uber Docs
Docs for the entire Flutter Engine repo.
 
Loading...
Searching...
No Matches
impeller::testing::TestPipelineCompileQueue Class Reference
Inheritance diagram for impeller::testing::TestPipelineCompileQueue:
impeller::PipelineCompileQueue

Public Member Functions

void PostJob (const fml::closure &job) override
 Post a compilation job to the worker task runner.
 
void OnJobAdded () override
 Called by PostJobForDescriptor after a job has been successfully added to the queue. Subclasses must implement this to define their scheduling strategy.
 
bool AddJobForTest (const PipelineDescriptor &desc, const fml::closure &job)
 
bool HasPendingJobsForTest ()
 
- Public Member Functions inherited from impeller::PipelineCompileQueue
 PipelineCompileQueue ()=default
 
virtual ~PipelineCompileQueue ()
 
 PipelineCompileQueue (const PipelineCompileQueue &)=delete
 
PipelineCompileQueueoperator= (const PipelineCompileQueue &)=delete
 
bool PostJobForDescriptor (const PipelineDescriptor &desc, const fml::closure &job)
 Post a compile job for the specified descriptor.
 
void PerformJobEagerly (const PipelineDescriptor &desc)
 If the task has not yet been done, perform it eagerly on the calling thread. This can be used in lieu of an idle wait for the task completion on the calling thread.
 

Additional Inherited Members

- Protected Member Functions inherited from impeller::PipelineCompileQueue
void DoOneJob ()
 Execute one pending compilation job from the queue.
 
bool AddJob (const PipelineDescriptor &desc, const fml::closure &job)
 Add a compilation job to the pending queue for the specified descriptor.
 
bool HasPendingJobs ()
 Check if there are any pending compilation jobs in the queue.
 

Detailed Description

Definition at line 15 of file pipeline_compile_queue_unittests.cc.

Member Function Documentation

◆ AddJobForTest()

bool impeller::testing::TestPipelineCompileQueue::AddJobForTest ( const PipelineDescriptor desc,
const fml::closure job 
)
inline

Definition at line 25 of file pipeline_compile_queue_unittests.cc.

25 {
26 return AddJob(desc, job);
27 }
bool AddJob(const PipelineDescriptor &desc, const fml::closure &job)
Add a compilation job to the pending queue for the specified descriptor.

References impeller::PipelineCompileQueue::AddJob().

◆ HasPendingJobsForTest()

bool impeller::testing::TestPipelineCompileQueue::HasPendingJobsForTest ( )
inline

Definition at line 29 of file pipeline_compile_queue_unittests.cc.

29{ return HasPendingJobs(); }
bool HasPendingJobs()
Check if there are any pending compilation jobs in the queue.

References impeller::PipelineCompileQueue::HasPendingJobs().

◆ OnJobAdded()

void impeller::testing::TestPipelineCompileQueue::OnJobAdded ( )
inlineoverridevirtual

Called by PostJobForDescriptor after a job has been successfully added to the queue. Subclasses must implement this to define their scheduling strategy.

The default implementation for duplicate descriptors is to run the job eagerly. Subclasses can override this behavior by checking for duplicates before calling the base class.

Implements impeller::PipelineCompileQueue.

Definition at line 23 of file pipeline_compile_queue_unittests.cc.

23{}

◆ PostJob()

void impeller::testing::TestPipelineCompileQueue::PostJob ( const fml::closure job)
inlineoverridevirtual

Post a compilation job to the worker task runner.

        This is a pure virtual function that must be implemented by
        subclasses. It is responsible for actually dispatching the
        job closure to the appropriate task runner for execution.
Parameters
[in]jobThe compilation job closure to post

Implements impeller::PipelineCompileQueue.

Definition at line 17 of file pipeline_compile_queue_unittests.cc.

17 {
18 if (job) {
19 job();
20 }
21 }

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