Logo Search packages:      
Sourcecode: pwlib version File versions  Download package

void PThread::Resume (  )  [virtual, inherited]

Resume thread execution, this is identical to Suspend(FALSE)#.

The Resume() method may be called from within the constructor of a PThread descendant. However, the Resume() should be in the constructor of the most descendant class. So, if you have a class B (which is descended of PThread), and a class C (which is descended of B), placing the call to Resume in the constructor of B is unwise.

If you do place a call to Resume in the constructor, it should be at the end of the constructor, after all the other initialisation in the constructor.

The reason the call to Resume() should be at the end of the construction process is simple - you want the thread to start when all the variables in the class have been correctly initialised.

Definition at line 1385 of file win32.cxx.

References PThread::IsTerminated().

Referenced by LauncherThread::Main(), and PThread::Suspend().

{
  PAssert(!IsTerminated(), "Operation on terminated thread");
  ResumeThread(threadHandle);
}


Generated by  Doxygen 1.6.0   Back to index