Class Job
java.lang.Object
|
+----Job
-
public class Job
-
extends Object

-
BLOCKED
-
Job needs to do an I/O operation next
-
burst
-
size of current burst
-
burstStart
-
time when current burst started (job "arrived" at the cpu queue)
-
DONE
-
Job has completed
-
READY
-
Job is ready to run

-
doIO()
-
Called when this Job does an I/O operation
-
finish()
-
This job is finished.
-
nextBurst()
-
Return the amount of CPU time remaining for this job until it next does
I/O, or completes.
-
start()
-
Called when this Job is started running on the CPU
-
state()
-
What is the current state of this Job?
-
stop()
-
Called when this Job is removed from the CPU
-
toString()
-
for debugging: a string version of this job

burst
public int burst
-
size of current burst
burstStart
public int burstStart
-
time when current burst started (job "arrived" at the cpu queue)
DONE
public static final int DONE
-
Job has completed
BLOCKED
public static final int BLOCKED
-
Job needs to do an I/O operation next
READY
public static final int READY
-
Job is ready to run

toString
public String toString()
-
for debugging: a string version of this job
-
Overrides:
-
toString
in class Object
state
public int state()
-
What is the current state of this Job?
start
public void start()
-
Called when this Job is started running on the CPU
stop
public void stop()
-
Called when this Job is removed from the CPU
nextBurst
public int nextBurst()
-
Return the amount of CPU time remaining for this job until it next does
I/O, or completes.
doIO
public void doIO()
-
Called when this Job does an I/O operation
finish
public JobStats finish()
-
This job is finished. Return some summary statistics