- Test:
- verify lifecycle behaviour of threads managed by thread-wrapper.
- See also
- thread.hpp
-
ThreadWrapperBackground_test
-
ThreadWrapperJoin_test
Definition at line 61 of file thread-wrapper-lifecycle-test.cpp.
|
virtual void | run (Arg arg)=0 |
|
◆ defaultWrapperLifecycle()
void defaultWrapperLifecycle |
( |
| ) |
|
|
inlineprivate |
◆ verifyThreadLifecycleHooks()
void verifyThreadLifecycleHooks |
( |
| ) |
|
|
inlineprivate |
◆ demonstrateExplicitThreadLifecycle()
void demonstrateExplicitThreadLifecycle |
( |
| ) |
|
|
inlineprivate |
- Test:
- verify a special setup to start a thread explicitly and to track the thread's lifecycle state.
- use a component to encapsulate the thread
- this TestThread component is managed in a
unique_ptr
- thus it is explicitly possible to be not in running state
- when starting the TestThread, a lifecycle callback is bound
- at termination this callback will clear the unique_ptr
- thus allocation and running state is tied to the lifecycle
Definition at line 133 of file thread-wrapper-lifecycle-test.cpp.
The documentation for this class was generated from the following file: