public class AcceleratingProgressHandlerWithTotal extends ProgressHandlerWithTotal
Constructor and Description |
---|
AcceleratingProgressHandlerWithTotal(long _countTotal)
Constructs a new AcceleratingProgressHandlerWithTotal with the given total count,
update interval, roundTo, maximum update delay, estimation base total and exponent.
|
AcceleratingProgressHandlerWithTotal(long _countTotal,
int _updateInterval) |
AcceleratingProgressHandlerWithTotal(long _countTotal,
int _updateInterval,
int _roundTo) |
AcceleratingProgressHandlerWithTotal(long _countTotal,
int _updateInterval,
int _roundTo,
int _maxUpdateDelay) |
AcceleratingProgressHandlerWithTotal(long _countTotal,
int _updateInterval,
int _roundTo,
int _maxUpdateDelay,
long _estimationBaseTotal) |
AcceleratingProgressHandlerWithTotal(long _countTotal,
int _updateInterval,
int _roundTo,
int _maxUpdateDelay,
long _estimationBaseTotal,
double _exponent) |
Modifier and Type | Method and Description |
---|---|
double |
getPercent()
Returns the percentage of progress done, taking into account the accelerating effect.
|
double |
getUnmodifiedPercent()
Returns the raw percentage of progress done, without the accelerating effect applied.
|
getCountTotal, getEstimationBaseHandled, getEstimationBaseTotal, getLogLevel, getMessage, getMessage, getMessage, getPercentDefaultFormatted, getTodoTime, setCountTotal, setEstimationBaseHandled, setEstimationBaseTotal, tick, tick
finalResultToLog, finalResultToLog, finalResultToLog, finalResultToLog, getCountHandled, getRunningTime, getStartedAt, isDone, printFinalResult, printFinalResult, printFinalResult, printFinalResult, printFinalResult, printProgress, printProgress, printProgress, printProgress, progressToLog, progressToLog, progressToLog, setCountHandled, setLogLevel, start, tick, tickAndPrintProgress, tickAndPrintProgress, tickAndPrintProgress, tickAndPrintProgress, tickAndProgressToLog, tickAndProgressToLog, tickAndProgressToLog
public AcceleratingProgressHandlerWithTotal(long _countTotal)
_countTotal
- the total number of elements to be handled._updateInterval
- interval in which progress notifications should be
given, in seconds (defaults to 15)._roundTo
- progress notifications are only given if the number of
handled elements is a multiple of this (defaults to 100)_maxUpdateInterval
- maximum time in seconds to wait until progress notification
is shown; if this time has passed a notification will be given, no matter
if a "_roundTo compatible value" is reached or not. This can be used to
assure notifications are shown periodically even if progress is extremly
slow. If 0 this feature will be deactivated. Defaults to 20._estimationBaseTotal
- the total number that shall be used for
calculating the estimated remaining time to complete._exponent
- the exponent to use for the accelerating effect; an exponent > 1
will result in a slower reported progress at the beginning and a faster reported
progress at the end, while an exponent < 1 will have the opposite effect.
For e.g. 1.5 we will reach half the progress at about 70% real progress, but the
remaining half will be done very quick, as only 30% are still to do in reality.
In contrast to that, an exponent of e.g. 0.7 will already report half to be done
when in reality only about 38% are done, so the 2nd half will take considerably
longer, as still about 62% have to be done.
An exponent of 1.0 will of course cause the real percentage always to be reported.public AcceleratingProgressHandlerWithTotal(long _countTotal, int _updateInterval)
public AcceleratingProgressHandlerWithTotal(long _countTotal, int _updateInterval, int _roundTo)
public AcceleratingProgressHandlerWithTotal(long _countTotal, int _updateInterval, int _roundTo, int _maxUpdateDelay)
public AcceleratingProgressHandlerWithTotal(long _countTotal, int _updateInterval, int _roundTo, int _maxUpdateDelay, long _estimationBaseTotal)
public AcceleratingProgressHandlerWithTotal(long _countTotal, int _updateInterval, int _roundTo, int _maxUpdateDelay, long _estimationBaseTotal, double _exponent)
public double getUnmodifiedPercent()
public double getPercent()
getPercent
in class ProgressHandlerWithTotal
Copyright © 2000-2024 OAshi S.à r.l. All Rights Reserved.