com.sun.jaw.impl.agent.services.monitor
Class GaugeMonitor

java.lang.Object
  |
  +--com.sun.jaw.impl.agent.services.monitor.Monitor
        |
        +--com.sun.jaw.impl.agent.services.monitor.GaugeMonitor

public class GaugeMonitor
extends Monitor
implements AlarmClockListener, java.io.Serializable

This class provides a simple implementation of a gauge monitor.

A gauge monitor is a monitor which observes an attribute which behaves as a gauge. A hysteresis mechanism is provided to avoid the repeated triggering of event notifications when the gauge makes small oscillations around the threshold value. This capability is provided by specifying threshold values in pairs; one being a high threshold value and the other being a low threshold value. The difference between threshold values is the hysteresis interval.

The gauge monitor has the following structure:

The gauge monitor has the following constraints: The gauge monitor has the following behaviour: If the gauge difference option is used, then 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 initially calculated using the following equation:

This implementation of the gauge monitor requires the observed property to be either of type Integer or Float.

See Also:
Monitor, CounterMonitor, Serialized Form

Fields inherited from class com.sun.jaw.impl.agent.services.monitor.Monitor
administrativeStateOnOff, alarmClock, already_notified, ALREADY_NOTIFIED_FLAGS_CLEARED, cmf, derivedGauge, derivedGaugeTimestamp, event_type, GRANULARITY_PERIOD_ALREADY_NOTIFIED, granularityPeriod, listeners, OBSERVED_OBJECT_ALREADY_NOTIFIED, OBSERVED_PROPERTY_ALREADY_NOTIFIED, OBSERVED_PROPERTY_TYPE_ALREADY_NOTIFIED, observedObject, observedProperty
 
Constructor Summary
GaugeMonitor()
           
 
Method Summary
 java.lang.Boolean getGaugeDifferenceOnOff()
          Returns the gauge difference on/off flag.
 java.lang.Boolean getNotifyHighOnOff()
          Returns the notify high on/off switch value.
 java.lang.Boolean getNotifyLowOnOff()
          Returns the notify low on/off switch value.
 java.lang.Number getPreviousScanGauge()
          Returns the previous scan gauge.
 java.lang.Boolean getPreviousScanGaugeInitialisedOnOff()
          Returns the previous scan gauge procedural status.
 java.lang.Number getThresholdHighValue()
          Returns the threshold high value.
 java.lang.Number getThresholdLowValue()
          Returns the threshold low value.
 void handleAlarmClock(AlarmClockEvent e)
          This handle will be called each time the alarm-clock has exceeded its timeout.
 void performStart()
          Activates the GaugeMonitor service.
 void performStop()
          Deactivates the GaugeMonitor service.
 void setGaugeDifferenceOnOff(java.lang.Boolean value)
          Sets the gauge difference on/off flag.
 void setNotifyHighOnOff(java.lang.Boolean value)
          Sets the notify high on/off switch value.
 void setNotifyLowOnOff(java.lang.Boolean value)
          Sets the notify low on/off switch value.
 void setThresholdHighValue(java.lang.Number value)
          Sets the threshold high value.
 void setThresholdLowValue(java.lang.Number value)
          Sets the threshold low value.
 
Methods inherited from class com.sun.jaw.impl.agent.services.monitor.Monitor
addMonitorListener, deleteCmf, getClassVersion, getDerivedGauge, getDerivedGaugeTimestamp, getGranularityPeriod, getGranularityPeriodAsLong, getObservedObject, getObservedProperty, initCmf, isActive, notifyMonitor, removeMonitorListener, setGranularityPeriod, setGranularityPeriodAsLong, setObservedObject, setObservedProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GaugeMonitor

public GaugeMonitor()
Method Detail

handleAlarmClock

public void handleAlarmClock(AlarmClockEvent e)
This handle will be called each time the alarm-clock has exceeded its timeout.
Specified by:
handleAlarmClock in interface AlarmClockListener
Overrides:
handleAlarmClock in class Monitor

getThresholdHighValue

public java.lang.Number getThresholdHighValue()
Returns the threshold high value.

setThresholdHighValue

public void setThresholdHighValue(java.lang.Number value)
Sets the threshold high value.

getThresholdLowValue

public java.lang.Number getThresholdLowValue()
Returns the threshold low value.

setThresholdLowValue

public void setThresholdLowValue(java.lang.Number value)
Sets the threshold low value.

getNotifyHighOnOff

public java.lang.Boolean getNotifyHighOnOff()
Returns the notify high on/off switch value.

setNotifyHighOnOff

public void setNotifyHighOnOff(java.lang.Boolean value)
Sets the notify high on/off switch value.

getNotifyLowOnOff

public java.lang.Boolean getNotifyLowOnOff()
Returns the notify low on/off switch value.

setNotifyLowOnOff

public void setNotifyLowOnOff(java.lang.Boolean value)
Sets the notify low on/off switch value.

getGaugeDifferenceOnOff

public java.lang.Boolean getGaugeDifferenceOnOff()
Returns the gauge difference on/off flag.

setGaugeDifferenceOnOff

public void setGaugeDifferenceOnOff(java.lang.Boolean value)
Sets the gauge difference on/off flag.

getPreviousScanGauge

public java.lang.Number getPreviousScanGauge()
Returns the previous scan gauge.

getPreviousScanGaugeInitialisedOnOff

public java.lang.Boolean getPreviousScanGaugeInitialisedOnOff()
Returns the previous scan gauge procedural status.

performStart

public void performStart()
Activates the GaugeMonitor service.
Overrides:
performStart in class Monitor

performStop

public void performStop()
Deactivates the GaugeMonitor service.
Overrides:
performStop in class Monitor