Rename Timer::_str
This commit is contained in:
parent
0e8a60f1ad
commit
33e718d59e
|
@ -72,7 +72,7 @@ void TimerResults::AddResults(const std::string& str, std::clock_t clocks)
|
||||||
}
|
}
|
||||||
|
|
||||||
Timer::Timer(const std::string& str, unsigned int showtimeMode, TimerResultsIntf* timerResults)
|
Timer::Timer(const std::string& str, unsigned int showtimeMode, TimerResultsIntf* timerResults)
|
||||||
: _str(str)
|
: mStr(str)
|
||||||
, mTimerResults(timerResults)
|
, mTimerResults(timerResults)
|
||||||
, mStart(0)
|
, mStart(0)
|
||||||
, mShowTimeMode(showtimeMode)
|
, mShowTimeMode(showtimeMode)
|
||||||
|
@ -95,10 +95,10 @@ void Timer::Stop()
|
||||||
|
|
||||||
if (mShowTimeMode == SHOWTIME_FILE) {
|
if (mShowTimeMode == SHOWTIME_FILE) {
|
||||||
const double sec = (double)diff / CLOCKS_PER_SEC;
|
const double sec = (double)diff / CLOCKS_PER_SEC;
|
||||||
std::cout << _str << ": " << sec << "s" << std::endl;
|
std::cout << mStr << ": " << sec << "s" << std::endl;
|
||||||
} else {
|
} else {
|
||||||
if (mTimerResults)
|
if (mTimerResults)
|
||||||
mTimerResults->AddResults(_str, diff);
|
mTimerResults->AddResults(mStr, diff);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -77,7 +77,7 @@ private:
|
||||||
Timer(const Timer& other); // disallow copying
|
Timer(const Timer& other); // disallow copying
|
||||||
Timer& operator=(const Timer&); // disallow assignments
|
Timer& operator=(const Timer&); // disallow assignments
|
||||||
|
|
||||||
const std::string _str;
|
const std::string mStr;
|
||||||
TimerResultsIntf* mTimerResults;
|
TimerResultsIntf* mTimerResults;
|
||||||
std::clock_t mStart;
|
std::clock_t mStart;
|
||||||
const unsigned int mShowTimeMode;
|
const unsigned int mShowTimeMode;
|
||||||
|
|
Loading…
Reference in New Issue