Gecode::Support::Thread::Run Class Reference
A real thread. More...
#include <gecode/support/thread.hpp>
Public Member Functions | |
| Run (Runnable *r) | |
| Create a new thread. | |
| void | exec (void) |
| Infinite loop for execution. | |
| void | run (Runnable *r) |
| Run a runnable object. | |
Static Public Member Functions | |
| static void * | operator new (size_t s) |
| Allocate memory from heap. | |
| static void | operator delete (void *p) |
| Free memory allocated from heap. | |
Public Attributes | |
| Run * | n |
| Next idle thread. | |
| std::atomic< Runnable * > | r |
| Runnable object to execute. | |
| Event | e |
| Event to wait for next runnable object to execute. | |
Detailed Description
A real thread.
Definition at line 216 of file thread.hpp.
Constructor & Destructor Documentation
◆ Run()
| Gecode::Support::Thread::Run::Run | ( | Runnable * | r | ) |
Create a new thread.
Definition at line 79 of file thread.cpp.
Member Function Documentation
◆ exec()
| void Gecode::Support::Thread::Run::exec | ( | void | ) |
Infinite loop for execution.
Definition at line 54 of file thread.cpp.
◆ run()
|
inline |
Run a runnable object.
Definition at line 172 of file thread.hpp.
◆ operator new()
|
inlinestatic |
Allocate memory from heap.
Definition at line 194 of file thread.hpp.
◆ operator delete()
|
inlinestatic |
Free memory allocated from heap.
Definition at line 190 of file thread.hpp.
Member Data Documentation
◆ n
| Run* Gecode::Support::Thread::Run::n |
Next idle thread.
Definition at line 219 of file thread.hpp.
◆ r
| std::atomic<Runnable*> Gecode::Support::Thread::Run::r |
Runnable object to execute.
Definition at line 221 of file thread.hpp.
◆ e
| Event Gecode::Support::Thread::Run::e |
Event to wait for next runnable object to execute.
Definition at line 223 of file thread.hpp.
The documentation for this class was generated from the following files:
- gecode/support/thread.hpp
- gecode/support/thread/thread.cpp
- gecode/support/thread/thread.hpp
