|
Nebula
|
#include <fibers.h>
Inherits Thread.
Public Member Functions | |
| FiberThread () | |
| constructor | |
| virtual | ~FiberThread () |
| destructor | |
| void | EmitWakeupSignal () |
| called if thread needs a wakeup call before stopping | |
| void | DoWork () |
| this method runs in the thread context | |
| bool | HasWork () |
| returns true if thread has work | |
| void | SleepFiber (volatile int *counter, int value) |
| sleeps the current fiber and switches it for a new one | |
| void | NewFiber () |
| switches the current fiber | |
| void | SwitchFiber () |
| switch back to original fiber | |
Private Member Functions | |
| __DeclareClass (FiberThread) | |
Private Attributes | |
| Fibers::FiberContext | currentFiber |
| Fibers::Fiber | threadFiber |
| Fibers::FiberThread::FiberThread | ( | ) |
constructor
|
virtual |
destructor
|
private |
| void Fibers::FiberThread::DoWork | ( | ) |
this method runs in the thread context
| void Fibers::FiberThread::EmitWakeupSignal | ( | ) |
called if thread needs a wakeup call before stopping
| bool Fibers::FiberThread::HasWork | ( | ) |
returns true if thread has work
| void Fibers::FiberThread::NewFiber | ( | ) |
switches the current fiber
| void Fibers::FiberThread::SleepFiber | ( | volatile int * | counter, |
| int | value ) |
sleeps the current fiber and switches it for a new one
| void Fibers::FiberThread::SwitchFiber | ( | ) |
switch back to original fiber
|
private |
|
private |