Progress logger to ignore all progress notifications.
More...
#include <ProgressLogger.h>
|
bool | logProgress (const string &, size_t=0, size_t=100, bool=false) override |
|
bool | logStatus (const string &, int=0) override |
|
bool | logDuration (const string &, double, int=1) override |
|
| ProgressLogger (bool detailedProgress=false, double updateDelay=kDefaultUpdateDelay) |
|
virtual void | setStepCount (int stepCount) |
|
virtual void | setDetailedProgress (bool detailedProgress) |
|
bool | getDetailedProgress () const |
|
virtual bool | logNewStep (const string &stepName, size_t progress=0, size_t maxProgress=100) |
|
bool | logProgress (const string &stepName, size_t progress=0, size_t maxProgress=100) |
|
bool | logProgress (const string &stepName, int64_t progress, int64_t maxProgress) |
|
|
static constexpr double | kDefaultUpdateDelay = 2 |
|
virtual void | logMessage (const string &message) |
|
virtual void | logErrorMessage (const string &message) |
|
virtual void | updateStep (size_t progress=0, size_t maxProgress=100) |
|
virtual void | updateNextProgressTime () |
| Callback to schedule the time of the next text update.
|
|
virtual bool | shouldKeepGoing () |
|
bool | detailedProgress_ |
|
double | updateDelay_ |
|
int | stepNumber_ |
|
int | stepCount_ |
|
double | nextProgressTime_ |
|
Progress logger to ignore all progress notifications.
◆ logDuration()
bool vrs::SilentLogger::logDuration |
( |
const string & |
operationName, |
|
|
double |
duration, |
|
|
int |
precision = 1 |
|
) |
| |
|
inlineoverridevirtual |
Log that an operation was performed in a specific duration.
- Parameters
-
operationName | text describing the operation. |
duration | number of seconds the operation lasted. |
precision | precision to use when printing the duration. |
- Returns
- True if the operation should continue, false if it should be cancelled.
Reimplemented from vrs::ProgressLogger.
◆ logProgress()
bool vrs::SilentLogger::logProgress |
( |
const string & |
stepName, |
|
|
size_t |
progress = 0 , |
|
|
size_t |
maxProgress = 100 , |
|
|
bool |
newStep = false |
|
) |
| |
|
inlineoverridevirtual |
- Parameters
-
stepName | the name of the step. |
progress | the current progress in the step. |
maxProgress | the max value of the progress counter in the step. |
newStep | tells if the step is a new step (for internal use). |
- Returns
- True if the operation should continue, false if it should be cancelled.
Reimplemented from vrs::ProgressLogger.
◆ logStatus()
bool vrs::SilentLogger::logStatus |
( |
const string & |
stepName, |
|
|
int |
status = 0 |
|
) |
| |
|
inlineoverridevirtual |
Log that a step is completed, with a specific status.
- Parameters
-
stepName | the name of the step. |
status | 0 on success, otherwise, the step is considered failed. |
- Returns
- True if the operation should continue, false if it should be cancelled.
Reimplemented from vrs::ProgressLogger.
The documentation for this class was generated from the following files: