summaryrefslogtreecommitdiffstats
path: root/Source/cmWorkerPool.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmWorkerPool.h')
-rw-r--r--Source/cmWorkerPool.h23
1 files changed, 12 insertions, 11 deletions
diff --git a/Source/cmWorkerPool.h b/Source/cmWorkerPool.h
index 0fb6707..9082d7f 100644
--- a/Source/cmWorkerPool.h
+++ b/Source/cmWorkerPool.h
@@ -28,7 +28,8 @@ public:
void reset();
bool error() const
{
- return (ExitStatus != 0) || (TermSignal != 0) || !ErrorMessage.empty();
+ return (this->ExitStatus != 0) || (this->TermSignal != 0) ||
+ !this->ErrorMessage.empty();
}
std::int64_t ExitStatus = 0;
@@ -60,7 +61,7 @@ public:
* - no jobs later in the queue will be processed before this job was
* processed
*/
- bool IsFence() const { return Fence_; }
+ bool IsFence() const { return this->Fence_; }
protected:
/**
@@ -80,13 +81,13 @@ public:
* Get the worker pool.
* Only valid during the JobT::Process() call!
*/
- cmWorkerPool* Pool() const { return Pool_; }
+ cmWorkerPool* Pool() const { return this->Pool_; }
/**
* Get the user data.
* Only valid during the JobT::Process() call!
*/
- void* UserData() const { return Pool_->UserData(); };
+ void* UserData() const { return this->Pool_->UserData(); };
/**
* Get the worker index.
@@ -95,7 +96,7 @@ public:
* Concurrently processing jobs will never have the same WorkerIndex().
* Only valid during the JobT::Process() call!
*/
- unsigned int WorkerIndex() const { return WorkerIndex_; }
+ unsigned int WorkerIndex() const { return this->WorkerIndex_; }
/**
* Run an external read only process.
@@ -111,8 +112,8 @@ public:
//! Worker thread entry method.
void Work(cmWorkerPool* pool, unsigned int workerIndex)
{
- Pool_ = pool;
- WorkerIndex_ = workerIndex;
+ this->Pool_ = pool;
+ this->WorkerIndex_ = workerIndex;
this->Process();
}
@@ -150,7 +151,7 @@ public:
{
public:
//! Does nothing
- void Process() override { Pool()->Abort(); }
+ void Process() override { this->Pool()->Abort(); }
};
public:
@@ -161,7 +162,7 @@ public:
/**
* Number of worker threads.
*/
- unsigned int ThreadCount() const { return ThreadCount_; }
+ unsigned int ThreadCount() const { return this->ThreadCount_; }
/**
* Set the number of worker threads.
@@ -184,7 +185,7 @@ public:
*
* Only valid during Process().
*/
- void* UserData() const { return UserData_; }
+ void* UserData() const { return this->UserData_; }
// -- Job processing interface
@@ -212,7 +213,7 @@ public:
template <class T, typename... Args>
bool EmplaceJob(Args&&... args)
{
- return PushJob(cm::make_unique<T>(std::forward<Args>(args)...));
+ return this->PushJob(cm::make_unique<T>(std::forward<Args>(args)...));
}
private: