26 void run(
void* classptr)
47 pthread_join(t_id, NULL);
79 template <
typename T,
void (T::*M)(
bool&, UINT16&)>
84 T* pt =
static_cast<T*
>(
pthis);
86 m_threadShouldRun =
true;
87 bool endThread =
false;
90 while ((m_threadShouldRun ==
true) && (endThread ==
false))
92 usleep(((
UINT32)sleepTimeMs) * 1000);
93 (pt->*M)(endThread, sleepTimeMs);
101 m_threadShouldRun =
false;
107 bool m_threadShouldRun;
258 #endif // SICKTHREAD_HPP
void * wrapper_prerun(void *)
pthread_t * get_thread_id()
virtual ~ThreadWrapperBase()
virtual void thread_entry()=0
friend void * wrapper_prerun(void *)
Wrapper class for posix threads.