dispatch.h.svn-base

来自「德国Erlangen大学教学操作系统源码。」· SVN-BASE 代码 · 共 36 行

SVN-BASE
36
字号
/*****************************************************************************//* Betriebssysteme                                                           *//*---------------------------------------------------------------------------*//*                                                                           *//*                          D I S P A T C H E R                              *//*                                                                           *//*---------------------------------------------------------------------------*//* Implementierung des Dispatcher.                                           *//* Der Dispatcher verwaltet den life-Pointer, der die jeweils aktive         *//* Koroutine angibt. mit go() wird der life Pointer initialisiert und die    *//* erste Koroutine gestartet, alle weiteren Kontextwechsel werden mit        *//* dispatch() ausgeloest. active() liefert den life Pointer zurueck.         *//*****************************************************************************/#ifndef __dispatch_include__#define __dispatch_include__#include "thread/coroutine.h"        class Dispatcher{public:	Dispatcher();	Dispatcher(Dispatcher &obj);	virtual ~Dispatcher();		void go (Coroutine& first);	void dispatch (Coroutine& next);	Coroutine* active ();private:	Coroutine *life;};#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?