OOStuBS - Technische Informatik II (TI-II)
2.4
Hauptseite
Zusätzliche Informationen
Klassen
Dateien
Auflistung der Dateien
Datei-Elemente
src
thread
dispatch.cc
gehe zur Dokumentation dieser Datei
1
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\
2
* Technische Informatik II *
3
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
4
* *
5
* D I S P A T C H E R *
6
* *
7
\* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
8
9
/* * * * * * * * * * * * * * * * * * * * * * * * *\
10
# INCLUDES #
11
\* * * * * * * * * * * * * * * * * * * * * * * * */
12
13
#include "
thread/dispatch.h
"
14
15
/* * * * * * * * * * * * * * * * * * * * * * * * *\
16
# METHODS #
17
\* * * * * * * * * * * * * * * * * * * * * * * * */
18
19
void
Dispatcher::start
(
Thread
& first){
20
current
=&first;
21
first.
context
.
set
();
22
}
23
24
void
Dispatcher::dispatch
(
Thread
& next){
25
Thread
& temp=*
current
;
26
current
=&next;
27
temp.
context
.
swap
(next.
context
);
28
}
Erzeugt am Mon Jun 30 2014 07:13:28 für OOStuBS - Technische Informatik II (TI-II) von
1.8.1.2