|
|||||||||||
| 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.StringMonitor
Defines a monitor MBean designed to observe the values of a string attribute.
A string monitor sends notifications as follows:
match notification is sent.
The notify match flag must be set to true.
differ notification is sent.
The notify differ flag must be set to true.
| Field Summary |
| Fields inherited from class javax.management.monitor.Monitor |
observedObjects |
| Constructor Summary | |
StringMonitor()
|
|
| Method Summary | |
void |
addObservedObject(ObjectName objectName)
Adds the specified object in the set of observed MBeans. |
protected void |
doMonitor(ObjectName observedObject,
java.lang.Object value)
|
java.lang.String |
getDerivedGauge(ObjectName observedObject)
Gets the derived gauge for the specified MBean. |
long |
getDerivedGaugeTimeStamp(ObjectName observedObject)
Gets the derived gauge timestamp for the specified MBean. |
MBeanNotificationInfo[] |
getNotificationInfo()
Returns a NotificationInfo object contaning the name of the Java class of the notification and the notification types sent. |
boolean |
getNotifyDiffer()
Gets the differing notification's on/off switch value. |
boolean |
getNotifyMatch()
Gets the matching notification's on/off switch value. |
java.lang.String |
getStringToCompare()
Gets the string to compare with the observed attribute. |
void |
setNotifyDiffer(boolean value)
Sets the differing notification's on/off switch value. |
void |
setNotifyMatch(boolean value)
Sets the matching notification's on/off switch value. |
void |
setStringToCompare(java.lang.String value)
Sets the string to compare with the observed attribute. |
void |
start()
|
void |
stop()
|
| Methods inherited from class javax.management.monitor.Monitor |
_start, _stop, containsObservedObject, getGranularityPeriod, getMonitorData, getObservedAttribute, getObservedObjects, isActive, postDeregister, postRegister, preDeregister, preRegister, removeObservedObject, sendNotification, setGranularityPeriod, setObservedAttribute |
| Methods inherited from class javax.management.NotificationBroadcasterSupport |
addNotificationListener, handleNotification, removeNotificationListener, 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 |
containsObservedObject, getGranularityPeriod, getObservedAttribute, getObservedObjects, isActive, removeObservedObject, setGranularityPeriod, setObservedAttribute |
| Constructor Detail |
public StringMonitor()
| Method Detail |
public void start()
start in class Monitorpublic void stop()
stop in class Monitorpublic java.lang.String getDerivedGauge(ObjectName observedObject)
StringMonitorMBean
getDerivedGauge in interface StringMonitorMBeanobservedObject - the MBean for which the derived gauge is to be returned
null otherwise.public long getDerivedGaugeTimeStamp(ObjectName observedObject)
StringMonitorMBean
getDerivedGaugeTimeStamp in interface StringMonitorMBeanobservedObject - the MBean for which the derived gauge timestamp is to be returned
null otherwise.public java.lang.String getStringToCompare()
StringMonitorMBean
getStringToCompare in interface StringMonitorMBeanStringMonitorMBean.setStringToCompare(java.lang.String)
public void setStringToCompare(java.lang.String value)
throws java.lang.IllegalArgumentException
StringMonitorMBean
setStringToCompare in interface StringMonitorMBeanvalue - The string value.
java.lang.IllegalArgumentException - The specified
string to compare is null.StringMonitorMBean.getStringToCompare()public boolean getNotifyMatch()
StringMonitorMBean
getNotifyMatch in interface StringMonitorMBeantrue if the string monitor notifies when
matching, false otherwise.StringMonitorMBean.setNotifyMatch(boolean)public void setNotifyMatch(boolean value)
StringMonitorMBean
setNotifyMatch in interface StringMonitorMBeanvalue - The matching notification's on/off switch value.StringMonitorMBean.getNotifyMatch()public boolean getNotifyDiffer()
StringMonitorMBean
getNotifyDiffer in interface StringMonitorMBeantrue if the string monitor notifies when
differing, false otherwise.StringMonitorMBean.setNotifyDiffer(boolean)public void setNotifyDiffer(boolean value)
StringMonitorMBean
setNotifyDiffer in interface StringMonitorMBeanvalue - The differing notification's on/off switch value.StringMonitorMBean.getNotifyDiffer()public MBeanNotificationInfo[] getNotificationInfo()
NotificationBroadcasterSupport
getNotificationInfo in interface NotificationBroadcastergetNotificationInfo in class NotificationBroadcasterSupport
protected void doMonitor(ObjectName observedObject,
java.lang.Object value)
doMonitor in class Monitor
public void addObservedObject(ObjectName objectName)
throws java.lang.IllegalArgumentException
MonitorMBean
addObservedObject in interface MonitorMBeanaddObservedObject in class MonitorobjectName - The object to observe.
java.lang.IllegalArgumentException - the specified object is null.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||