70 if (timeout == 0xffffffff)
81 DWORD returnCode = WaitForSingleObject(
mhThreadHandle, (DWORD)timeout);
83 if (returnCode == WAIT_TIMEOUT)
88 else if (returnCode != WAIT_OBJECT_0)
137 if (returnCode == WAIT_OBJECT_0)
178 switch (threadPriority)
190 success = SetThreadPriority(
mhThreadHandle, THREAD_PRIORITY_TIME_CRITICAL)?
true :
false;
193 success = SetThreadPriority(
mhThreadHandle, THREAD_PRIORITY_ABOVE_NORMAL)?
true :
false;
209 if(pTheadPPriority ==
NULL)
244 if (pThreadImpl ==
NULL)
279 return uint64_t(GetCurrentThreadId());
Declares the AJADebug class.
#define AJA_ASSERT(_expression_)
static uint64_t GetThreadId()
AJAStatus Attach(AJAThreadFunction *pThreadFunction, void *pUserContext)
AJAThreadPriority mPriority
void AJAThreadFunction(AJAThread *pThread, void *pContext)
AJAThreadFunction * mThreadFunc
#define AJA_REPORT(_index_, _severity_, _format_,...)
AJAThreadImpl(AJAThread *pThreadContext)
AJAStatus GetPriority(AJAThreadPriority *pThreadPriority)
Declares the AJAThreadImpl class.
AJAStatus SetPriority(AJAThreadPriority threadPriority)
AJAStatus Kill(uint32_t exitCode)
static void * ThreadProcStatic(void *pThreadImplContext)
AJAStatus SetThreadName(const char *name)
AJAStatus SetRealTime(AJAThreadRealTimePolicy policy, int priority)
virtual AJAStatus ThreadRun()
AJAStatus Stop(uint32_t timeout=0xffffffff)