GDAL
Public Member Functions | List of all members
CPLJobQueue Class Reference

Job queue. More...

#include <cpl_worker_thread_pool.h>

Public Member Functions

CPLWorkerThreadPoolGetPool ()
 Return the owning worker thread pool.
 
bool SubmitJob (CPLThreadFunc pfnFunc, void *pData)
 Queue a new job.
 
void WaitCompletion (int nMaxRemainingJobs=0)
 Wait for completion of part or whole jobs.
 

Detailed Description

Job queue.

Member Function Documentation

◆ SubmitJob()

bool CPLJobQueue::SubmitJob ( CPLThreadFunc  pfnFunc,
void *  pData 
)

Queue a new job.

Parameters
pfnFuncFunction to run for the job.
pDataUser data to pass to the job function.
Returns
true in case of success.

◆ WaitCompletion()

void CPLJobQueue::WaitCompletion ( int  nMaxRemainingJobs = 0)

Wait for completion of part or whole jobs.

Parameters
nMaxRemainingJobsMaximum number of pendings jobs that are allowed in the queue after this method has completed. Might be 0 to wait for all jobs.

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