NewCoroutine Class Reference

Internal coroutine class for coroutines that can be created without a corresponding thread. More...

#include <coroutine_decls.h>

Inheritance diagram for NewCoroutine:

Coroutine RefCounter Microthread BaseScheduler EpollScheduler SelectScheduler List of all members.

Public Member Functions

 NewCoroutine (int stacksize=4096 *1024)
 NewCoroutine constructor.
void returnto (Coroutine &o, bool acquired=false)
 Lets this coroutine return to the given coroutine.
virtual void start ()=0
 This is the coroutines main function.

Detailed Description

Internal coroutine class for coroutines that can be created without a corresponding thread.


Constructor & Destructor Documentation

NewCoroutine::NewCoroutine ( int  stacksize = 4096 *1024  ) 

NewCoroutine constructor.

Parameters:
stacksize is the size of the stack to be allocated for this coroutine


Member Function Documentation

void NewCoroutine::returnto ( Coroutine o,
bool  acquired = false 
)

Lets this coroutine return to the given coroutine.

Parameters:
o is the coroutine to be continued
acquired must be true if this object was previously acquired using acquire()
Returns:
never

virtual void NewCoroutine::start (  )  [pure virtual]

This is the coroutines main function.

It has to be overridden by subclasses.

Implemented in Microthread.


The documentation for this class was generated from the following files:
Generated on Sat Feb 7 01:26:51 2009 by  doxygen 1.5.1