All Packages Class Hierarchy This Package Previous Next Index
java.lang.Object | +----simula.simset.Linkage | +----simula.simset.Link | +----simula.simset.simulation.Process
Process
objects implement the interacting sequential processes that model the
behaviour of a system.
A user-defines class can be turned into a process by extending this class.
At any point in time, a process can be in one, and only one, of the
following states:
Active
-- The process is at the head of the event list
and its actions are being executed. Only one process can be active at any one
time.
Suspended
-- The process is on the event list, scheduled
to become active at a specified time in the future. The event list is ordered
according to these 'event times'. The event time of a suspended process may
be equal to that of the active process, in which case its actions will be
executed before the clock is advanced.
Passive
-- The process is not on the event list. Unless
another process brings it back on to the list by means of an activation
statement, its further actions will not be executed.
Terminated
-- The process is not on the event list and
has * no further actions to execute.
Thread
associated with this process.
True
if the process is passive or terminated,
False
if it is scheduled.
Thread
associated with this process.
True
if the process is terminated, False
if it is scheduled or passive.
protected static final int ACTIVE
protected static final int SUSPENDED
protected static final int PASSIVE
protected static final int TERMINATED
protected int status
protected double evTime
protected EventThread processThread
Thread
associated with this process.
protected Simulation sim
public Process(Simulation _simulation)
public double evtime() throws SimulaException
protected void evtime(double _time)
public boolean idle()
True
if the process is passive or terminated,
False
if it is scheduled.
True
if the process is passive or terminated,
False
if it is scheduled.
public Process nextev()
Null
.
protected EventThread processThread()
Thread
associated with this process.
public abstract void run()
protected void setStatus(int newStatus)
public boolean terminated()
True
if the process is terminated, False
if it is scheduled or passive.
True
if the process is terminated, False
if it is scheduled or passive.
All Packages Class Hierarchy This Package Previous Next Index