|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Thread | +--cz.zcu.fav.kiv.jsim.JSimProcess | +--cz.zcu.fav.kiv.jsimcasestudies.watersystem.model.StationProcess
The dynamic model of water station (i.e. its state - main tank water level) changes. This process is responsible for periodic adjustments of model values concerning the main water tank. This involves switching on/off sensors of low/high level of water in the tank. It is assumed that just one process of this class will be created in the whole model.
Field Summary | |
private static double |
BASE_PERIOD_MULTIPLIER
Multiplier of the model's base period. |
private double |
basePeriod
The model's base period of updates. |
private StationHardwareData |
hw
Information produced by hardware sensors. |
private InterruptController |
ic
Interrupt controller object. |
private Station |
station
The station that this process manages. |
Fields inherited from class cz.zcu.fav.kiv.jsim.JSimProcess |
INT_REQUESTS_TO_IGNORE, myParent, semaphoreIAmCurrentlyBlockedOn, STATE_ACTIVE, STATE_BLOCKEDONMESSAGERECEIVE, STATE_BLOCKEDONMESSAGESEND, STATE_BLOCKEDONSEMAPHORE, STATE_NEW, STATE_PASSIVE, STATE_SCHEDULED, STATE_TERMINATED |
Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
protected |
StationProcess(cz.zcu.fav.kiv.jsim.JSimSimulation simulation,
StationHardwareData hw,
Station station,
InterruptController ic,
double basePeriod)
Constructs a new process simulating water changes in the main tank. |
Method Summary | |
protected void |
life()
Simulates water level changes in the station tank and sensor setting. |
Methods inherited from class cz.zcu.fav.kiv.jsim.JSimProcess |
activate, blockOnSemaphore, cancel, compareTo, copyToMessageClipboard, createDetailedInfoWindow, equals, error, getDetailedInformationArray, getMessageBox, getNumber, getObjectListItemDescription, getParent, getPrivateLock, getSenderIAmWaitingFor, getScheduleTime, getState, getStateAsString, getStateAsString, hasBeenStarted, hasEmptyMessageClipboard, hashCode, hold, isIdle, message, messageNoNL, passivate, reactivate, readFromClipboard, receiveMessageWithBlocking, receiveMessageWithBlocking, receiveMessageWithBlocking, receiveMessageWithBlocking, receiveMessageWithoutBlocking, receiveMessageWithoutBlocking, receiveMessageWithoutBlocking, receiveMessageWithoutBlocking, run, sendMessageWithBlocking, sendMessageWithBlocking, sendMessageWithBlocking, sendMessageWithoutBlocking, sendMessageWithoutBlocking, sendMessageWithoutBlocking, start, toString, unblockFromSemaphore, wait |
Methods inherited from class java.lang.Thread |
activeCount, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, checkAccess, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, stop, stop, suspend, yield |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
private static final double BASE_PERIOD_MULTIPLIER
private final double basePeriod
private StationHardwareData hw
private InterruptController ic
private final Station station
Constructor Detail |
protected StationProcess(cz.zcu.fav.kiv.jsim.JSimSimulation simulation, StationHardwareData hw, Station station, InterruptController ic, double basePeriod) throws cz.zcu.fav.kiv.jsim.JSimSimulationAlreadyTerminatedException, cz.zcu.fav.kiv.jsim.JSimInvalidParametersException, cz.zcu.fav.kiv.jsim.JSimTooManyProcessesException
simulation
- The overall simulation.hw
- Hardware data periodically changed by the tank's sensors.station
- The station that this process will manage.ic
- Interrupt object (flag) sets with any sensor changebasePeriod
- The model's base period.Method Detail |
protected void life()
life
in class cz.zcu.fav.kiv.jsim.JSimProcess
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |