mirror of https://github.com/Icinga/icinga2.git
28 lines
304 B
C++
28 lines
304 B
C++
#ifndef I2_THREAD_H
|
|
#define I2_THREAD_H
|
|
|
|
namespace icinga
|
|
{
|
|
|
|
class thread
|
|
{
|
|
private:
|
|
#ifdef _WIN32
|
|
HANDLE m_Thread;
|
|
#else
|
|
pthread_t m_Thread;
|
|
#endif
|
|
|
|
public:
|
|
thread(void (*callback)(void *));
|
|
~thread(void);
|
|
|
|
void start(void);
|
|
void terminate(void);
|
|
void join(void);
|
|
};
|
|
|
|
}
|
|
|
|
#endif /* I2_THREAD_H */
|