001: /*
002: * JBoss, Home of Professional Open Source.
003: * Copyright 2006, Red Hat Middleware LLC, and individual contributors
004: * as indicated by the @author tags. See the copyright.txt file in the
005: * distribution for a full listing of individual contributors.
006: *
007: * This is free software; you can redistribute it and/or modify it
008: * under the terms of the GNU Lesser General Public License as
009: * published by the Free Software Foundation; either version 2.1 of
010: * the License, or (at your option) any later version.
011: *
012: * This software is distributed in the hope that it will be useful,
013: * but WITHOUT ANY WARRANTY; without even the implied warranty of
014: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
015: * Lesser General Public License for more details.
016: *
017: * You should have received a copy of the GNU Lesser General Public
018: * License along with this software; if not, write to the Free
019: * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
020: * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
021: */
022: package javax.management.monitor;
023:
024: import javax.management.ObjectName;
025:
026: /**
027: * The string monitor service MBean interface. <p>
028: *
029: * @author <a href="mailto:Adrian.Brock@HappeningTimes.com">Adrian Brock</a>
030: * @version $Revision: 57200 $
031: *
032: */
033: public interface StringMonitorMBean extends MonitorMBean {
034: // Constants -----------------------------------------------------
035:
036: // Static --------------------------------------------------------
037:
038: // Public --------------------------------------------------------
039:
040: /**
041: * Retrieves the derived gauge.
042: *
043: * @return the derived gauge.
044: * @deprecated use {@link #getDerivedGauge(ObjectName)}
045: */
046: public String getDerivedGauge();
047:
048: /**
049: * Retrieves the derived gauge timestamp.
050: *
051: * @return the derived gauge timestamp.
052: * @deprecated use {@link #getDerivedGaugeTimeStamp(ObjectName)}
053: */
054: public long getDerivedGaugeTimeStamp();
055:
056: /**
057: * Retrieves the derived gauge.
058: *
059: * @param name the object name of the mbean.
060: * @return the derived gauge.
061: */
062: public String getDerivedGauge(ObjectName name);
063:
064: /**
065: * Retrieves the derived gauge timestamp.
066: *
067: * @param name the object name of the mbean.
068: * @return the derived gauge timestamp.
069: */
070: public long getDerivedGaugeTimeStamp(ObjectName name);
071:
072: /**
073: * Retrieves the string to compare with the observed attribute.
074: *
075: * @return the comparison string.
076: */
077: public String getStringToCompare();
078:
079: /**
080: * Sets the string to compare with the observed attribute.
081: *
082: * @param value the comparison string.
083: * @exception IllegalArgumentException when specified string is null.
084: */
085: public void setStringToCompare(String value)
086: throws IllegalArgumentException;
087:
088: /**
089: * Retrieves the matching on/off switch.
090: *
091: * @return true if the notification occurs when the string matches, false
092: * otherwise.
093: */
094: public boolean getNotifyMatch();
095:
096: /**
097: * Sets the matching on/off switch.
098: *
099: * @param value pass true for a notification when the string matches, false
100: * otherwise.
101: */
102: public void setNotifyMatch(boolean value);
103:
104: /**
105: * Retrieves the differs on/off switch.
106: *
107: * @return true if the notification occurs when the string differs, false
108: * otherwise.
109: */
110: public boolean getNotifyDiffer();
111:
112: /**
113: * Sets the differs on/off switch.
114: *
115: * @param value pass true for a notification when the string differs, false
116: * otherwise.
117: */
118: public void setNotifyDiffer(boolean value);
119: }
|