-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathEMBeThread.h
43 lines (33 loc) · 896 Bytes
/
EMBeThread.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*******************************************************
* Creator: Martin Rudefelt
* Portability: native
*-------------------------------------------------------
*
*******************************************************/
#include "EMGlobals.h"
#ifdef PLATFORM_BEOS
#ifndef __EM_BE_THREAD
#define __EM_BE_THREAD
#include "EMThread.h"
#include <OS.h>
class EMThreadListener;
class EMSemaphore;
class EMBeThread : public EMThread
{
public:
EMBeThread(const char* p_vpName, int32 p_vPriority, int32 p_vSleepTime);
~EMBeThread();
void Kill(bool p_vCalledFromThreadRun = false);
static status_t ThreadEntry(void* obj);
void Run(void);
void SetPriority(int32 p_vPriority);
void Sleep(int64 p_vMicroSeconds);
void Start();
void Suspend();
void WaitForThread();
private:
thread_id m_sThreadID;
EMSemaphore* m_opSemaphore;
};
#endif
#endif