|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--cz.zcu.fav.kiv.jsimcasestudies.watersystem.application.SourceMonitor
An encapsulation of a water source data and functionality. This source code needn`t to be changed when passing it to the production version.
Field Summary | |
private CommonControlInterface |
controlInterface
An interface between the controlled object and the control program |
private int |
sourceNumber
Number of the source |
Constructor Summary | |
protected |
SourceMonitor(CommonControlInterface controlInterface,
int sourceNumber)
Constructor of the class |
Method Summary | |
protected int |
getNumber()
Gets the number of the source |
protected SourceState |
getSourceState()
Synchronized method that returns consistent state of the source |
protected void |
pumpSwitchOff()
Synchronized method that shows if the pump is switched off |
protected void |
pumpSwitchOn()
Synchronized method that switches on the pump |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private CommonControlInterface controlInterface
private final int sourceNumber
Constructor Detail |
protected SourceMonitor(CommonControlInterface controlInterface, int sourceNumber)
controlInterface
- sourceNumber
- Method Detail |
protected int getNumber()
protected void pumpSwitchOn()
protected void pumpSwitchOff()
protected SourceState getSourceState()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |