This commit is contained in:
Gary Gregory 2019-12-30 13:41:54 -05:00
parent 0ef55fe145
commit c8289bfcc9
1 changed files with 26 additions and 33 deletions

View File

@ -131,30 +131,26 @@ public class StopWatch {
/** /**
* <p> * <p>
* The method is used to find out if the StopWatch is started. A suspended * Returns whether the StopWatch is started. A suspended StopWatch is also started watch.
* StopWatch is also started watch.
* </p> * </p>
*
* @return boolean * @return boolean If the StopWatch is started.
* If the StopWatch is started.
*/ */
abstract boolean isStarted(); abstract boolean isStarted();
/** /**
* <p> * <p>
* This method is used to find out whether the StopWatch is stopped. The * Returns whether the StopWatch is stopped. The stopwatch which's not yet started and explicitly stopped stopwatch is
* stopwatch which's not yet started and explicitly stopped stopwatch is
* considered as stopped. * considered as stopped.
* </p> * </p>
* *
* @return boolean * @return boolean If the StopWatch is stopped.
* If the StopWatch is stopped.
*/ */
abstract boolean isStopped(); abstract boolean isStopped();
/** /**
* <p> * <p>
* This method is used to find out whether the StopWatch is suspended. * Returns whether the StopWatch is suspended.
* </p> * </p>
* *
* @return boolean * @return boolean
@ -166,7 +162,7 @@ public class StopWatch {
private static final long NANO_2_MILLIS = 1000000L; private static final long NANO_2_MILLIS = 1000000L;
/** /**
* Provides a started stopwatch for convenience. * Creates a started stopwatch for convenience.
* *
* @return StopWatch a stopwatch that's already been started. * @return StopWatch a stopwatch that's already been started.
* *
@ -177,6 +173,7 @@ public class StopWatch {
sw.start(); sw.start();
return sw; return sw;
} }
/** /**
* The current running state of the StopWatch. * The current running state of the StopWatch.
*/ */
@ -215,7 +212,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Get the time on the stopwatch in nanoseconds. * Gets the time on the stopwatch in nanoseconds.
* </p> * </p>
* *
* <p> * <p>
@ -240,7 +237,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Get the split time on the stopwatch in nanoseconds. * Gets the split time on the stopwatch in nanoseconds.
* </p> * </p>
* *
* <p> * <p>
@ -262,7 +259,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Get the split time on the stopwatch. * Gets the split time on the stopwatch.
* </p> * </p>
* *
* <p> * <p>
@ -280,7 +277,7 @@ public class StopWatch {
} }
/** /**
* Returns the time this stopwatch was started. * Gets the time this stopwatch was started.
* *
* @return the time this stopwatch was started * @return the time this stopwatch was started
* @throws IllegalStateException * @throws IllegalStateException
@ -297,7 +294,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Get the time on the stopwatch. * Gets the time on the stopwatch.
* </p> * </p>
* *
* <p> * <p>
@ -313,7 +310,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Get the time on the stopwatch in the specified TimeUnit. * Gets the time on the stopwatch in the specified TimeUnit.
* </p> * </p>
* *
* <p> * <p>
@ -333,12 +330,10 @@ public class StopWatch {
/** /**
* <p> * <p>
* The method is used to find out if the StopWatch is started. A suspended * Returns whether the StopWatch is started. A suspended StopWatch is also started watch.
* StopWatch is also started watch.
* </p> * </p>
* *
* @return boolean * @return boolean If the StopWatch is started.
* If the StopWatch is started.
* @since 3.2 * @since 3.2
*/ */
public boolean isStarted() { public boolean isStarted() {
@ -347,13 +342,11 @@ public class StopWatch {
/** /**
* <p> * <p>
* This method is used to find out whether the StopWatch is stopped. The * Returns whether StopWatch is stopped. The stopwatch which's not yet started and explicitly stopped stopwatch is considered
* stopwatch which's not yet started and explicitly stopped stopwatch is * as stopped.
* considered as stopped.
* </p> * </p>
* *
* @return boolean * @return boolean If the StopWatch is stopped.
* If the StopWatch is stopped.
* @since 3.2 * @since 3.2
*/ */
public boolean isStopped() { public boolean isStopped() {
@ -362,7 +355,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* This method is used to find out whether the StopWatch is suspended. * Returns whether the StopWatch is suspended.
* </p> * </p>
* *
* @return boolean * @return boolean
@ -389,7 +382,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Resume the stopwatch after a suspend. * Resumes the stopwatch after a suspend.
* </p> * </p>
* *
* <p> * <p>
@ -409,7 +402,7 @@ public class StopWatch {
} }
/** /**
* <p> * <p>
* Split the time. * Splits the time.
* </p> * </p>
* *
* <p> * <p>
@ -430,7 +423,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Start the stopwatch. * Starts the stopwatch.
* </p> * </p>
* *
* <p> * <p>
@ -454,7 +447,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Stop the stopwatch. * Stops the stopwatch.
* </p> * </p>
* *
* <p> * <p>
@ -476,7 +469,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Suspend the stopwatch for later resumption. * Suspends the stopwatch for later resumption.
* </p> * </p>
* *
* <p> * <p>
@ -529,7 +522,7 @@ public class StopWatch {
/** /**
* <p> * <p>
* Remove a split. * Removes a split.
* </p> * </p>
* *
* <p> * <p>