public class RunMeter
extends Object
Simple class for making a meter in the console.
- Author:
- posenato
-
Field Summary 
Fields
(package private) long
(package private) static final int
A value between 0 and 100
(package private) long
(package private) long
-
Constructor Summary 
Constructors
RunMeter(long inputStartTime,
long inputTotal,
long inputCurrent)
-
Method Summary 
void
void
Each call of method, advance `this.current` and print the meter.
Methods inherited from class java.lang.Object 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details 
-
maxMeterSize 
static final int maxMeterSize
A value between 0 and 100
- See Also:
-
-
current 
long current
-
startTime 
long startTime
-
total 
long total
-
Constructor Details 
-
RunMeter 
public RunMeter(long inputStartTime,
long inputTotal,
long inputCurrent)
- Parameters:
inputStartTime
- in milliseconds
inputTotal
- number of times to show
inputCurrent
- number of times to show
-
Method Details 
-
printProgress 
public void printProgress()
-
printProgress 
public void printProgress(long givenCurrent)
Each call of method, advance `this.current` and print the meter.
- Parameters:
givenCurrent
- current meter