Class RangeStatisticImpl
java.lang.Object
com.sun.enterprise.admin.monitor.stats.StatisticImpl
com.sun.enterprise.admin.monitor.stats.RangeStatisticImpl
- All Implemented Interfaces:
Serializable,RangeStatistic,Statistic
An implementation of a RangeStatistic. All instances of this class are
immutable. Provides all the necessary accessors for properties.
- Since:
- S1AS8.0
- Author:
- Muralidhar Vempaty, Kedar Mhaswade
- See Also:
-
Field Summary
Fields inherited from class com.sun.enterprise.admin.monitor.stats.StatisticImpl
DEFAULT_UNIT, DEFAULT_VALUE, localStrMgr, NEWLINE -
Constructor Summary
ConstructorsConstructorDescriptionRangeStatisticImpl(long curVal, long highMark, long lowMark, String name, String unit, String desc, long startTime, long sampleTime) Constructs an immutable instance of RangeStatistic. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the current value of this statistic.longReturns the highest value of this statistic, since measurement started.longReturns the lowest value of this statistic, since measurement started.toString()Methods inherited from class com.sun.enterprise.admin.monitor.stats.StatisticImpl
getDescription, getLastSampleTime, getName, getStartTime, getUnit, setDescriptionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.glassfish.j2ee.statistics.Statistic
getDescription, getLastSampleTime, getName, getStartTime, getUnit
-
Constructor Details
-
RangeStatisticImpl
public RangeStatisticImpl(long curVal, long highMark, long lowMark, String name, String unit, String desc, long startTime, long sampleTime) Constructs an immutable instance of RangeStatistic.- Parameters:
curVal- The current value of this statistichighMark- The highest value of this statistic, since measurement startedlowMark- The lowest value of this statistic, since measurement startedname- The name of the statisticunit- The unit of measurement for this statisticdesc- A brief description of the statisticstartTime- Time in milliseconds at which the measurement was startedsampleTime- Time at which the last measurement was done.
-
-
Method Details
-
getCurrent
public long getCurrent()Returns the current value of this statistic.- Specified by:
getCurrentin interfaceRangeStatistic- Returns:
- long indicating the current value
-
getHighWaterMark
public long getHighWaterMark()Returns the highest value of this statistic, since measurement started.- Specified by:
getHighWaterMarkin interfaceRangeStatistic- Returns:
- long indicating high water mark
-
getLowWaterMark
public long getLowWaterMark()Returns the lowest value of this statistic, since measurement started.- Specified by:
getLowWaterMarkin interfaceRangeStatistic- Returns:
- long indicating low water mark
-
toString
- Overrides:
toStringin classStatisticImpl
-