|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rioproject.watch.ThresholdManager
public abstract class ThresholdManager
The ThresholdManager is the keeper of ThresholdValues and determines when Calculable items being recorded have crossed any thresholds. A ThresholdManager provides threshold management processing, providing specific behavior that may be used to remedy the situation where a threshold has been crossed
| Field Summary | |
|---|---|
protected List<ThresholdListener> |
thresholdListeners
|
protected ThresholdValues |
thresholdValues
Holds value of property thresholdValues |
| Constructor Summary | |
|---|---|
ThresholdManager()
|
|
| Method Summary | |
|---|---|
void |
addThresholdListener(ThresholdListener listener)
Add a Threshold listener |
abstract void |
checkThreshold(Calculable calculable)
Check the threshold and determine if any action needs to occur |
void |
clear()
Remove all registered ThresholdListener instances |
abstract boolean |
getThresholdCrossed()
Get the type of threshold that has been crossed |
ThresholdListener[] |
getThresholdListeners()
Get all registered ThresholdListener instances |
ThresholdValues |
getThresholdValues()
Getter for property thresholdValues. |
protected void |
notifyListeners(Calculable calculable,
int type)
Notify all ThresholdListeners of a threshold being crossed |
void |
removeThresholdListener(ThresholdListener listener)
Remove a ThresholdListener |
void |
setThresholdValues(ThresholdValues thresholdValues)
Setter for property thresholdValues. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final transient List<ThresholdListener> thresholdListeners
protected ThresholdValues thresholdValues
| Constructor Detail |
|---|
public ThresholdManager()
| Method Detail |
|---|
public abstract void checkThreshold(Calculable calculable)
calculable - The Calculable to checkpublic abstract boolean getThresholdCrossed()
public ThresholdValues getThresholdValues()
public void setThresholdValues(ThresholdValues thresholdValues)
thresholdValues - New value of property thresholdValues.
protected void notifyListeners(Calculable calculable,
int type)
calculable - The Calculable recordtype - The type of threshold, breached or clearedpublic void addThresholdListener(ThresholdListener listener)
listener - the ThresholdListener to addpublic void removeThresholdListener(ThresholdListener listener)
listener - the ThresholdListener to removepublic ThresholdListener[] getThresholdListeners()
public void clear()
|
Copyright © Rio Project. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||