52 Progress(
int minSecondsUntilProgress=-1);
69 void start(
double total, std::string msg=
"");
71 inline void set(
size_t now)
76 inline void set(
int now)
82 inline void set(
double now)
87 void setD(
double now);
111 #define PROGRESS_START(progVarName, dSize, msg) \
112 ug::Progress progVarName; { std::stringstream ss; ss << msg; progVarName.start(dSize, ss.str()); }
114 #define PROGRESS_START_WITH(progVarName, dSize, msg) \
115 { std::stringstream ss; ss << msg; progVarName.start(dSize, ss.str()); }
117 #define PROGRESS_UPDATE(progVarName, d) progVarName.set(d);
118 #define PROGRESS_FINISH(progVarName) progVarName.stop();
Definition: progress.h:50
void set(double now)
Definition: progress.h:82
void start(double total, std::string msg="")
Definition: progress.cpp:161
std::string m_msg
Definition: progress.h:102
int myDepth
Definition: progress.h:106
double dNextValueToUpdate
Definition: progress.h:95
void stop()
Definition: progress.cpp:141
~Progress()
Definition: progress.h:54
static int lastUpdateDepth
Definition: progress.h:105
int m_minSecondsUntilProgress
Definition: progress.h:93
void setD(double now)
Definition: progress.cpp:105
int m_length
Definition: progress.h:101
void set_length(int l)
Definition: progress.h:59
int posNow
Definition: progress.h:97
void calc_next_value()
Definition: progress.h:64
static int totalDepth
Definition: progress.h:104
size_t iNextValueToUpdate
Definition: progress.h:96
void set(size_t now)
Definition: progress.h:71
double m_total
Definition: progress.h:99
Progress(int minSecondsUntilProgress=-1)
Definition: progress.cpp:41
double m_now
Definition: progress.h:100
double startS
Definition: progress.h:94
bool bStarted
Definition: progress.h:98
void set(int now)
Definition: progress.h:76
stopwatch class for quickly taking times