|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object
|
+--java.lang.Thread
|
+--Philosopher
The philosopher class INPUT: none OUTPUT: none
| Field Summary | |
(package private) int |
me
|
(package private) PhilosopherApplet |
pa
|
| Fields inherited from class java.lang.Thread |
contextClassLoader,
daemon,
eetop,
group,
inheritedAccessControlContext,
MAX_PRIORITY,
MIN_PRIORITY,
name,
NORM_PRIORITY,
priority,
single_step,
stillborn,
stopThreadPermission,
target,
threadInitNumber,
threadQ,
values |
| Constructor Summary | |
Philosopher(PhilosopherApplet phillApp,
int _me)
Initialize the philosopher class INPUT: phillApp, link to main _me , ID number OUTPUT: none |
|
| Method Summary | |
(package private) void |
activity(int n,
java.awt.Color c)
The thread for each philosopher. |
(package private) void |
eat()
Defines what the color will be with the assorted acction INPUT: none OUTPUT: none |
(package private) void |
hungry()
Defines what the color will be with the assorted action INPUT: none OUTPUT: none |
int |
left()
Not used, not needed. |
int |
right()
Not used, not needed. |
void |
run()
Change the modes. |
(package private) void |
think()
Defines what the color will be with the assorted action INPUT: none OUTPUT: none |
| Methods inherited from class java.lang.Thread |
|
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Field Detail |
PhilosopherApplet pa
int me
| Constructor Detail |
public Philosopher(PhilosopherApplet phillApp,
int _me)
| Method Detail |
public void run()
public int left()
public int right()
void activity(int n,
java.awt.Color c)
void think()
void hungry()
void eat()
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||