|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rioproject.watch.Watch
org.rioproject.watch.ThresholdWatch
public class ThresholdWatch
A Watch that provides threshold processing semantics
| Field Summary |
|---|
| Fields inherited from class org.rioproject.watch.Watch |
|---|
COMPONENT, DEFAULT_VIEW, id, localRef, logger, watchDataSource |
| Constructor Summary | |
|---|---|
ThresholdWatch(String id)
Create a new ThresholdWatch |
|
ThresholdWatch(String id,
Configuration config)
Creates new ThresholdWatch, creates and exports a WatchDataSourceImpl if the WatchDataSource is null using the Configuration object provided |
|
ThresholdWatch(WatchDataSource watchDataSource,
String id)
Create a new ThresholdWatch |
|
| Method Summary | |
|---|---|
void |
addThresholdListener(ThresholdListener listener)
Add a ThresholdListener |
void |
addWatchRecord(Calculable record)
Override parent's addRecord to check for threshold(s) being crossed |
long |
getBreachedCount()
Get the number of times the threshold has been breached |
long |
getClearedCount()
Get the number of times the threshold has been cleared |
double |
getCurrentHighThreshold()
Get the current high threshold value |
double |
getCurrentLowThreshold()
Get the current low threshold value |
double |
getHighThreshold()
Get the high threshold value |
double |
getLowThreshold()
Get the low threshold value |
ThresholdManager |
getThresholdManager()
Get the ThresholdManager for the ThresholdWatch |
ThresholdValues |
getThresholdValues()
Get the ThresholdValues from the ThresholdManager |
void |
removeThresholdListener(ThresholdListener listener)
Remove a ThresholdListener |
void |
setCurrentHighThreshold(double threshold)
Get the current high threshold value |
void |
setCurrentLowThreshold(double threshold)
Set the low threshold value |
void |
setThresholdValues(ThresholdValues tValues)
Set the ThresholdValues for the ThresholdManager |
| Methods inherited from class org.rioproject.watch.Watch |
|---|
clear, equals, getCalculables, getId, getLastCalculableValue, getView, getWatchDataSource, hashCode, main, setView, setWatchDataSource, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.rioproject.watch.WatchMBean |
|---|
clear, getCalculables, getId, getLastCalculableValue |
| Constructor Detail |
|---|
public ThresholdWatch(String id)
id - The identifier for this watch
public ThresholdWatch(String id,
Configuration config)
id - The identifier for this watchconfig - Configuration object used for constructing a
WatchDataSource
public ThresholdWatch(WatchDataSource watchDataSource,
String id)
watchDataSource - The watch data source associated with this watchid - The identifier for this watch| Method Detail |
|---|
public ThresholdManager getThresholdManager()
public void addThresholdListener(ThresholdListener listener)
listener - Thre ThresholdListenerpublic void removeThresholdListener(ThresholdListener listener)
listener - The ThresholdListenerpublic void setThresholdValues(ThresholdValues tValues)
tValues - The ThresholdValuespublic ThresholdValues getThresholdValues()
public void addWatchRecord(Calculable record)
addWatchRecord in class Watchrecord - the Calculable record to be addedpublic double getHighThreshold()
ThresholdWatchMBean
getHighThreshold in interface ThresholdWatchMBeanThresholdWatchMBean.getHighThreshold()public double getLowThreshold()
ThresholdWatchMBean
getLowThreshold in interface ThresholdWatchMBeanThresholdWatchMBean.getLowThreshold()public double getCurrentHighThreshold()
ThresholdWatchMBean
getCurrentHighThreshold in interface ThresholdWatchMBeanThresholdWatchMBean.getCurrentHighThreshold()public void setCurrentHighThreshold(double threshold)
ThresholdWatchMBean
setCurrentHighThreshold in interface ThresholdWatchMBeanthreshold - The current high threshold valueThresholdWatchMBean.setCurrentHighThreshold(double)public void setCurrentLowThreshold(double threshold)
ThresholdWatchMBean
setCurrentLowThreshold in interface ThresholdWatchMBeanthreshold - The threshold valueThresholdWatchMBean.setCurrentLowThreshold(double)public double getCurrentLowThreshold()
ThresholdWatchMBean
getCurrentLowThreshold in interface ThresholdWatchMBeanThresholdWatchMBean.getCurrentLowThreshold()public long getBreachedCount()
ThresholdWatchMBean
getBreachedCount in interface ThresholdWatchMBeanThresholdWatchMBean.getBreachedCount()public long getClearedCount()
ThresholdWatchMBean
getClearedCount in interface ThresholdWatchMBeanThresholdWatchMBean.getClearedCount()
|
Copyright © Rio Project. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||