|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--javax.management.NotificationBroadcasterSupport
|
+--javax.management.monitor.Monitor
|
+--javax.management.monitor.GaugeMonitor
Defines a monitor MBean designed to observe the values of a gauge attribute.
A gauge monitor observes an attribute that is continuously variable with time. A gauge monitor sends notifications as follows:
threshold high notification is sent.
The notify high flag must be set to true
threshold low notification is sent.
The notify low flag must be set to true.
If the gauge difference mode is used, the value of the derived gauge is calculated
as the difference between the observed gauge values for two successive observations.
The derived gauge value (V[t]) is calculated using the following method:
Byte, Integer, Short, Long, Float, Double).
| Constructor Summary | |
GaugeMonitor()
|
|
| Method Summary | |
protected void |
doMonitor(java.lang.Object value)
|
java.lang.Number |
getDerivedGauge()
Gets the derived gauge. |
long |
getDerivedGaugeTimeStamp()
Gets the derived gauge timestamp. |
boolean |
getDifferenceMode()
Gets the difference mode flag value. |
java.lang.Number |
getHighThreshold()
Gets the high threshold value. |
java.lang.Number |
getLowThreshold()
Gets the low threshold value. |
MBeanNotificationInfo[] |
getNotificationInfo()
Returns a NotificationInfo object contaning the name of the Java class of the notification and the notification types sent. |
boolean |
getNotifyHigh()
Gets the high notification's on/off switch value. |
boolean |
getNotifyLow()
Gets the low notification's on/off switch value. |
void |
setDifferenceMode(boolean value)
Sets the difference mode flag value. |
void |
setNotifyHigh(boolean value)
Sets the high notification's on/off switch value. |
void |
setNotifyLow(boolean value)
Sets the low notification's on/off switch value. |
void |
setThresholds(java.lang.Number highValue,
java.lang.Number lowValue)
Sets the high and the low threshold values. |
void |
start()
|
void |
stop()
|
| Methods inherited from class javax.management.monitor.Monitor |
_start, _stop, getGranularityPeriod, getObservedAttribute, getObservedObject, isActive, postDeregister, postRegister, preDeregister, preRegister, sendNotification, setGranularityPeriod, setObservedAttribute, setObservedObject |
| Methods inherited from class javax.management.NotificationBroadcasterSupport |
addNotificationListener, removeNotificationListener, sendNotification |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.management.monitor.MonitorMBean |
getGranularityPeriod, getObservedAttribute, getObservedObject, isActive, setGranularityPeriod, setObservedAttribute, setObservedObject |
| Constructor Detail |
public GaugeMonitor()
| Method Detail |
public void start()
start in class Monitorpublic void stop()
stop in class Monitorpublic java.lang.Number getDerivedGauge()
GaugeMonitorMBean
getDerivedGauge in interface GaugeMonitorMBeanpublic long getDerivedGaugeTimeStamp()
GaugeMonitorMBean
getDerivedGaugeTimeStamp in interface GaugeMonitorMBeanpublic java.lang.Number getHighThreshold()
GaugeMonitorMBean
getHighThreshold in interface GaugeMonitorMBeanpublic java.lang.Number getLowThreshold()
GaugeMonitorMBean
getLowThreshold in interface GaugeMonitorMBean
public void setThresholds(java.lang.Number highValue,
java.lang.Number lowValue)
throws java.lang.IllegalArgumentException
GaugeMonitorMBean
setThresholds in interface GaugeMonitorMBeanhighValue - The high threshold value.lowValue - The low threshold value.
java.lang.IllegalArgumentException - The specified high/low threshold is null
or the low threshold is greater than the high threshold
or the high threshold and the low threshold are not of the same type.public boolean getNotifyHigh()
GaugeMonitorMBean
getNotifyHigh in interface GaugeMonitorMBeantrue if the gauge monitor notifies when exceeding the high threshold, false otherwise.public void setNotifyHigh(boolean value)
GaugeMonitorMBean
setNotifyHigh in interface GaugeMonitorMBeanvalue - The high notification's on/off switch value.public boolean getNotifyLow()
GaugeMonitorMBean
getNotifyLow in interface GaugeMonitorMBeantrue if the gauge monitor notifies when exceeding the low threshold, false otherwise.public void setNotifyLow(boolean value)
GaugeMonitorMBean
setNotifyLow in interface GaugeMonitorMBeanvalue - The low notification's on/off switch value.public boolean getDifferenceMode()
GaugeMonitorMBean
getDifferenceMode in interface GaugeMonitorMBeantrue if the difference mode is used, false otherwise.public void setDifferenceMode(boolean value)
GaugeMonitorMBean
setDifferenceMode in interface GaugeMonitorMBeanvalue - The difference mode flag value.public MBeanNotificationInfo[] getNotificationInfo()
NotificationBroadcasterSupport
getNotificationInfo in interface NotificationBroadcastergetNotificationInfo in class NotificationBroadcasterSupportprotected void doMonitor(java.lang.Object value)
doMonitor in class Monitor
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||