Rio Project 4.2 API Documentation



org.rioproject.watch
Interface StopWatchMBean

All Superinterfaces:
ThresholdWatchMBean, WatchMBean
All Known Implementing Classes:
StopWatch

public interface StopWatchMBean
extends ThresholdWatchMBean

Provides a standard MBean to use when administering a StopWatch using JMX


Method Summary
 long getStartTime()
          Getter for property startTime
 void setElapsedTime(long elapsed)
          Sets the elapsed time of the measured interval
 void setElapsedTime(long elapsed, long now)
          Sets the elapsed time of the measured interval
 void setStartTime(long startTime)
          Setter for property startTime
 void startTiming()
          Start the timing for the watch
 void stopTiming()
          Stop the timing for the watch
 
Methods inherited from interface org.rioproject.watch.ThresholdWatchMBean
getBreachedCount, getClearedCount, getCurrentHighThreshold, getCurrentLowThreshold, getHighThreshold, getLowThreshold, setCurrentHighThreshold, setCurrentLowThreshold
 
Methods inherited from interface org.rioproject.watch.WatchMBean
clear, getCalculables, getId, getLastCalculableValue
 

Method Detail

startTiming

void startTiming()
Start the timing for the watch


stopTiming

void stopTiming()
Stop the timing for the watch


setElapsedTime

void setElapsedTime(long elapsed)
Sets the elapsed time of the measured interval

Parameters:
elapsed - milliseconds of elapsed time

setElapsedTime

void setElapsedTime(long elapsed,
                    long now)
Sets the elapsed time of the measured interval

Parameters:
elapsed - milliseconds of elapsed time
now - the current time in milliseconcds since the epoch.

getStartTime

long getStartTime()
Getter for property startTime

Returns:
Value of property startTime.

setStartTime

void setStartTime(long startTime)
Setter for property startTime

Parameters:
startTime - New value of property startTime.

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.