#include <source/ariba/utility/transport/tcpip/protlib/threads.h>
Public Member Functions | |
ThreadStarter (uint32 count, const TParam ¶m) | |
~ThreadStarter () | |
void | start_processing () |
void | stop_processing () |
bool | sleepuntilstop () |
void | wait_until_stopped () |
void | abort_processing (bool kill=false) |
T * | get_thread_object () |
get a pointer to the thread object | |
bool | is_running () const |
Are all threads finished: TODO. | |
Private Attributes | |
T | thread_object |
The Thread object on which the threads run. | |
const TParam | thread_param |
For debugging, the name of the thread as given by TParam. | |
std::vector< pthread_t > | pthreads |
Contains the handles of all pthreads that we created. |
Note that the ThreadStarter template class is not thread-safe yet, so it may only be accessed by one thread at a time.
Definition at line 271 of file threads.h.
T* protlib::ThreadStarter< T, TParam >::get_thread_object | ( | ) | [inline] |
get a pointer to the thread object
Definition at line 283 of file threads.h.
Referenced by ariba::transport::tcpip::send(), and ariba::transport::tcpip::terminate().
bool protlib::ThreadStarter< T, TParam >::is_running | ( | ) | const [inline] |
std::vector<pthread_t> protlib::ThreadStarter< T, TParam >::pthreads [private] |
Contains the handles of all pthreads that we created.
Definition at line 296 of file threads.h.
Referenced by protlib::ThreadStarter< T, TParam >::abort_processing(), protlib::ThreadStarter< T, TParam >::start_processing(), and protlib::ThreadStarter< T, TParam >::ThreadStarter().
T protlib::ThreadStarter< T, TParam >::thread_object [private] |
The Thread object on which the threads run.
Definition at line 290 of file threads.h.
Referenced by protlib::ThreadStarter< T, TParam >::abort_processing(), protlib::ThreadStarter< TPoverTCP, TPoverTCPParam >::get_thread_object(), protlib::ThreadStarter< TPoverTCP, TPoverTCPParam >::is_running(), protlib::ThreadStarter< T, TParam >::sleepuntilstop(), protlib::ThreadStarter< T, TParam >::start_processing(), protlib::ThreadStarter< T, TParam >::stop_processing(), protlib::ThreadStarter< T, TParam >::wait_until_stopped(), and protlib::ThreadStarter< T, TParam >::~ThreadStarter().
const TParam protlib::ThreadStarter< T, TParam >::thread_param [private] |
For debugging, the name of the thread as given by TParam.
Definition at line 293 of file threads.h.
Referenced by protlib::ThreadStarter< T, TParam >::abort_processing(), protlib::ThreadStarter< T, TParam >::sleepuntilstop(), protlib::ThreadStarter< T, TParam >::start_processing(), protlib::ThreadStarter< T, TParam >::stop_processing(), and protlib::ThreadStarter< T, TParam >::wait_until_stopped().