Class Controller

java.lang.Object
  extended by Controller
All Implemented Interfaces:
java.lang.Runnable

public class Controller
extends java.lang.Object
implements java.lang.Runnable

This class serves as the Global Name Server(GNS). It also sends out message requesting the PEs to compute their local min time, based on which it will compute the GVT.

Version:
1.9 (09/2006)
Author:
Yin Xiong

Field Summary
(package private)  boolean endOfSim
           
(package private)  Flag eosFlag
           
(package private)  Flag gvtFlag
           
(package private)  int newGVT
           
(package private)  PE[] PEs
           
(package private)  int sleepTime
          all the PEs in this simulation
(package private)  boolean timeForGvt
           
 
Constructor Summary
Controller(PE[] pes, Flag ef, Flag gf)
          Constructer.
 
Method Summary
(package private)  int computeGVT()
          Compute GVT/
 void run()
          Implements TimerTask's abstract run method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sleepTime

int sleepTime
all the PEs in this simulation


eosFlag

Flag eosFlag

endOfSim

boolean endOfSim

gvtFlag

Flag gvtFlag

timeForGvt

boolean timeForGvt

PEs

PE[] PEs

newGVT

int newGVT
Constructor Detail

Controller

public Controller(PE[] pes,
                  Flag ef,
                  Flag gf)
Constructer.

Method Detail

run

public void run()
Implements TimerTask's abstract run method.

Specified by:
run in interface java.lang.Runnable

computeGVT

int computeGVT()
Compute GVT/