Sourceforge.net - The VCF's Project Host
   The VCF Website Home   |   Online Discussion Forums   |   Sourceforge.net Project Page   

VCF::OSXThread Class Reference

#include <OSXThread.h>

Inheritance diagram for VCF::OSXThread:

VCF::ThreadPeer List of all members.

Public Types

enum  { k_eExecutionContextSystemTask, k_eExecutionContextDeferredTask, k_eExecutionContextMPTask, k_eExecutionContextOther }

Public Member Functions

 OSXThread (Thread *thread, bool mainThread)
virtual ~OSXThread ()
virtual bool start ()
 Starts (or resumes) a thread running.
virtual void stop ()
 gracefully stops the thread and shuts it down, releasing any OS resources associated with the thread
virtual uint32 getThreadID ()
 returns the thread associated with this thread of execution
virtual OSHandleID getHandleID ()
 returns a handle ID for the thread.
virtual uint32 getOwningProcessID ()
 Returns process that created thread.
virtual bool isActive ()
virtual void sleep (uint32 milliseconds)
 causes the thread the thread to sleep for the specified number of milliseconds
virtual int wait ()
virtual int wait (uint32 milliseconds)
void setCurrentLocale (Locale *locale)
LocalegetCurrentLocale ()

Static Protected Member Functions

static int executionContext ()
static OSStatus taskProc (void *parameter)

Protected Attributes

MPQueueID queueID_
MPTaskID taskID_
ProcessSerialNumber processID_
Threadthread_
bool isActive_
Locale locale_

Member Enumeration Documentation

anonymous enum
 

Enumerator:
k_eExecutionContextSystemTask 
k_eExecutionContextDeferredTask 
k_eExecutionContextMPTask 
k_eExecutionContextOther 


Constructor & Destructor Documentation

VCF::OSXThread::OSXThread Thread thread,
bool  mainThread
 

virtual VCF::OSXThread::~OSXThread  )  [virtual]
 


Member Function Documentation

static int VCF::OSXThread::executionContext  )  [static, protected]
 

Locale* VCF::OSXThread::getCurrentLocale  ) 
 

virtual OSHandleID VCF::OSXThread::getHandleID  )  [inline, virtual]
 

returns a handle ID for the thread.

It's use and signifigance are platform specific. On Win32 systems this is the HANDLE returned by the CreateThread/_beginthreadex() calls

Implements VCF::ThreadPeer.

virtual uint32 VCF::OSXThread::getOwningProcessID  )  [inline, virtual]
 

Returns process that created thread.

Is this useful? For OSX this is a pointer to a ProcessSerialNumber struct. See the ProcessManager API for more info

Implements VCF::ThreadPeer.

virtual uint32 VCF::OSXThread::getThreadID  )  [inline, virtual]
 

returns the thread associated with this thread of execution

Implements VCF::ThreadPeer.

virtual bool VCF::OSXThread::isActive  )  [inline, virtual]
 

Implements VCF::ThreadPeer.

void VCF::OSXThread::setCurrentLocale Locale locale  ) 
 

virtual void VCF::OSXThread::sleep uint32  milliseconds  )  [virtual]
 

causes the thread the thread to sleep for the specified number of milliseconds

Parameters:
uint32 - the number of milliseconds to sleep

Implements VCF::ThreadPeer.

virtual bool VCF::OSXThread::start  )  [virtual]
 

Starts (or resumes) a thread running.

Implements VCF::ThreadPeer.

virtual void VCF::OSXThread::stop  )  [virtual]
 

gracefully stops the thread and shuts it down, releasing any OS resources associated with the thread

Implements VCF::ThreadPeer.

static OSStatus VCF::OSXThread::taskProc void *  parameter  )  [static, protected]
 

virtual int VCF::OSXThread::wait uint32  milliseconds  )  [virtual]
 

Implements VCF::ThreadPeer.

virtual int VCF::OSXThread::wait  )  [virtual]
 

Implements VCF::ThreadPeer.


Member Data Documentation

bool VCF::OSXThread::isActive_ [protected]
 

Locale VCF::OSXThread::locale_ [protected]
 

ProcessSerialNumber VCF::OSXThread::processID_ [protected]
 

MPQueueID VCF::OSXThread::queueID_ [protected]
 

MPTaskID VCF::OSXThread::taskID_ [protected]
 

Thread* VCF::OSXThread::thread_ [protected]
 


The documentation for this class was generated from the following file:
   Comments or Suggestions?    License Information